summaryrefslogtreecommitdiffstats
path: root/src/gui/widgets
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets')
-rw-r--r--src/gui/widgets/qlineedit.cpp4
-rw-r--r--src/gui/widgets/qmenu.h4
-rw-r--r--src/gui/widgets/qmenu_p.h4
-rw-r--r--src/gui/widgets/qmenu_symbian.cpp9
-rw-r--r--src/gui/widgets/qmenubar_p.h9
5 files changed, 19 insertions, 11 deletions
diff --git a/src/gui/widgets/qlineedit.cpp b/src/gui/widgets/qlineedit.cpp
index fa337af..116d000 100644
--- a/src/gui/widgets/qlineedit.cpp
+++ b/src/gui/widgets/qlineedit.cpp
@@ -1774,8 +1774,8 @@ void QLineEdit::mouseReleaseEvent(QMouseEvent* e)
}
#endif
- if (e->button() == Qt::LeftButton && (!d->clickCausedFocus
- || QApplication::autoSipOnMouseFocus())) {
+ if (e->button() == Qt::LeftButton && qApp->autoSipEnabled()
+ && (!d->clickCausedFocus || qApp->autoSipOnMouseFocus())) {
QEvent event(QEvent::RequestSoftwareInputPanel);
QApplication::sendEvent(this, &event);
}
diff --git a/src/gui/widgets/qmenu.h b/src/gui/widgets/qmenu.h
index 1e544f7..1676eb8 100644
--- a/src/gui/widgets/qmenu.h
+++ b/src/gui/widgets/qmenu.h
@@ -52,13 +52,15 @@
#endif
QT_BEGIN_HEADER
+#ifdef Q_OS_SYMBIAN
+ class CEikMenuPane;
+#endif
QT_BEGIN_NAMESPACE
QT_MODULE(Gui)
#ifdef Q_OS_SYMBIAN
- class CEikMenuPane;
IMPORT_C void qt_symbian_show_toplevel(CEikMenuPane* menuPane);
IMPORT_C void qt_symbian_show_submenu(CEikMenuPane* menuPane, int id);
#endif
diff --git a/src/gui/widgets/qmenu_p.h b/src/gui/widgets/qmenu_p.h
index 61cc3db..d47749f 100644
--- a/src/gui/widgets/qmenu_p.h
+++ b/src/gui/widgets/qmenu_p.h
@@ -61,6 +61,9 @@
#include "QtCore/qbasictimer.h"
#include "private/qwidget_p.h"
+#ifdef Q_OS_SYMBIAN
+class CEikMenuPane;
+#endif
QT_BEGIN_NAMESPACE
#ifndef QT_NO_MENU
@@ -121,7 +124,6 @@ struct QWceMenuAction {
};
#endif
#ifdef Q_OS_SYMBIAN
-class CEikMenuPane;
struct QSymbianMenuAction {
uint command;
int parent;
diff --git a/src/gui/widgets/qmenu_symbian.cpp b/src/gui/widgets/qmenu_symbian.cpp
index 4c8b4ae..aee55b9 100644
--- a/src/gui/widgets/qmenu_symbian.cpp
+++ b/src/gui/widgets/qmenu_symbian.cpp
@@ -31,8 +31,7 @@
QT_BEGIN_NAMESPACE
-// ### FIX/Document this, we need some safe range of menu id's for Qt that don't clash with AIW ones
-typedef QHash<QWidget *, QMenuBarPrivate *> MenuBarHash;
+typedef QMultiHash<QWidget *, QMenuBarPrivate *> MenuBarHash;
Q_GLOBAL_STATIC(MenuBarHash, menubars)
#define QT_FIRST_MENU_ITEM 32000
@@ -53,7 +52,7 @@ bool menuExists()
{
QWidget *w = qApp->activeWindow();
QMenuBarPrivate *mb = menubars()->value(w);
- if (!mb)
+ if ((!mb) && !menubars()->count())
return false;
return true;
}
@@ -272,7 +271,7 @@ void QMenuBarPrivate::symbianDestroyMenuBar()
Q_Q(QMenuBar);
int index = nativeMenuBars.indexOf(q);
nativeMenuBars.removeAt(index);
- menubars()->remove(q->window());
+ menubars()->remove(q->window(), this);
rebuildMenu();
if (symbian_menubar)
delete symbian_menubar;
@@ -387,4 +386,6 @@ void QMenuBarPrivate::QSymbianMenuBarPrivate::rebuild()
}
}
+QT_END_NAMESPACE
+
#endif //QT_NO_MENUBAR
diff --git a/src/gui/widgets/qmenubar_p.h b/src/gui/widgets/qmenubar_p.h
index f617d80..d562cd9 100644
--- a/src/gui/widgets/qmenubar_p.h
+++ b/src/gui/widgets/qmenubar_p.h
@@ -61,14 +61,17 @@
#include "qguifunctions_wince.h"
#endif
-QT_BEGIN_NAMESPACE
-
#ifndef QT_NO_MENUBAR
-class QMenuBarExtension;
#ifdef Q_OS_SYMBIAN
class CCoeControl;
class CEikMenuBar;
#endif
+#endif
+
+QT_BEGIN_NAMESPACE
+
+#ifndef QT_NO_MENUBAR
+class QMenuBarExtension;
class QMenuBarPrivate : public QWidgetPrivate
{
Q_DECLARE_PUBLIC(QMenuBar)