Search: Allow empty prefix for completer

Change-Id: Ia3a77c4512c03496cac492d401c2bff3eee7a980
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
This commit is contained in:
Orgad Shaneh
2012-09-09 09:28:18 +03:00
committed by Eike Ziller
parent 507334526e
commit a131793f51

View File

@@ -105,6 +105,8 @@ bool FindToolWindow::eventFilter(QObject *obj, QEvent *event)
if (obj == m_ui.searchTerm && event->type() == QEvent::KeyPress) {
QKeyEvent *ke = static_cast<QKeyEvent *>(event);
if (ke->key() == Qt::Key_Down) {
if (m_ui.searchTerm->text().isEmpty())
m_findCompleter->setCompletionPrefix(QString());
m_findCompleter->complete();
}
}