summaryrefslogtreecommitdiffstats
path: root/src/gui/widgets/qmenu_symbian.cpp
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2009-10-08 16:03:27 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2009-10-08 16:03:27 (GMT)
commite5bcddb6fecc1fb55f18f734601a3e928dc7510a (patch)
tree4c6fd15be926b48ca7e962c51024a1bea9bae649 /src/gui/widgets/qmenu_symbian.cpp
parent468bd5ac176c42af310d439810bbd3bb561f5a1b (diff)
parent3945fd75a93d790434b33c2d23add155893a82a4 (diff)
downloadQt-e5bcddb6fecc1fb55f18f734601a3e928dc7510a.zip
Qt-e5bcddb6fecc1fb55f18f734601a3e928dc7510a.tar.gz
Qt-e5bcddb6fecc1fb55f18f734601a3e928dc7510a.tar.bz2
Merge branch '4.6'
Conflicts: tools/assistant/translations/translations_adp.pro
Diffstat (limited to 'src/gui/widgets/qmenu_symbian.cpp')
-rw-r--r--src/gui/widgets/qmenu_symbian.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/widgets/qmenu_symbian.cpp b/src/gui/widgets/qmenu_symbian.cpp
index c656ef8..d757f98 100644
--- a/src/gui/widgets/qmenu_symbian.cpp
+++ b/src/gui/widgets/qmenu_symbian.cpp
@@ -74,12 +74,13 @@ struct SymbianMenuItem
QAction* action;
};
+Q_GLOBAL_STATIC_WITH_ARGS(QAction, contextAction, (0))
+
static QList<SymbianMenuItem*> symbianMenus;
static QList<QMenuBar*> nativeMenuBars;
static uint qt_symbian_menu_static_cmd_id = QT_SYMBIAN_FIRST_MENU_ITEM;
static QPointer<QWidget> widgetWithContextMenu;
static QList<QAction*> contextMenuActionList;
-static QAction contextAction(0);
static int contexMenuCommand=0;
bool menuExists()
@@ -400,8 +401,8 @@ void QMenuBarPrivate::QSymbianMenuBarPrivate::rebuild()
contextMenuActionList.clear();
if (widgetWithContextMenu) {
contexMenuCommand = qt_symbian_menu_static_cmd_id; // Increased inside insertNativeMenuItems
- contextAction.setText(QMenuBar::tr("Actions"));
- contextMenuActionList.append(&contextAction);
+ contextAction()->setText(QMenuBar::tr("Actions"));
+ contextMenuActionList.append(contextAction());
insertNativeMenuItems(contextMenuActionList);
}
}