diff options
author | Orgad Shaneh <orgad.shaneh@audiocodes.com> | 2013-08-20 20:39:18 +0300 |
---|---|---|
committer | Orgad Shaneh <orgads@gmail.com> | 2013-08-21 14:39:39 +0200 |
commit | 7410e4bea63cb1fbe87301363cafa9c4df61c6fe (patch) | |
tree | f8f03896608e6525c560837335f4e9b1d13f4fbd /src/plugins/locator/locatorwidget.cpp | |
parent | c2e90c360baaa5b8ea31d4466cadfab2bda3aabe (diff) |
Locator: Do not popup on focus in
* When a dialog initiated by the locator is closed
* When the main window loses focus
Task-number: QTCREATORBUG-9953
Change-Id: Iff923320e7f1cc9a633d3a6a9bee1fa49b41bb68
Reviewed-by: André Hartmann <aha_1980@gmx.de>
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Diffstat (limited to 'src/plugins/locator/locatorwidget.cpp')
-rw-r--r-- | src/plugins/locator/locatorwidget.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/plugins/locator/locatorwidget.cpp b/src/plugins/locator/locatorwidget.cpp index fb004d225f..cc0f4fd788 100644 --- a/src/plugins/locator/locatorwidget.cpp +++ b/src/plugins/locator/locatorwidget.cpp @@ -407,8 +407,10 @@ bool LocatorWidget::eventFilter(QObject *obj, QEvent *event) !(fev->reason() == Qt::ActiveWindowFocusReason && !m_completionList->isActiveWindow())) hideList = false; } - if (hideList) + if (hideList) { m_completionList->hide(); + m_fileLineEdit->clearFocus(); + } } else if (obj == m_fileLineEdit && event->type() == QEvent::FocusIn) { showPopupNow(); } else if (obj == this && event->type() == QEvent::ShortcutOverride) { @@ -542,6 +544,7 @@ void LocatorWidget::acceptCurrentEntry() return; const FilterEntry entry = m_locatorModel->data(index, Qt::UserRole).value<FilterEntry>(); m_completionList->hide(); + m_fileLineEdit->clearFocus(); entry.filter->accept(entry); } |