OSDN Git Service

Show to popup synchronously to avoid issues with the focus handling.
authorRoberto Raggi <roberto.raggi@nokia.com>
Fri, 24 Sep 2010 15:19:31 +0000 (17:19 +0200)
committerRoberto Raggi <roberto.raggi@nokia.com>
Fri, 24 Sep 2010 15:20:36 +0000 (17:20 +0200)
src/plugins/locator/locatorwidget.cpp

index 4ea486c..7ada357 100644 (file)
@@ -371,7 +371,7 @@ bool LocatorWidget::eventFilter(QObject *obj, QEvent *event)
 #endif
             m_completionList->hide();
     } else if (obj == m_fileLineEdit && event->type() == QEvent::FocusIn) {
-        showPopup();
+        showPopupNow();
     } else if (obj == this && event->type() == QEvent::ShortcutOverride) {
         QKeyEvent *ke = static_cast<QKeyEvent *>(event);
         if (ke->key() == Qt::Key_Escape && !ke->modifiers()) {
@@ -493,7 +493,7 @@ void LocatorWidget::show(const QString &text, int selectionStart, int selectionL
     if (!m_fileLineEdit->hasFocus())
         m_fileLineEdit->setFocus();
     else
-        showPopup();
+        showPopupNow();
 
     if (selectionStart >= 0) {
         m_fileLineEdit->setSelection(selectionStart, selectionLength);