diff options
author | Alessandro Portale <aportale@trolltech.com> | 2009-06-02 18:28:48 (GMT) |
---|---|---|
committer | Alessandro Portale <aportale@trolltech.com> | 2009-06-02 18:28:48 (GMT) |
commit | 9877c2b3b4b9bb8afaac9b207917ccdd866ad1d3 (patch) | |
tree | feaef23d8c3c4291421e4d04cbf838ee61a0527e /src/gui/widgets | |
parent | 629c7c2785bc7b371ed8ce1abf016c6c35a4a78f (diff) | |
download | Qt-9877c2b3b4b9bb8afaac9b207917ccdd866ad1d3.zip Qt-9877c2b3b4b9bb8afaac9b207917ccdd866ad1d3.tar.gz Qt-9877c2b3b4b9bb8afaac9b207917ccdd866ad1d3.tar.bz2 |
Since now, S60 commands are handled by QApplication::s60HandleCommandL
inside QtGui, we do not need to export those QMenu[Bar]::symbianCommands
through our public API, anymore.
This commit moved the code of QMenuBar::symbianCommands to
QMenuBarPrivate::symbianCommands and made that one static.
QMenu[Private]::symbianCommands was apparently unused -> deleted.
RevBy: Jason Barron
RevvBy: Markku Luukkainen
Diffstat (limited to 'src/gui/widgets')
-rw-r--r-- | src/gui/widgets/qmenu.h | 3 | ||||
-rw-r--r-- | src/gui/widgets/qmenu_p.h | 1 | ||||
-rw-r--r-- | src/gui/widgets/qmenu_symbian.cpp | 34 | ||||
-rw-r--r-- | src/gui/widgets/qmenubar.h | 4 | ||||
-rw-r--r-- | src/gui/widgets/qmenubar_p.h | 2 |
5 files changed, 6 insertions, 38 deletions
diff --git a/src/gui/widgets/qmenu.h b/src/gui/widgets/qmenu.h index 1676eb8..bf1c39f 100644 --- a/src/gui/widgets/qmenu.h +++ b/src/gui/widgets/qmenu.h @@ -184,9 +184,6 @@ protected: #ifdef Q_OS_WINCE QAction* wceCommands(uint command); #endif -#ifdef Q_OS_SYMBIAN - void symbianCommands(int command); -#endif private Q_SLOTS: void internalSetSloppyAction(); diff --git a/src/gui/widgets/qmenu_p.h b/src/gui/widgets/qmenu_p.h index a45f12f..aafc945 100644 --- a/src/gui/widgets/qmenu_p.h +++ b/src/gui/widgets/qmenu_p.h @@ -358,7 +358,6 @@ public: return 0; } } *symbian_menu; - bool symbianCommands(int command); #endif QPointer<QWidget> noReplayFor; }; diff --git a/src/gui/widgets/qmenu_symbian.cpp b/src/gui/widgets/qmenu_symbian.cpp index 86affe3..f181924 100644 --- a/src/gui/widgets/qmenu_symbian.cpp +++ b/src/gui/widgets/qmenu_symbian.cpp @@ -219,42 +219,18 @@ Q_GUI_EXPORT void qt_symbian_show_submenu( CEikMenuPane* menuPane, int id) } } -void QMenu::symbianCommands(int command) -{ - Q_D(QMenu); - d->symbianCommands(command); -} - -void QMenuBar::symbianCommands(int command) +void QMenuBarPrivate::symbianCommands(int command) { int size = nativeMenuBars.size(); for (int i = 0; i < nativeMenuBars.size(); ++i) { - bool result = nativeMenuBars.at(i)->d_func()->symbianCommands(command); - if (result) - return; - } -} - -bool QMenuBarPrivate::symbianCommands(int command) -{ SymbianMenuItem* menu = qt_symbian_find_menu_item(command, symbianMenus); if (!menu) - return false; - - emit q_func()->triggered(menu->action); - menu->action->activate(QAction::Trigger); - return true; -} - -bool QMenuPrivate::symbianCommands(int command) -{ - SymbianMenuItem* menu = qt_symbian_find_menu_item(command, symbianMenus); - if (!menu) - return false; + continue; - emit q_func()->triggered(menu->action); + emit nativeMenuBars.at(i)->triggered(menu->action); menu->action->activate(QAction::Trigger); - return true; + break; + } } void QMenuBarPrivate::symbianCreateMenuBar(QWidget *parent) diff --git a/src/gui/widgets/qmenubar.h b/src/gui/widgets/qmenubar.h index 36c983b..42f0c0c 100644 --- a/src/gui/widgets/qmenubar.h +++ b/src/gui/widgets/qmenubar.h @@ -118,10 +118,6 @@ public: static void wceRefresh(); #endif -#ifdef Q_OS_SYMBIAN - static void symbianCommands(int command); -#endif - public Q_SLOTS: virtual void setVisible(bool visible); diff --git a/src/gui/widgets/qmenubar_p.h b/src/gui/widgets/qmenubar_p.h index d562cd9..7993acd 100644 --- a/src/gui/widgets/qmenubar_p.h +++ b/src/gui/widgets/qmenubar_p.h @@ -259,7 +259,7 @@ public: } } *symbian_menubar; - bool symbianCommands(int command); + static void symbianCommands(int command); #endif }; |