Changeset 52151 in vbox
- Timestamp:
- Jul 23, 2014 3:12:33 PM (11 years ago)
- svn:sync-xref-src-repo-rev:
- 95185
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 22 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp
r52100 r52151 3160 3160 emit sigLanguageChange(extraDataString(strKey)); 3161 3161 /* Selector UI shortcut changed? */ 3162 else if (strKey == GUI_Input_SelectorShortcuts && g ActionPool->type() == UIActionPoolType_Selector)3162 else if (strKey == GUI_Input_SelectorShortcuts && gpActionPool->type() == UIActionPoolType_Selector) 3163 3163 emit sigSelectorUIShortcutChange(); 3164 3164 /* Runtime UI shortcut changed? */ 3165 else if (strKey == GUI_Input_MachineShortcuts && g ActionPool->type() == UIActionPoolType_Runtime)3165 else if (strKey == GUI_Input_MachineShortcuts && gpActionPool->type() == UIActionPoolType_Runtime) 3166 3166 emit sigRuntimeUIShortcutChange(); 3167 3167 #ifdef Q_WS_MAC -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.cpp
r51390 r52151 1 1 /* $Id$ */ 2 2 /** @file 3 * 4 * VBox frontends: Qt GUI ("VirtualBox"): 5 * UIActionPool class implementation 3 * VBox Qt GUI - UIActionPool class implementation. 6 4 */ 7 5 8 6 /* 9 * Copyright (C) 2010-201 3Oracle Corporation7 * Copyright (C) 2010-2014 Oracle Corporation 10 8 * 11 9 * This file is part of VirtualBox Open Source Edition (OSE), as … … 18 16 */ 19 17 20 /* Globalincludes: */18 /* Qt includes: */ 21 19 #include <QHelpEvent> 22 20 #include <QToolTip> 23 21 24 /* Localincludes: */22 /* GUI includes: */ 25 23 #include "UIActionPool.h" 26 24 #include "UIActionPoolSelector.h" 27 25 #include "UIActionPoolRuntime.h" 26 #include "UIShortcutPool.h" 28 27 #include "UIIconPool.h" 29 #include "UIShortcutPool.h"30 28 #include "VBoxGlobal.h" 31 29 32 /* Action activation event: */ 30 31 /** QEvent extension 32 * representing action-activation event. */ 33 33 class ActivateActionEvent : public QEvent 34 34 { 35 35 public: 36 36 37 /** Constructor. */ 37 38 ActivateActionEvent(QAction *pAction) 38 39 : QEvent((QEvent::Type)ActivateActionEventType) 39 40 , m_pAction(pAction) {} 41 42 /** Returns the action this event corresponding to. */ 40 43 QAction* action() const { return m_pAction; } 41 44 42 45 private: 43 46 47 /** Ho0lds the action this event corresponding to. */ 44 48 QAction *m_pAction; 45 49 }; 46 50 47 /* UIAction stuff: */ 51 48 52 UIAction::UIAction(UIActionPool *pParent, UIActionType type) 49 53 : QAction(pParent) … … 58 62 } 59 63 60 UIAction State* UIAction::toStateAction()61 { 62 return qobject_cast<UIAction State*>(this);64 UIActionPolymorphic* UIAction::toActionPolymorphic() 65 { 66 return qobject_cast<UIActionPolymorphic*>(this); 63 67 } 64 68 … … 132 136 } 133 137 134 /* UIMenu stuff: */ 138 135 139 UIMenu::UIMenu() 136 : m_fShowToolTip s(false)140 : m_fShowToolTip(false) 137 141 { 138 142 } … … 151 155 QAction *pAction = actionAt(pHelpEvent->pos()); 152 156 /* If action present => show action's tool-tip if needed: */ 153 if (pAction && m_fShowToolTip s)157 if (pAction && m_fShowToolTip) 154 158 QToolTip::showText(pHelpEvent->globalPos(), pAction->toolTip()); 155 159 break; … … 158 162 break; 159 163 } 160 /* Base-class event-handler: */164 /* Call to base-class: */ 161 165 return QMenu::event(pEvent); 162 166 } 163 167 164 /* UIActionSimple stuff: */ 168 165 169 UIActionSimple::UIActionSimple(UIActionPool *pParent, 166 170 const QString &strIcon /* = QString() */, const QString &strIconDisabled /* = QString() */) … … 186 190 } 187 191 188 /* UIActionState stuff: */ 189 UIAction State::UIActionState(UIActionPool *pParent,192 193 UIActionPolymorphic::UIActionPolymorphic(UIActionPool *pParent, 190 194 const QString &strIcon /* = QString() */, const QString &strIconDisabled /* = QString() */) 191 : UIAction(pParent, UIActionType_ State)195 : UIAction(pParent, UIActionType_Polymorphic) 192 196 , m_iState(0) 193 197 { … … 196 200 } 197 201 198 UIAction State::UIActionState(UIActionPool *pParent,202 UIActionPolymorphic::UIActionPolymorphic(UIActionPool *pParent, 199 203 const QString &strIconNormal, const QString &strIconSmall, 200 204 const QString &strIconNormalDisabled, const QString &strIconSmallDisabled) 201 : UIAction(pParent, UIActionType_ State)205 : UIAction(pParent, UIActionType_Polymorphic) 202 206 , m_iState(0) 203 207 { … … 205 209 } 206 210 207 UIAction State::UIActionState(UIActionPool *pParent,211 UIActionPolymorphic::UIActionPolymorphic(UIActionPool *pParent, 208 212 const QIcon& icon) 209 : UIAction(pParent, UIActionType_ State)213 : UIAction(pParent, UIActionType_Polymorphic) 210 214 , m_iState(0) 211 215 { … … 214 218 } 215 219 216 /* UIActionToggle stuff: */ 220 217 221 UIActionToggle::UIActionToggle(UIActionPool *pParent, 218 222 const QString &strIcon /* = QString() */, const QString &strIconDisabled /* = QString() */) … … 221 225 if (!strIcon.isNull()) 222 226 setIcon(UIIconPool::iconSet(strIcon, strIconDisabled)); 223 init();227 prepare(); 224 228 } 225 229 … … 230 234 { 231 235 setIcon(UIIconPool::iconSetOnOff(strIconOn, strIconOff, strIconOnDisabled, strIconOffDisabled)); 232 init();236 prepare(); 233 237 } 234 238 … … 239 243 if (!icon.isNull()) 240 244 setIcon(icon); 241 init(); 242 } 243 244 void UIActionToggle::sltUpdate() 245 { 246 retranslateUi(); 247 } 248 249 void UIActionToggle::init() 245 prepare(); 246 } 247 248 void UIActionToggle::prepare() 250 249 { 251 250 setCheckable(true); 252 connect(this, SIGNAL(toggled(bool)), this, SLOT(sltUpdate())); 253 } 254 255 /* UIActionMenu stuff: */ 251 } 252 253 256 254 UIActionMenu::UIActionMenu(UIActionPool *pParent, 257 255 const QString &strIcon, const QString &strIconDis) … … 270 268 setIcon(icon); 271 269 setMenu(new UIMenu); 270 } 271 272 void UIActionMenu::setShowToolTip(bool fShowToolTip) 273 { 274 qobject_cast<UIMenu*>(menu())->setShowToolTip(fShowToolTip); 272 275 } 273 276 … … 544 547 545 548 546 /* UIActionPool stuff: */547 549 UIActionPool* UIActionPool::m_pInstance = 0; 548 550 -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.h
r51390 r52151 1 1 /** @file 2 * 3 * VBox frontends: Qt GUI ("VirtualBox"): 4 * UIActionPool class declaration 2 * VBox Qt GUI - UIActionPool class declaration. 5 3 */ 6 4 7 5 /* 8 * Copyright (C) 2010-201 3Oracle Corporation6 * Copyright (C) 2010-2014 Oracle Corporation 9 7 * 10 8 * This file is part of VirtualBox Open Source Edition (OSE), as … … 17 15 */ 18 16 19 #ifndef __ UIActionPool_h__20 #define __ UIActionPool_h__17 #ifndef ___UIActionPool_h___ 18 #define ___UIActionPool_h___ 21 19 22 20 /* Qt includes: */ … … 28 26 29 27 /* Forward declarations: */ 30 class UIAction State;28 class UIActionPolymorphic; 31 29 class UIActionPool; 32 30 33 /* Action pool types: */ 31 32 /** Action-pool types. */ 34 33 enum UIActionPoolType 35 34 { … … 38 37 }; 39 38 40 /* Action types:*/39 /** Action types. */ 41 40 enum UIActionType 42 41 { 43 42 UIActionType_Simple, 44 UIActionType_ State,43 UIActionType_Polymorphic, 45 44 UIActionType_Toggle, 46 45 UIActionType_Menu 47 46 }; 48 47 49 /* Action keys:*/48 /** Action indexes. */ 50 49 enum UIActionIndex 51 50 { 52 /* Various dialogactions: */51 /* Various actions: */ 53 52 UIActionIndex_Simple_Preferences, 54 53 UIActionIndex_Simple_LogDialog, … … 69 68 }; 70 69 71 /* Basic abstract QAction reimplemetation, extending interface: */ 70 71 /** Abstract QAction extension. */ 72 72 class UIAction : public QAction 73 73 { … … 76 76 public: 77 77 78 /* API: RTTI:*/78 /** Returns action type. */ 79 79 UIActionType type() const { return m_type; } 80 80 81 /* API: Parent stuff:*/81 /** Returns action-pool this action belongs to. */ 82 82 UIActionPool* actionPool() const { return m_pActionPool; } 83 83 84 /* API: Update stuff: */ 85 virtual void update() {} 86 87 /* API: Cast stuff: */ 88 UIActionState* toStateAction(); 89 90 /* API: Name stuff: */ 84 /** Casts action to polymorphic-action. */ 85 UIActionPolymorphic* toActionPolymorphic(); 86 87 /** Returns current action name. */ 91 88 const QString& name() const { return m_strName; } 89 /** Defines current action name. */ 92 90 void setName(const QString &strName); 93 91 94 /* API: Shortcut stuff:*/92 /** Returns extra-data ID to save keyboard shortcut under. */ 95 93 virtual QString shortcutExtraDataID() const { return QString(); } 94 /** Returns default keyboard shortcut for this action. */ 96 95 virtual QKeySequence defaultShortcut(UIActionPoolType) const { return QKeySequence(); } 96 97 /** Defines current keyboard shortcut for this action. */ 97 98 void setShortcut(const QKeySequence &shortcut); 99 /** Make action show keyboard shortcut. */ 98 100 void showShortcut(); 101 /** Make action hide keyboard shortcut. */ 99 102 void hideShortcut(); 100 103 101 /** Calls for action translation handler. */104 /** Retranslates action. */ 102 105 virtual void retranslateUi() = 0; 103 106 104 107 protected: 105 108 106 /* Constructor:*/109 /** Constructor. */ 107 110 UIAction(UIActionPool *pParent, UIActionType type); 108 111 109 /* Protected API: Menu stuff:*/112 /** Returns current action name in menu. */ 110 113 QString nameInMenu() const; 111 114 … … 115 118 private: 116 119 117 /* Variables: */ 120 /** Holds the action type. */ 121 UIActionType m_type; 122 123 /** Holds the reference to the action-pool this action belongs to. */ 118 124 UIActionPool *m_pActionPool; 119 UIActionType m_type;125 /** Holds the type of the action-pool this action belongs to. */ 120 126 UIActionPoolType m_actionPoolType; 127 128 /** Holds the action name. */ 121 129 QString m_strName; 130 /** Holds the action shortcut. */ 122 131 QKeySequence m_shortcut; 132 /** Holds whether action shortcut hidden. */ 123 133 bool m_fShortcutHidden; 124 134 }; 125 135 126 /* Basic QMenu reimplemetation, extending interface: */ 136 137 /** QMenu extension 138 * allowing to show tool-tips. */ 127 139 class UIMenu : public QMenu 128 140 { … … 131 143 public: 132 144 133 /* Constructor:*/145 /** Constructor. */ 134 146 UIMenu(); 135 147 136 /* API: Tool-tip stuff: */ 137 void setShowToolTips(bool fShowToolTips) { m_fShowToolTips = fShowToolTips; } 138 bool isToolTipsShown() const { return m_fShowToolTips; } 139 140 private: 141 142 /* Helper: Event stuff: */ 143 bool event(QEvent *pEvent); 144 145 /* Variables: */ 146 bool m_fShowToolTips; 147 }; 148 149 /* Abstract extention for UIAction, describing 'simple' action type: */ 148 /** Defines whether tool-tip should be shown. */ 149 void setShowToolTip(bool fShowToolTips) { m_fShowToolTip = fShowToolTips; } 150 151 protected: 152 153 /** General event handler. */ 154 virtual bool event(QEvent *pEvent); 155 156 private: 157 158 /** Holds whether tool-tip should be shown. */ 159 bool m_fShowToolTip; 160 }; 161 162 163 /** Abstract UIAction extension for 'Simple' action type. */ 150 164 class UIActionSimple : public UIAction 151 165 { … … 154 168 protected: 155 169 156 /* Constructors:*/170 /** Constructor, taking normal icon name and name for disabled analog. */ 157 171 UIActionSimple(UIActionPool *pParent, 158 172 const QString &strIcon = QString(), const QString &strIconDisabled = QString()); 173 /** Constructor, taking normal, small icon names and names for disabled analogs. */ 159 174 UIActionSimple(UIActionPool *pParent, 160 175 const QString &strIconNormal, const QString &strIconSmall, 161 176 const QString &strIconNormalDisabled, const QString &strIconSmallDisabled); 177 /** Constructor, taking copy of existing icon. */ 162 178 UIActionSimple(UIActionPool *pParent, 163 179 const QIcon& icon); 164 180 }; 165 181 166 /* Abstract extention for UIAction, describing 'state' action type: */ 167 class UIActionState : public UIAction 182 183 /** Abstract UIAction extension for 'Polymorphic' action type. */ 184 class UIActionPolymorphic : public UIAction 168 185 { 169 186 Q_OBJECT; … … 171 188 public: 172 189 173 /* API: State stuff: */ 190 /** Returns current action state. */ 191 int state() const { return m_iState; } 192 /** Defines current action state. */ 174 193 void setState(int iState) { m_iState = iState; retranslateUi(); } 175 194 176 195 protected: 177 196 178 /* Constructors:*/179 UIAction State(UIActionPool *pParent,197 /** Constructor, taking normal icon name and name for disabled analog. */ 198 UIActionPolymorphic(UIActionPool *pParent, 180 199 const QString &strIcon = QString(), const QString &strIconDisabled = QString()); 181 UIActionState(UIActionPool *pParent, 200 /** Constructor, taking normal, small icon names and names for disabled analogs. */ 201 UIActionPolymorphic(UIActionPool *pParent, 182 202 const QString &strIconNormal, const QString &strIconSmall, 183 203 const QString &strIconNormalDisabled, const QString &strIconSmallDisabled); 184 UIActionState(UIActionPool *pParent, 204 /** Constructor, taking copy of existing icon. */ 205 UIActionPolymorphic(UIActionPool *pParent, 185 206 const QIcon& icon); 186 207 187 /* Variables: */ 208 private: 209 210 /** Holds current action state. */ 188 211 int m_iState; 189 212 }; 190 213 191 /* Abstract extention for UIAction, describing 'toggle' action type: */ 214 215 /** Abstract UIAction extension for 'Toggle' action type. */ 192 216 class UIActionToggle : public UIAction 193 217 { … … 196 220 protected: 197 221 198 /* Constructors:*/222 /** Constructor, taking normal icon name and name for disabled analog. */ 199 223 UIActionToggle(UIActionPool *pParent, 200 224 const QString &strIcon = QString(), const QString &strIconDisabled = QString()); 225 /** Constructor, taking normal on/off icon names and names for disabled analogs. */ 201 226 UIActionToggle(UIActionPool *pParent, 202 227 const QString &strIconOn, const QString &strIconOff, 203 228 const QString &strIconOnDisabled, const QString &strIconOffDisabled); 229 /** Constructor, taking copy of existing icon. */ 204 230 UIActionToggle(UIActionPool *pParent, 205 231 const QIcon &icon); 206 232 207 /* API reimplementation: Update stuff: */ 208 void update() { sltUpdate(); } 209 210 private slots: 211 212 /* Handler: Update stuff: */ 213 void sltUpdate(); 214 215 private: 216 217 /* Helper: Prepare stuff: */ 218 void init(); 219 }; 220 221 /* Abstract extention for UIAction, describing 'menu' action type: */ 233 private: 234 235 /** Prepare routine. */ 236 void prepare(); 237 }; 238 239 240 /** Abstract UIAction extension for 'Menu' action type. */ 222 241 class UIActionMenu : public UIAction 223 242 { … … 226 245 protected: 227 246 228 /* Constructors:*/247 /** Constructor, taking normal icon name and name for disabled analog. */ 229 248 UIActionMenu(UIActionPool *pParent, 230 249 const QString &strIcon = QString(), const QString &strIconDis = QString()); 250 /** Constructor, taking copy of existing icon. */ 231 251 UIActionMenu(UIActionPool *pParent, 232 252 const QIcon &icon); 233 253 254 /** Defines whether tool-tip should be shown. */ 255 void setShowToolTip(bool fShowToolTip); 256 257 private: 258 234 259 /** Updates action text accordingly. */ 235 260 virtual void updateText(); 236 261 }; 237 262 238 /* Singleton action pool: */ 263 264 /** Abstract QObject extension 265 * representing action-pool singleton. */ 239 266 class UIActionPool : public QIWithRetranslateUI3<QObject> 240 267 { … … 243 270 public: 244 271 245 /* API: Singleton stuff:*/272 /** Singleton instance access member. */ 246 273 static UIActionPool* instance(); 274 275 /** Static factory constructor. */ 247 276 static void create(UIActionPoolType type); 277 /** Static factory destructor. */ 248 278 static void destroy(); 249 279 250 /* API: Shortcut pool helper stuff: */ 280 /** Static factory constructor (temporary), 281 * used to initialize shortcuts-pool from action-pool of passed @a type. */ 251 282 static void createTemporary(UIActionPoolType type); 252 283 253 /* API: RTTI:*/284 /** Returns action-pool type. */ 254 285 UIActionPoolType type() const { return m_type; } 255 286 256 /* API: Action stuff: */ 257 UIAction* action(int iIndex) const { return m_pool[iIndex]; } 287 /** Returns the action for the passed @a iIndex. */ 288 UIAction* action(int iIndex) const { return m_pool.value(iIndex); } 289 /** Returns all the actions action-pool contains. */ 258 290 QList<UIAction*> actions() const { return m_pool.values(); } 259 291 260 /* API: Shortcuts stuff:*/292 /** Returns extra-data ID to save keyboard shortcuts under. */ 261 293 virtual QString shortcutsExtraDataID() const = 0; 262 294 263 /* API: Prepare stuff:*/295 /** Recreates menus. */ 264 296 void recreateMenus() { createMenus(); } 265 297 266 /* API: Hot-key handling stuff:*/298 /** Hot-key processing delegate. */ 267 299 bool processHotKey(const QKeySequence &key); 268 300 269 301 protected slots: 270 302 271 /* Handler: Shortcuts stuff:*/303 /** Loads keyboard shortcuts of action-pool into shortcuts-pool. */ 272 304 void sltApplyShortcuts(); 273 305 274 306 protected: 275 307 276 /* Constructor/destructor:*/308 /** Constructor of the action-pool of passed @a type. */ 277 309 UIActionPool(UIActionPoolType type); 310 /** Destructor. */ 278 311 ~UIActionPool(); 279 312 280 /* Helpers: Prepare/cleanup stuff:*/313 /** Prepare routine. */ 281 314 void prepare(); 315 /** Cleanup routine. */ 282 316 void cleanup(); 283 317 284 /* Virtual helpers: Prepare/cleanup stuff:*/318 /** Creates actions. */ 285 319 virtual void createActions(); 320 /** Creates menus. */ 286 321 virtual void createMenus(); 322 /** Destroyes poll contents. */ 287 323 virtual void destroyPool(); 288 324 289 /* Helper: Event stuff:*/290 bool event(QEvent *pEvent);291 292 /* Instance:*/325 /** General event handler. */ 326 virtual bool event(QEvent *pEvent); 327 328 /** Holds the singleton action-pool instance. */ 293 329 static UIActionPool *m_pInstance; 294 /* Action pool type:*/330 /** Holds the action-pool type. */ 295 331 UIActionPoolType m_type; 296 /* Actions pool itself:*/332 /** Holds all the actions action-pool contains. */ 297 333 QMap<int, UIAction*> m_pool; 298 334 }; 299 335 300 #define gActionPool UIActionPool::instance() 301 302 #endif /* __UIActionPool_h__ */ 303 336 #define gpActionPool UIActionPool::instance() 337 338 #endif /* !___UIActionPool_h___ */ -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIActionPoolRuntime.cpp
r52133 r52151 814 814 : UIActionMenu(pParent, ":/hd_16px.png", ":/hd_disabled_16px.png") 815 815 { 816 qobject_cast<UIMenu*>(menu())->setShowToolTips(true);816 setShowToolTip(true); 817 817 retranslateUi(); 818 818 } … … 858 858 : UIActionMenu(pParent, ":/cd_16px.png", ":/cd_disabled_16px.png") 859 859 { 860 qobject_cast<UIMenu*>(menu())->setShowToolTips(true);860 setShowToolTip(true); 861 861 retranslateUi(); 862 862 } … … 879 879 : UIActionMenu(pParent, ":/fd_16px.png", ":/fd_disabled_16px.png") 880 880 { 881 qobject_cast<UIMenu*>(menu())->setShowToolTips(true);881 setShowToolTip(true); 882 882 retranslateUi(); 883 883 } … … 900 900 : UIActionMenu(pParent, ":/usb_16px.png", ":/usb_disabled_16px.png") 901 901 { 902 qobject_cast<UIMenu*>(menu())->setShowToolTips(true);902 setShowToolTip(true); 903 903 retranslateUi(); 904 904 } … … 921 921 : UIActionMenu(pParent, ":/web_camera_16px.png", ":/web_camera_disabled_16px.png") 922 922 { 923 qobject_cast<UIMenu*>(menu())->setShowToolTips(true);923 setShowToolTip(true); 924 924 retranslateUi(); 925 925 } -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIKeyboardHandler.cpp
r52131 r52151 1003 1003 } 1004 1004 /* Process hot keys not processed in keyEvent() (as in case of non-alphanumeric keys): */ 1005 g ActionPool->processHotKey(QKeySequence(pKeyEvent->key()));1005 gpActionPool->processHotKey(QKeySequence(pKeyEvent->key())); 1006 1006 } 1007 1007 else if (!m_bIsHostComboPressed && pEvent->type() == QEvent::KeyRelease) … … 1578 1578 symbol = 0; 1579 1579 if (symbol) 1580 fWasProcessed = g ActionPool->processHotKey(QKeySequence((Qt::UNICODE_ACCEL + QChar(symbol).toUpper().unicode())));1580 fWasProcessed = gpActionPool->processHotKey(QKeySequence((Qt::UNICODE_ACCEL + QChar(symbol).toUpper().unicode()))); 1581 1581 } 1582 1582 delete[] pList; … … 1596 1596 { 1597 1597 QChar qtSymbol = QString::fromLocal8Bit(&symbol, 1)[0]; 1598 fWasProcessed = g ActionPool->processHotKey(QKeySequence((Qt::UNICODE_ACCEL + qtSymbol.toUpper().unicode())));1598 fWasProcessed = gpActionPool->processHotKey(QKeySequence((Qt::UNICODE_ACCEL + qtSymbol.toUpper().unicode()))); 1599 1599 } 1600 1600 } … … 1604 1604 Q_UNUSED(iHotKey); 1605 1605 if (pHotKey && pHotKey[0] && !pHotKey[1]) 1606 fWasProcessed = g ActionPool->processHotKey(QKeySequence(Qt::UNICODE_ACCEL + QChar(pHotKey[0]).toUpper().unicode()));1606 fWasProcessed = gpActionPool->processHotKey(QKeySequence(Qt::UNICODE_ACCEL + QChar(pHotKey[0]).toUpper().unicode())); 1607 1607 #endif /* Q_WS_MAC */ 1608 1608 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineLogic.cpp
r52133 r52151 273 273 /* Append 'Machine' menu: */ 274 274 if (uisession()->allowedMenus() & RuntimeMenuType_Machine) 275 result << g ActionPool->action(UIActionIndexRT_M_Machine)->menu();275 result << gpActionPool->action(UIActionIndexRT_M_Machine)->menu(); 276 276 /* Append 'View' menu: */ 277 277 if (uisession()->allowedMenus() & RuntimeMenuType_View) 278 result << g ActionPool->action(UIActionIndexRT_M_View)->menu();278 result << gpActionPool->action(UIActionIndexRT_M_View)->menu(); 279 279 /* Append 'Devices' menu: */ 280 280 if (uisession()->allowedMenus() & RuntimeMenuType_Devices) 281 result << g ActionPool->action(UIActionIndexRT_M_Devices)->menu();281 result << gpActionPool->action(UIActionIndexRT_M_Devices)->menu(); 282 282 #ifdef VBOX_WITH_DEBUGGER_GUI 283 283 /* Append 'Debug' menu: */ 284 284 if (uisession()->allowedMenus() & RuntimeMenuType_Debug) 285 result << g ActionPool->action(UIActionIndexRT_M_Debug)->menu();285 result << gpActionPool->action(UIActionIndexRT_M_Debug)->menu(); 286 286 #endif /* VBOX_WITH_DEBUGGER_GUI */ 287 287 /* Append 'Help' menu: */ 288 288 if (uisession()->allowedMenus() & RuntimeMenuType_Help) 289 result << g ActionPool->action(UIActionIndex_Menu_Help)->menu();289 result << gpActionPool->action(UIActionIndex_Menu_Help)->menu(); 290 290 291 291 /* Return result: */ … … 474 474 case KMachineState_TeleportingPausedVM: 475 475 { 476 QAction *pPauseAction = g ActionPool->action(UIActionIndexRT_M_Machine_T_Pause);476 QAction *pPauseAction = gpActionPool->action(UIActionIndexRT_M_Machine_T_Pause); 477 477 if (!pPauseAction->isChecked()) 478 478 { … … 488 488 case KMachineState_LiveSnapshotting: 489 489 { 490 QAction *pPauseAction = g ActionPool->action(UIActionIndexRT_M_Machine_T_Pause);490 QAction *pPauseAction = gpActionPool->action(UIActionIndexRT_M_Machine_T_Pause); 491 491 if (pPauseAction->isChecked()) 492 492 { … … 536 536 { 537 537 /* Update action states: */ 538 g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->setEnabled(uisession()->isGuestSupportsGraphics());539 g ActionPool->action(UIActionIndexRT_M_View_T_Seamless)->setEnabled(uisession()->isVisualStateAllowed(UIVisualStateType_Seamless) &&538 gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->setEnabled(uisession()->isGuestSupportsGraphics()); 539 gpActionPool->action(UIActionIndexRT_M_View_T_Seamless)->setEnabled(uisession()->isVisualStateAllowed(UIVisualStateType_Seamless) && 540 540 uisession()->isGuestSupportsSeamless()); 541 541 } … … 553 553 554 554 /* Update action state: */ 555 QAction *pAction = g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration);555 QAction *pAction = gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration); 556 556 pAction->setEnabled(fIsMouseSupportsAbsolute && fIsMouseSupportsRelative && !fIsMouseHostCursorNeeded); 557 557 if (fIsMouseHostCursorNeeded) … … 840 840 * another QMenu or a QMenuBar. This means we have to recreate all QMenus 841 841 * when creating a new QMenuBar. */ 842 g ActionPool->recreateMenus();842 gpActionPool->recreateMenus(); 843 843 #endif /* Q_WS_MAC */ 844 844 … … 862 862 863 863 /* Move actions into running actions group: */ 864 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD));864 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD)); 865 865 #ifdef Q_WS_X11 866 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS));866 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS)); 867 867 #endif 868 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Reset));869 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown));870 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_ViewPopup));871 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen));872 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless));873 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_Scale));874 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize));875 m_pRunningActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow));868 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Reset)); 869 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown)); 870 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_ViewPopup)); 871 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen)); 872 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless)); 873 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_Scale)); 874 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)); 875 m_pRunningActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow)); 876 876 877 877 /* Move actions into running-n-paused actions group: */ 878 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Save));879 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Settings));880 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot));881 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot));882 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation));883 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard));884 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings));885 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse));886 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration));887 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_T_Pause));888 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar));889 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings));890 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility));891 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives));892 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings));893 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices));894 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices));895 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices));896 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_WebCams));897 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard));898 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop));899 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_Network));900 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings));901 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders));902 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings));903 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer));904 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture));905 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start));906 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings));907 m_pRunningOrPausedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools));878 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Save)); 879 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Settings)); 880 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot)); 881 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot)); 882 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation)); 883 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard)); 884 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings)); 885 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse)); 886 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)); 887 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_T_Pause)); 888 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar)); 889 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)); 890 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)); 891 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives)); 892 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings)); 893 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)); 894 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)); 895 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)); 896 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)); 897 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)); 898 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)); 899 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_Network)); 900 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings)); 901 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders)); 902 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings)); 903 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)); 904 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture)); 905 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start)); 906 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings)); 907 m_pRunningOrPausedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools)); 908 908 909 909 /* Move actions into running-n-paused-n-stucked actions group: */ 910 m_pRunningOrPausedOrStackedActions->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff));910 m_pRunningOrPausedOrStackedActions->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff)); 911 911 } 912 912 … … 914 914 { 915 915 /* "Machine" actions connections: */ 916 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_Settings), SIGNAL(triggered()),916 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_Settings), SIGNAL(triggered()), 917 917 this, SLOT(sltOpenVMSettingsDialog())); 918 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot), SIGNAL(triggered()),918 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot), SIGNAL(triggered()), 919 919 this, SLOT(sltTakeSnapshot())); 920 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot), SIGNAL(triggered()),920 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot), SIGNAL(triggered()), 921 921 this, SLOT(sltTakeScreenshot())); 922 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation), SIGNAL(triggered()),922 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation), SIGNAL(triggered()), 923 923 this, SLOT(sltShowInformationDialog())); 924 connect(g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings), SIGNAL(triggered()),924 connect(gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings), SIGNAL(triggered()), 925 925 this, SLOT(sltShowKeyboardSettings())); 926 connect(g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration), SIGNAL(toggled(bool)),926 connect(gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration), SIGNAL(toggled(bool)), 927 927 this, SLOT(sltToggleMouseIntegration(bool))); 928 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD), SIGNAL(triggered()),928 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD), SIGNAL(triggered()), 929 929 this, SLOT(sltTypeCAD())); 930 930 #ifdef Q_WS_X11 931 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS), SIGNAL(triggered()),931 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS), SIGNAL(triggered()), 932 932 this, SLOT(sltTypeCABS())); 933 933 #endif 934 connect(g ActionPool->action(UIActionIndexRT_M_Machine_T_Pause), SIGNAL(toggled(bool)),934 connect(gpActionPool->action(UIActionIndexRT_M_Machine_T_Pause), SIGNAL(toggled(bool)), 935 935 this, SLOT(sltPause(bool))); 936 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_Reset), SIGNAL(triggered()),936 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_Reset), SIGNAL(triggered()), 937 937 this, SLOT(sltReset())); 938 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_Save), SIGNAL(triggered()),938 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_Save), SIGNAL(triggered()), 939 939 this, SLOT(sltSaveState())); 940 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown), SIGNAL(triggered()),940 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown), SIGNAL(triggered()), 941 941 this, SLOT(sltShutdown())); 942 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff), SIGNAL(triggered()),942 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff), SIGNAL(triggered()), 943 943 this, SLOT(sltPowerOff())); 944 connect(g ActionPool->action(UIActionIndexRT_M_Machine_S_Close), SIGNAL(triggered()),944 connect(gpActionPool->action(UIActionIndexRT_M_Machine_S_Close), SIGNAL(triggered()), 945 945 this, SLOT(sltClose())); 946 946 947 947 /* "View" actions connections: */ 948 connect(g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize), SIGNAL(toggled(bool)),948 connect(gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize), SIGNAL(toggled(bool)), 949 949 this, SLOT(sltToggleGuestAutoresize(bool))); 950 connect(g ActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow), SIGNAL(triggered()),950 connect(gpActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow), SIGNAL(triggered()), 951 951 this, SLOT(sltAdjustWindow())); 952 952 953 953 /* "Devices" actions connections: */ 954 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings), SIGNAL(triggered()),954 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings), SIGNAL(triggered()), 955 955 this, SLOT(sltOpenStorageSettingsDialog())); 956 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)->menu(), SIGNAL(aboutToShow()),956 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)->menu(), SIGNAL(aboutToShow()), 957 957 this, SLOT(sltPrepareStorageMenu())); 958 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)->menu(), SIGNAL(aboutToShow()),958 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)->menu(), SIGNAL(aboutToShow()), 959 959 this, SLOT(sltPrepareStorageMenu())); 960 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->menu(), SIGNAL(aboutToShow()),960 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->menu(), SIGNAL(aboutToShow()), 961 961 this, SLOT(sltPrepareUSBMenu())); 962 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->menu(), SIGNAL(aboutToShow()),962 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->menu(), SIGNAL(aboutToShow()), 963 963 this, SLOT(sltPrepareWebCamMenu())); 964 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)->menu(), SIGNAL(aboutToShow()),964 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)->menu(), SIGNAL(aboutToShow()), 965 965 this, SLOT(sltPrepareSharedClipboardMenu())); 966 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)->menu(), SIGNAL(aboutToShow()),966 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)->menu(), SIGNAL(aboutToShow()), 967 967 this, SLOT(sltPrepareDragAndDropMenu())); 968 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_Network)->menu(), SIGNAL(aboutToShow()),968 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_Network)->menu(), SIGNAL(aboutToShow()), 969 969 this, SLOT(sltPrepareNetworkMenu())); 970 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings), SIGNAL(triggered()),970 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings), SIGNAL(triggered()), 971 971 this, SLOT(sltOpenNetworkAdaptersDialog())); 972 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings), SIGNAL(triggered()),972 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings), SIGNAL(triggered()), 973 973 this, SLOT(sltOpenSharedFoldersDialog())); 974 connect(g ActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer), SIGNAL(toggled(bool)),974 connect(gpActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer), SIGNAL(toggled(bool)), 975 975 this, SLOT(sltToggleVRDE(bool))); 976 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start), SIGNAL(toggled(bool)),976 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start), SIGNAL(toggled(bool)), 977 977 this, SLOT(sltToggleVideoCapture(bool))); 978 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings), SIGNAL(triggered()),978 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings), SIGNAL(triggered()), 979 979 this, SLOT(sltOpenVideoCaptureOptions())); 980 connect(g ActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools), SIGNAL(triggered()),980 connect(gpActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools), SIGNAL(triggered()), 981 981 this, SLOT(sltInstallGuestAdditions())); 982 982 983 983 #ifdef VBOX_WITH_DEBUGGER_GUI 984 984 /* "Debug" actions connections: */ 985 connect(g ActionPool->action(UIActionIndexRT_M_Debug)->menu(), SIGNAL(aboutToShow()),985 connect(gpActionPool->action(UIActionIndexRT_M_Debug)->menu(), SIGNAL(aboutToShow()), 986 986 this, SLOT(sltPrepareDebugMenu())); 987 connect(g ActionPool->action(UIActionIndexRT_M_Debug_S_ShowStatistics), SIGNAL(triggered()),987 connect(gpActionPool->action(UIActionIndexRT_M_Debug_S_ShowStatistics), SIGNAL(triggered()), 988 988 this, SLOT(sltShowDebugStatistics())); 989 connect(g ActionPool->action(UIActionIndexRT_M_Debug_S_ShowCommandLine), SIGNAL(triggered()),989 connect(gpActionPool->action(UIActionIndexRT_M_Debug_S_ShowCommandLine), SIGNAL(triggered()), 990 990 this, SLOT(sltShowDebugCommandLine())); 991 connect(g ActionPool->action(UIActionIndexRT_M_Debug_T_Logging), SIGNAL(toggled(bool)),991 connect(gpActionPool->action(UIActionIndexRT_M_Debug_T_Logging), SIGNAL(toggled(bool)), 992 992 this, SLOT(sltLoggingToggled(bool))); 993 connect(g ActionPool->action(UIActionIndex_Simple_LogDialog), SIGNAL(triggered()),993 connect(gpActionPool->action(UIActionIndex_Simple_LogDialog), SIGNAL(triggered()), 994 994 this, SLOT(sltShowLogDialog())); 995 995 #endif … … 1037 1037 void UIMachineLogic::prepareDock() 1038 1038 { 1039 QMenu *pDockMenu = g ActionPool->action(UIActionIndexRT_M_Dock)->menu();1039 QMenu *pDockMenu = gpActionPool->action(UIActionIndexRT_M_Dock)->menu(); 1040 1040 1041 1041 /* Add all VM menu entries to the dock menu. Leave out close and stuff like 1042 1042 * this. */ 1043 QList<QAction*> actions = g ActionPool->action(UIActionIndexRT_M_Machine)->menu()->actions();1043 QList<QAction*> actions = gpActionPool->action(UIActionIndexRT_M_Machine)->menu()->actions(); 1044 1044 for (int i=0; i < actions.size(); ++i) 1045 1045 if (actions.at(i)->menuRole() == QAction::NoRole) … … 1047 1047 pDockMenu->addSeparator(); 1048 1048 1049 QMenu *pDockSettingsMenu = g ActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings)->menu();1049 QMenu *pDockSettingsMenu = gpActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings)->menu(); 1050 1050 QActionGroup *pDockPreviewModeGroup = new QActionGroup(this); 1051 QAction *pDockDisablePreview = g ActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings_T_DisableMonitor);1051 QAction *pDockDisablePreview = gpActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings_T_DisableMonitor); 1052 1052 pDockPreviewModeGroup->addAction(pDockDisablePreview); 1053 QAction *pDockEnablePreviewMonitor = g ActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings_T_PreviewMonitor);1053 QAction *pDockEnablePreviewMonitor = gpActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings_T_PreviewMonitor); 1054 1054 pDockPreviewModeGroup->addAction(pDockEnablePreviewMonitor); 1055 1055 pDockSettingsMenu->addActions(pDockPreviewModeGroup->actions()); … … 1182 1182 { 1183 1183 /* Get corresponding menu: */ 1184 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_Machine)->menu();1184 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_Machine)->menu(); 1185 1185 AssertPtrReturnVoid(pMenu); 1186 1186 /* Clear contents: */ … … 1194 1194 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_SettingsDialog) 1195 1195 { 1196 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Settings));1196 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Settings)); 1197 1197 fSeparator1 = true; 1198 1198 } 1199 1199 else 1200 g ActionPool->action(UIActionIndexRT_M_Machine_S_Settings)->setEnabled(false);1200 gpActionPool->action(UIActionIndexRT_M_Machine_S_Settings)->setEnabled(false); 1201 1201 1202 1202 /* 'Take Snapshot' action: */ … … 1204 1204 uisession()->isSnapshotOperationsAllowed()) 1205 1205 { 1206 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot));1206 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot)); 1207 1207 fSeparator1 = true; 1208 1208 } 1209 1209 else 1210 g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot)->setEnabled(false);1210 gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot)->setEnabled(false); 1211 1211 1212 1212 /* 'Take Screenshot' action: */ 1213 1213 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_TakeScreenshot) 1214 1214 { 1215 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot));1215 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot)); 1216 1216 fSeparator1 = true; 1217 1217 } 1218 1218 else 1219 g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot)->setEnabled(false);1219 gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeScreenshot)->setEnabled(false); 1220 1220 1221 1221 /* 'Information Dialog' action: */ 1222 1222 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_InformationDialog) 1223 1223 { 1224 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation));1224 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation)); 1225 1225 fSeparator1 = true; 1226 1226 } 1227 1227 else 1228 g ActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation)->setEnabled(false);1228 gpActionPool->action(UIActionIndexRT_M_Machine_S_ShowInformation)->setEnabled(false); 1229 1229 1230 1230 /* Separator #1: */ … … 1239 1239 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_KeyboardSettings) 1240 1240 { 1241 // pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings));1241 // pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings)); 1242 1242 // fSeparator2 = true; 1243 1243 } 1244 1244 else 1245 g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings)->setEnabled(false);1245 gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings)->setEnabled(false); 1246 1246 1247 1247 /* 'Mouse Integration' action: */ 1248 1248 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_MouseIntegration) 1249 1249 { 1250 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration));1250 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)); 1251 1251 fSeparator2 = true; 1252 1252 } 1253 1253 else 1254 g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)->setEnabled(false);1254 gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)->setEnabled(false); 1255 1255 1256 1256 /* Separator #2: */ … … 1265 1265 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_TypeCAD) 1266 1266 { 1267 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD));1267 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD)); 1268 1268 fSeparator3 = true; 1269 1269 } 1270 1270 else 1271 g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD)->setEnabled(false);1271 gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCAD)->setEnabled(false); 1272 1272 1273 1273 #ifdef Q_WS_X11 … … 1275 1275 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_TypeCABS) 1276 1276 { 1277 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS));1277 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS)); 1278 1278 fSeparator3 = true; 1279 1279 } 1280 1280 else 1281 g ActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS)->setEnabled(false);1281 gpActionPool->action(UIActionIndexRT_M_Machine_S_TypeCABS)->setEnabled(false); 1282 1282 #endif /* Q_WS_X11 */ 1283 1283 … … 1293 1293 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_Pause) 1294 1294 { 1295 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_T_Pause));1295 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_T_Pause)); 1296 1296 fSeparator4 = true; 1297 1297 } 1298 1298 else 1299 g ActionPool->action(UIActionIndexRT_M_Machine_T_Pause)->setEnabled(false);1299 gpActionPool->action(UIActionIndexRT_M_Machine_T_Pause)->setEnabled(false); 1300 1300 1301 1301 /* 'Reset' action: */ 1302 1302 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_Reset) 1303 1303 { 1304 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Reset));1304 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Reset)); 1305 1305 fSeparator4 = true; 1306 1306 } 1307 1307 else 1308 g ActionPool->action(UIActionIndexRT_M_Machine_S_Reset)->setEnabled(false);1308 gpActionPool->action(UIActionIndexRT_M_Machine_S_Reset)->setEnabled(false); 1309 1309 1310 1310 /* 'Save' action: */ 1311 1311 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_SaveState) 1312 1312 { 1313 // pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Save));1313 // pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Save)); 1314 1314 // fSeparator4 = true; 1315 1315 } 1316 1316 else 1317 g ActionPool->action(UIActionIndexRT_M_Machine_S_Save)->setEnabled(false);1317 gpActionPool->action(UIActionIndexRT_M_Machine_S_Save)->setEnabled(false); 1318 1318 1319 1319 /* 'Shutdown' action: */ 1320 1320 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_Shutdown) 1321 1321 { 1322 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown));1322 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown)); 1323 1323 fSeparator4 = true; 1324 1324 } 1325 1325 else 1326 g ActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown)->setEnabled(false);1326 gpActionPool->action(UIActionIndexRT_M_Machine_S_Shutdown)->setEnabled(false); 1327 1327 1328 1328 /* 'PowerOff' action: */ 1329 1329 if (uisession()->allowedActionsMenuMachine() & RuntimeMenuMachineActionType_PowerOff) 1330 1330 { 1331 // pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff));1331 // pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff)); 1332 1332 // fSeparator4 = true; 1333 1333 } 1334 1334 else 1335 g ActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff)->setEnabled(false);1335 gpActionPool->action(UIActionIndexRT_M_Machine_S_PowerOff)->setEnabled(false); 1336 1336 1337 1337 #ifndef Q_WS_MAC … … 1343 1343 1344 1344 /* Close action: */ 1345 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_S_Close));1345 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_S_Close)); 1346 1346 if (uisession()->isAllCloseActionsRestricted()) 1347 g ActionPool->action(UIActionIndexRT_M_Machine_S_Close)->setEnabled(false);1347 gpActionPool->action(UIActionIndexRT_M_Machine_S_Close)->setEnabled(false); 1348 1348 } 1349 1349 … … 1351 1351 { 1352 1352 /* Get corresponding menu: */ 1353 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_View)->menu();1353 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_View)->menu(); 1354 1354 AssertPtrReturnVoid(pMenu); 1355 1355 /* Clear contents: */ … … 1365 1365 1366 1366 /* 'Fullscreen' action: */ 1367 g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen)->setEnabled(fIsAllowedFullscreen);1367 gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen)->setEnabled(fIsAllowedFullscreen); 1368 1368 if (fIsAllowedFullscreen) 1369 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen));1369 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen)); 1370 1370 1371 1371 /* 'Seamless' action: */ 1372 g ActionPool->action(UIActionIndexRT_M_View_T_Seamless)->setEnabled(fIsAllowedSeamless);1372 gpActionPool->action(UIActionIndexRT_M_View_T_Seamless)->setEnabled(fIsAllowedSeamless); 1373 1373 if (fIsAllowedSeamless) 1374 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless));1374 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless)); 1375 1375 1376 1376 /* 'Scale' action: */ 1377 g ActionPool->action(UIActionIndexRT_M_View_T_Scale)->setEnabled(fIsAllowedScale);1377 gpActionPool->action(UIActionIndexRT_M_View_T_Scale)->setEnabled(fIsAllowedScale); 1378 1378 if (fIsAllowedScale) 1379 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_Scale));1379 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_Scale)); 1380 1380 1381 1381 /* Visual representation mode separator: */ … … 1387 1387 { 1388 1388 /* Get corresponding menu: */ 1389 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_Devices)->menu();1389 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_Devices)->menu(); 1390 1390 AssertPtrReturnVoid(pMenu); 1391 1391 /* Clear contents: */ … … 1399 1399 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_OpticalDevices) 1400 1400 { 1401 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices));1401 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)); 1402 1402 fSeparator1 = true; 1403 1403 } 1404 1404 else 1405 g ActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)->setEnabled(false);1405 gpActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)->setEnabled(false); 1406 1406 1407 1407 /* 'Floppy Devices' submenu: */ 1408 1408 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_FloppyDevices) 1409 1409 { 1410 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices));1410 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)); 1411 1411 fSeparator1 = true; 1412 1412 } 1413 1413 else 1414 g ActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)->setEnabled(false);1414 gpActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)->setEnabled(false); 1415 1415 1416 1416 /* 'USB Devices' submenu: */ 1417 1417 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_USBDevices) 1418 1418 { 1419 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices));1419 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)); 1420 1420 fSeparator1 = true; 1421 1421 } 1422 1422 else 1423 g ActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->setEnabled(false);1423 gpActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->setEnabled(false); 1424 1424 1425 1425 /* 'Web Cams' submenu: */ 1426 1426 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_WebCams) 1427 1427 { 1428 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_WebCams));1428 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)); 1429 1429 fSeparator1 = true; 1430 1430 } 1431 1431 else 1432 g ActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->setEnabled(false);1432 gpActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->setEnabled(false); 1433 1433 1434 1434 /* 'Shared Clipboard' submenu: */ 1435 1435 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_SharedClipboard) 1436 1436 { 1437 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard));1437 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)); 1438 1438 fSeparator1 = true; 1439 1439 } 1440 1440 else 1441 g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)->setEnabled(false);1441 gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)->setEnabled(false); 1442 1442 1443 1443 /* 'Drag&Drop' submenu: */ 1444 1444 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_DragAndDrop) 1445 1445 { 1446 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop));1446 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)); 1447 1447 fSeparator1 = true; 1448 1448 } 1449 1449 else 1450 g ActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)->setEnabled(false);1450 gpActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)->setEnabled(false); 1451 1451 1452 1452 /* 'Network' submenu: */ 1453 1453 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_Network) 1454 1454 { 1455 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_Network));1455 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_Network)); 1456 1456 fSeparator1 = true; 1457 1457 } 1458 1458 else 1459 g ActionPool->action(UIActionIndexRT_M_Devices_M_Network)->setEnabled(false);1459 gpActionPool->action(UIActionIndexRT_M_Devices_M_Network)->setEnabled(false); 1460 1460 updateMenuDevicesNetwork(); 1461 1461 … … 1463 1463 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_SharedFoldersSettings) 1464 1464 { 1465 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings));1465 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings)); 1466 1466 fSeparator1 = true; 1467 1467 } 1468 1468 else 1469 g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings)->setEnabled(false);1469 gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings)->setEnabled(false); 1470 1470 1471 1471 /* Separator #1: */ … … 1480 1480 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_VRDEServer) 1481 1481 { 1482 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer));1482 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)); 1483 1483 if (!uisession()->isExtensionPackUsable()) 1484 g ActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setEnabled(false);1484 gpActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setEnabled(false); 1485 1485 fSeparator2 = true; 1486 1486 } 1487 1487 else 1488 g ActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setEnabled(false);1488 gpActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setEnabled(false); 1489 1489 1490 1490 /* 'Video Capture' action: */ 1491 1491 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_VideoCapture) 1492 1492 { 1493 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start));1493 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start)); 1494 1494 fSeparator2 = true; 1495 1495 } 1496 1496 else 1497 g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start)->setEnabled(false);1497 gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start)->setEnabled(false); 1498 1498 1499 1499 /* Separator #2: */ … … 1504 1504 /* Install Guest Tools action: */ 1505 1505 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_InstallGuestTools) 1506 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools));1507 else 1508 g ActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools)->setEnabled(false);1506 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools)); 1507 else 1508 gpActionPool->action(UIActionIndexRT_M_Devices_S_InstallGuestTools)->setEnabled(false); 1509 1509 } 1510 1510 … … 1512 1512 { 1513 1513 /* Get corresponding menu: */ 1514 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_Network)->menu();1514 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_Network)->menu(); 1515 1515 AssertPtrReturnVoid(pMenu); 1516 1516 /* Clear contents: */ … … 1520 1520 /* 'Network Settings' action: */ 1521 1521 if (uisession()->allowedActionsMenuDevices() & RuntimeMenuDevicesActionType_NetworkSettings) 1522 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings));1523 else 1524 g ActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings)->setEnabled(false);1522 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings)); 1523 else 1524 gpActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings)->setEnabled(false); 1525 1525 } 1526 1526 … … 1529 1529 { 1530 1530 /* Get corresponding menu: */ 1531 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_Debug)->menu();1531 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_Debug)->menu(); 1532 1532 AssertPtrReturnVoid(pMenu); 1533 1533 /* Clear contents: */ … … 1537 1537 /* 'Statistics' action: */ 1538 1538 if (uisession()->allowedActionsMenuDebugger() & RuntimeMenuDebuggerActionType_Statistics) 1539 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Debug_S_ShowStatistics));1540 else 1541 g ActionPool->action(UIActionIndexRT_M_Debug_S_ShowStatistics)->setEnabled(false);1539 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Debug_S_ShowStatistics)); 1540 else 1541 gpActionPool->action(UIActionIndexRT_M_Debug_S_ShowStatistics)->setEnabled(false); 1542 1542 1543 1543 /* 'Command Line' action: */ 1544 1544 if (uisession()->allowedActionsMenuDebugger() & RuntimeMenuDebuggerActionType_CommandLine) 1545 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Debug_S_ShowCommandLine));1546 else 1547 g ActionPool->action(UIActionIndexRT_M_Debug_S_ShowCommandLine)->setEnabled(false);1545 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Debug_S_ShowCommandLine)); 1546 else 1547 gpActionPool->action(UIActionIndexRT_M_Debug_S_ShowCommandLine)->setEnabled(false); 1548 1548 1549 1549 /* 'Logging' action: */ 1550 1550 if (uisession()->allowedActionsMenuDebugger() & RuntimeMenuDebuggerActionType_Logging) 1551 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Debug_T_Logging));1552 else 1553 g ActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->setEnabled(false);1551 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Debug_T_Logging)); 1552 else 1553 gpActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->setEnabled(false); 1554 1554 1555 1555 /* 'Log Dialog' action: */ 1556 1556 if (uisession()->allowedActionsMenuDebugger() & RuntimeMenuDebuggerActionType_LogDialog) 1557 pMenu->addAction(g ActionPool->action(UIActionIndex_Simple_LogDialog));1558 else 1559 g ActionPool->action(UIActionIndex_Simple_LogDialog)->setEnabled(false);1557 pMenu->addAction(gpActionPool->action(UIActionIndex_Simple_LogDialog)); 1558 else 1559 gpActionPool->action(UIActionIndex_Simple_LogDialog)->setEnabled(false); 1560 1560 } 1561 1561 #endif /* VBOX_WITH_DEBUGGER_GUI */ … … 1564 1564 { 1565 1565 /* Get corresponding menu: */ 1566 QMenu *pMenu = g ActionPool->action(UIActionIndex_Menu_Help)->menu();1566 QMenu *pMenu = gpActionPool->action(UIActionIndex_Menu_Help)->menu(); 1567 1567 AssertPtrReturnVoid(pMenu); 1568 1568 /* Clear contents: */ … … 1576 1576 if (uisession()->allowedActionsMenuHelp() & RuntimeMenuHelpActionType_Contents) 1577 1577 { 1578 pMenu->addAction(g ActionPool->action(UIActionIndex_Simple_Contents));1579 VBoxGlobal::connect(g ActionPool->action(UIActionIndex_Simple_Contents), SIGNAL(triggered()),1578 pMenu->addAction(gpActionPool->action(UIActionIndex_Simple_Contents)); 1579 VBoxGlobal::connect(gpActionPool->action(UIActionIndex_Simple_Contents), SIGNAL(triggered()), 1580 1580 &msgCenter(), SLOT(sltShowHelpHelpDialog()), Qt::UniqueConnection); 1581 1581 fSeparator1 = true; 1582 1582 } 1583 1583 else 1584 g ActionPool->action(UIActionIndex_Simple_Contents)->setEnabled(false);1584 gpActionPool->action(UIActionIndex_Simple_Contents)->setEnabled(false); 1585 1585 1586 1586 /* 'Web Site' action: */ 1587 1587 if (uisession()->allowedActionsMenuHelp() & RuntimeMenuHelpActionType_WebSite) 1588 1588 { 1589 pMenu->addAction(g ActionPool->action(UIActionIndex_Simple_WebSite));1590 VBoxGlobal::connect(g ActionPool->action(UIActionIndex_Simple_WebSite), SIGNAL(triggered()),1589 pMenu->addAction(gpActionPool->action(UIActionIndex_Simple_WebSite)); 1590 VBoxGlobal::connect(gpActionPool->action(UIActionIndex_Simple_WebSite), SIGNAL(triggered()), 1591 1591 &msgCenter(), SLOT(sltShowHelpWebDialog()), Qt::UniqueConnection); 1592 1592 fSeparator1 = true; 1593 1593 } 1594 1594 else 1595 g ActionPool->action(RuntimeMenuHelpActionType_WebSite)->setEnabled(false);1595 gpActionPool->action(RuntimeMenuHelpActionType_WebSite)->setEnabled(false); 1596 1596 1597 1597 /* Separator #1: */ … … 1606 1606 if (uisession()->allowedActionsMenuHelp() & RuntimeMenuHelpActionType_ResetWarnings) 1607 1607 { 1608 pMenu->addAction(g ActionPool->action(UIActionIndex_Simple_ResetWarnings));1609 VBoxGlobal::connect(g ActionPool->action(UIActionIndex_Simple_ResetWarnings), SIGNAL(triggered()),1608 pMenu->addAction(gpActionPool->action(UIActionIndex_Simple_ResetWarnings)); 1609 VBoxGlobal::connect(gpActionPool->action(UIActionIndex_Simple_ResetWarnings), SIGNAL(triggered()), 1610 1610 &msgCenter(), SLOT(sltResetSuppressedMessages()), Qt::UniqueConnection); 1611 1611 fSeparator2 = true; 1612 1612 } 1613 1613 else 1614 g ActionPool->action(UIActionIndex_Simple_ResetWarnings)->setEnabled(false);1614 gpActionPool->action(UIActionIndex_Simple_ResetWarnings)->setEnabled(false); 1615 1615 1616 1616 /* Separator #2: */ … … 1628 1628 if (uisession()->allowedActionsMenuHelp() & RuntimeMenuHelpActionType_NetworkAccessManager) 1629 1629 { 1630 pMenu->addAction(g ActionPool->action(UIActionIndex_Simple_NetworkAccessManager));1631 VBoxGlobal::connect(g ActionPool->action(UIActionIndex_Simple_NetworkAccessManager), SIGNAL(triggered()),1630 pMenu->addAction(gpActionPool->action(UIActionIndex_Simple_NetworkAccessManager)); 1631 VBoxGlobal::connect(gpActionPool->action(UIActionIndex_Simple_NetworkAccessManager), SIGNAL(triggered()), 1632 1632 gNetworkManager, SLOT(show()), Qt::UniqueConnection); 1633 1633 # ifndef Q_WS_MAC … … 1636 1636 } 1637 1637 else 1638 g ActionPool->action(UIActionIndex_Simple_NetworkAccessManager)->setEnabled(false);1638 gpActionPool->action(UIActionIndex_Simple_NetworkAccessManager)->setEnabled(false); 1639 1639 1640 1640 # ifndef Q_WS_MAC … … 1653 1653 #endif /* Q_WS_MAC */ 1654 1654 { 1655 pMenu->addAction(g ActionPool->action(UIActionIndex_Simple_About));1656 VBoxGlobal::connect(g ActionPool->action(UIActionIndex_Simple_About), SIGNAL(triggered()),1655 pMenu->addAction(gpActionPool->action(UIActionIndex_Simple_About)); 1656 VBoxGlobal::connect(gpActionPool->action(UIActionIndex_Simple_About), SIGNAL(triggered()), 1657 1657 &msgCenter(), SLOT(sltShowHelpAboutDialog()), Qt::UniqueConnection); 1658 1658 } 1659 1659 else 1660 g ActionPool->action(UIActionIndex_Simple_About)->setEnabled(false);1660 gpActionPool->action(UIActionIndex_Simple_About)->setEnabled(false); 1661 1661 1662 1662 /* 'Preferences' action: */ … … 1667 1667 #endif /* Q_WS_MAC */ 1668 1668 { 1669 pMenu->addAction(g ActionPool->action(UIActionIndex_Simple_Preferences));1670 VBoxGlobal::connect(g ActionPool->action(UIActionIndex_Simple_Preferences), SIGNAL(triggered()),1669 pMenu->addAction(gpActionPool->action(UIActionIndex_Simple_Preferences)); 1670 VBoxGlobal::connect(gpActionPool->action(UIActionIndex_Simple_Preferences), SIGNAL(triggered()), 1671 1671 this, SLOT(sltShowGlobalPreferences()), Qt::UniqueConnection); 1672 1672 } 1673 1673 else 1674 g ActionPool->action(UIActionIndex_Simple_Preferences)->setEnabled(false);1674 gpActionPool->action(UIActionIndex_Simple_Preferences)->setEnabled(false); 1675 1675 } 1676 1676 … … 2097 2097 2098 2098 /* Determine device-type: */ 2099 const QMenu *pOpticalDevicesMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)->menu();2100 const QMenu *pFloppyDevicesMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)->menu();2099 const QMenu *pOpticalDevicesMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices)->menu(); 2100 const QMenu *pFloppyDevicesMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices)->menu(); 2101 2101 const KDeviceType deviceType = pMenu == pOpticalDevicesMenu ? KDeviceType_DVD : 2102 2102 pMenu == pFloppyDevicesMenu ? KDeviceType_Floppy : … … 2166 2166 /* Get and check the sender menu object: */ 2167 2167 QMenu *pMenu = qobject_cast<QMenu*>(sender()); 2168 QMenu *pUSBDevicesMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->menu();2168 QMenu *pUSBDevicesMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->menu(); 2169 2169 AssertMsg(pMenu == pUSBDevicesMenu, ("This slot should only be called on hovering USB menu!\n")); 2170 2170 Q_UNUSED(pUSBDevicesMenu); … … 2235 2235 /* Get and check the sender menu object: */ 2236 2236 QMenu *pMenu = qobject_cast<QMenu*>(sender()); 2237 QMenu *pWebCamMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->menu();2237 QMenu *pWebCamMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->menu(); 2238 2238 AssertReturnVoid(pMenu == pWebCamMenu); Q_UNUSED(pWebCamMenu); 2239 2239 … … 2370 2370 /* Get and check the sender menu object: */ 2371 2371 QMenu *pMenu = qobject_cast<QMenu*>(sender()); 2372 QMenu *pSharedClipboardMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)->menu();2372 QMenu *pSharedClipboardMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedClipboard)->menu(); 2373 2373 AssertMsg(pMenu == pSharedClipboardMenu, ("This slot should only be called on hovering Shared Clipboard menu!\n")); 2374 2374 Q_UNUSED(pSharedClipboardMenu); … … 2408 2408 /* Get and check the sender menu object: */ 2409 2409 QMenu *pMenu = qobject_cast<QMenu*>(sender()); 2410 QMenu *pDragAndDropMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)->menu();2410 QMenu *pDragAndDropMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_DragAndDrop)->menu(); 2411 2411 AssertMsg(pMenu == pDragAndDropMenu, ("This slot should only be called on hovering Drag'n'drop menu!\n")); 2412 2412 Q_UNUSED(pDragAndDropMenu); … … 2440 2440 /* Get and check 'the sender' menu object: */ 2441 2441 QMenu *pMenu = qobject_cast<QMenu*>(sender()); 2442 QMenu *pNetworkMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_Network)->menu();2442 QMenu *pNetworkMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_Network)->menu(); 2443 2443 AssertReturnVoid(pMenu == pNetworkMenu); 2444 2444 Q_UNUSED(pNetworkMenu); … … 2674 2674 } 2675 2675 } 2676 if (fEnabled != g ActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->isEnabled())2677 g ActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->setEnabled(fEnabled);2678 if (fChecked != g ActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->isChecked())2679 g ActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->setChecked(fChecked);2676 if (fEnabled != gpActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->isEnabled()) 2677 gpActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->setEnabled(fEnabled); 2678 if (fChecked != gpActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->isChecked()) 2679 gpActionPool->action(UIActionIndexRT_M_Debug_T_Logging)->setChecked(fChecked); 2680 2680 } 2681 2681 … … 2724 2724 if (!machine.isNull()) 2725 2725 { 2726 bool fEnabled = pAction != g ActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings_T_DisableMonitor);2726 bool fEnabled = pAction != gpActionPool->action(UIActionIndexRT_M_Dock_M_DockSettings_T_DisableMonitor); 2727 2727 gEDataManager->setRealtimeDockIconUpdateEnabled(fEnabled, vboxGlobal().managedVMUuid()); 2728 2728 updateDockOverlay(); … … 2835 2835 2836 2836 /* Check that we do NOT handling that already: */ 2837 if (g ActionPool->action(UIActionIndex_Simple_Preferences)->data().toBool())2837 if (gpActionPool->action(UIActionIndex_Simple_Preferences)->data().toBool()) 2838 2838 return; 2839 2839 /* Remember that we handling that already: */ 2840 g ActionPool->action(UIActionIndex_Simple_Preferences)->setData(true);2840 gpActionPool->action(UIActionIndex_Simple_Preferences)->setData(true); 2841 2841 2842 2842 /* Create and execute global settings window: */ … … 2848 2848 2849 2849 /* Remember that we do NOT handling that already: */ 2850 g ActionPool->action(UIActionIndex_Simple_Preferences)->setData(false);2850 gpActionPool->action(UIActionIndex_Simple_Preferences)->setData(false); 2851 2851 } 2852 2852 … … 2941 2941 { 2942 2942 m_pDbgGuiVT->pfnSetParent(m_pDbgGui, activeMachineWindow()); 2943 m_pDbgGuiVT->pfnSetMenu(m_pDbgGui, g ActionPool->action(UIActionIndexRT_M_Debug));2943 m_pDbgGuiVT->pfnSetMenu(m_pDbgGui, gpActionPool->action(UIActionIndexRT_M_Debug)); 2944 2944 dbgAdjustRelativePos(); 2945 2945 return true; -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMultiScreenLayout.cpp
r52133 r52151 359 359 360 360 /* Get the list of all view-menu actions: */ 361 QList<QAction*> viewMenuActions = g ActionPool->action(UIActionIndexRT_M_View)->menu()->actions();361 QList<QAction*> viewMenuActions = gpActionPool->action(UIActionIndexRT_M_View)->menu()->actions(); 362 362 /* Get the list of all view related actions: */ 363 363 QList<QAction*> viewActions; -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.cpp
r52133 r52151 760 760 bool fIsVRDEServerAvailable = !server.isNull(); 761 761 /* Show/Hide VRDE action depending on VRDE server availability status: */ 762 g ActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setVisible(fIsVRDEServerAvailable);762 gpActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setVisible(fIsVRDEServerAvailable); 763 763 /* Check/Uncheck VRDE action depending on VRDE server activity status: */ 764 764 if (fIsVRDEServerAvailable) 765 g ActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setChecked(server.GetEnabled());765 gpActionPool->action(UIActionIndexRT_M_Devices_T_VRDEServer)->setChecked(server.GetEnabled()); 766 766 /* Notify listeners about VRDE change: */ 767 767 emit sigVRDEChange(); … … 773 773 const CMachine machine = session().GetMachine(); 774 774 /* Check/Uncheck Video Capture action depending on feature status: */ 775 g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start)->setChecked(machine.GetVideoCaptureEnabled());775 gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start)->setChecked(machine.GetVideoCaptureEnabled()); 776 776 /* Notify listeners about Video Capture change: */ 777 777 emit sigVideoCaptureChange(); … … 990 990 ++iDevicesCountFD; 991 991 } 992 QAction *pOpticalDevicesMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices);993 QAction *pFloppyDevicesMenu = g ActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices);992 QAction *pOpticalDevicesMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices); 993 QAction *pFloppyDevicesMenu = gpActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices); 994 994 pOpticalDevicesMenu->setData(iDevicesCountCD); 995 995 pOpticalDevicesMenu->setVisible(iDevicesCountCD); … … 1013 1013 } 1014 1014 } 1015 g ActionPool->action(UIActionIndexRT_M_Devices_M_Network)->setVisible(fAtLeastOneAdapterActive);1015 gpActionPool->action(UIActionIndexRT_M_Devices_M_Network)->setVisible(fAtLeastOneAdapterActive); 1016 1016 } 1017 1017 … … 1022 1022 && !machine.GetUSBControllers().isEmpty() 1023 1023 && machine.GetUSBProxyAvailable(); 1024 g ActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->setVisible(fUSBEnabled);1024 gpActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices)->setVisible(fUSBEnabled); 1025 1025 } 1026 1026 … … 1030 1030 host.GetVideoInputDevices(); 1031 1031 const bool fWebCamsEnabled = host.isOk() && !machine.GetUSBControllers().isEmpty(); 1032 g ActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->setVisible(fWebCamsEnabled);1032 gpActionPool->action(UIActionIndexRT_M_Devices_M_WebCams)->setVisible(fWebCamsEnabled); 1033 1033 } 1034 1034 } … … 1156 1156 1157 1157 /* Should guest autoresize? */ 1158 QAction *pGuestAutoresizeSwitch = g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize);1158 QAction *pGuestAutoresizeSwitch = gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize); 1159 1159 pGuestAutoresizeSwitch->setChecked(gEDataManager->guestScreenAutoResizeEnabled(vboxGlobal().managedVMUuid())); 1160 1160 … … 1168 1168 const bool fEnabledForMachine = gEDataManager->statusBarEnabled(vboxGlobal().managedVMUuid()); 1169 1169 const bool fEnabled = fEnabledGlobally && fEnabledForMachine; 1170 QAction *pActionStatusBarSettings = g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings);1170 QAction *pActionStatusBarSettings = gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings); 1171 1171 pActionStatusBarSettings->setEnabled(fEnabled); 1172 QAction *pActionStatusBarSwitch = g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility);1172 QAction *pActionStatusBarSwitch = gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility); 1173 1173 pActionStatusBarSwitch->blockSignals(true); 1174 1174 pActionStatusBarSwitch->setChecked(fEnabled); … … 1205 1205 1206 1206 /* Remember if guest should autoresize: */ 1207 gEDataManager->setGuestScreenAutoResizeEnabled(g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->isChecked(), vboxGlobal().managedVMUuid());1207 gEDataManager->setGuestScreenAutoResizeEnabled(gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->isChecked(), vboxGlobal().managedVMUuid()); 1208 1208 1209 1209 #if 0 /* Disabled for now! */ … … 1259 1259 { 1260 1260 /* Particularly enable/disable reconfigurable action: */ 1261 g ActionPool->action(UIActionIndexRT_M_Machine_S_Settings)->setEnabled(m_fReconfigurable);1262 g ActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings)->setEnabled(m_fReconfigurable);1263 g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings)->setEnabled(m_fReconfigurable);1264 g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings)->setEnabled(m_fReconfigurable);1265 g ActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings)->setEnabled(m_fReconfigurable);1261 gpActionPool->action(UIActionIndexRT_M_Machine_S_Settings)->setEnabled(m_fReconfigurable); 1262 gpActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings)->setEnabled(m_fReconfigurable); 1263 gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings)->setEnabled(m_fReconfigurable); 1264 gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings)->setEnabled(m_fReconfigurable); 1265 gpActionPool->action(UIActionIndexRT_M_Devices_M_Network_S_Settings)->setEnabled(m_fReconfigurable); 1266 1266 /* Particularly enable/disable snapshot related action: */ 1267 g ActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot)->setEnabled(m_fSnapshotOperationsAllowed);1267 gpActionPool->action(UIActionIndexRT_M_Machine_S_TakeSnapshot)->setEnabled(m_fSnapshotOperationsAllowed); 1268 1268 } 1269 1269 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineLogicFullscreen.cpp
r52133 r52151 75 75 * the linked key without the 'Host+' part we are adding it here. */ 76 76 QString hotKey = QString("Host+%1") 77 .arg(VBoxGlobal::extractKeyFromActionText(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen)->text()));77 .arg(VBoxGlobal::extractKeyFromActionText(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen)->text())); 78 78 Assert(!hotKey.isEmpty()); 79 79 … … 446 446 447 447 /* Take care of view-action toggle state: */ 448 UIAction *pActionFullscreen = g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen);448 UIAction *pActionFullscreen = gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen); 449 449 if (!pActionFullscreen->isChecked()) 450 450 { … … 452 452 pActionFullscreen->setChecked(true); 453 453 pActionFullscreen->blockSignals(false); 454 pActionFullscreen->update();455 454 } 456 455 } … … 462 461 463 462 /* "View" actions connections: */ 464 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),463 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 465 464 this, SLOT(sltChangeVisualStateToNormal())); 466 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),465 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 467 466 this, SLOT(sltChangeVisualStateToSeamless())); 468 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),467 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 469 468 this, SLOT(sltChangeVisualStateToScale())); 470 469 } … … 608 607 { 609 608 /* "View" actions disconnections: */ 610 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),609 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 611 610 this, SLOT(sltChangeVisualStateToNormal())); 612 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),611 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 613 612 this, SLOT(sltChangeVisualStateToSeamless())); 614 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),613 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 615 614 this, SLOT(sltChangeVisualStateToScale())); 616 615 … … 622 621 { 623 622 /* Take care of view-action toggle state: */ 624 UIAction *pActionFullscreen = g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen);623 UIAction *pActionFullscreen = gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen); 625 624 if (pActionFullscreen->isChecked()) 626 625 { … … 628 627 pActionFullscreen->setChecked(false); 629 628 pActionFullscreen->blockSignals(false); 630 pActionFullscreen->update();631 629 } 632 630 … … 641 639 642 640 /* Get corresponding menu: */ 643 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_View)->menu();641 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_View)->menu(); 644 642 AssertPtrReturnVoid(pMenu); 645 643 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineViewFullscreen.cpp
r52133 r52151 51 51 #endif 52 52 ) 53 , m_bIsGuestAutoresizeEnabled(g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->isChecked())53 , m_bIsGuestAutoresizeEnabled(gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->isChecked()) 54 54 { 55 55 } -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineWindowFullscreen.cpp
r52133 r52151 226 226 #endif /* !RT_OS_DARWIN */ 227 227 connect(m_pMiniToolBar, SIGNAL(sigExitAction()), 228 g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SLOT(trigger()));228 gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SLOT(trigger())); 229 229 connect(m_pMiniToolBar, SIGNAL(sigCloseAction()), 230 g ActionPool->action(UIActionIndexRT_M_Machine_S_Close), SLOT(trigger()));230 gpActionPool->action(UIActionIndexRT_M_Machine_S_Close), SLOT(trigger())); 231 231 connect(m_pMiniToolBar, SIGNAL(sigNotifyAboutFocusStolen()), this, SLOT(sltRevokeFocus())); 232 232 } -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/normal/UIMachineLogicNormal.cpp
r52133 r52151 81 81 82 82 /* Make sure status-bar is enabled: */ 83 const bool fEnabled = g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->isChecked();83 const bool fEnabled = gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->isChecked(); 84 84 AssertReturnVoid(fEnabled); 85 85 86 86 /* Prevent user from opening another one editor or toggle status-bar: */ 87 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)->setEnabled(false);88 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->setEnabled(false);87 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)->setEnabled(false); 88 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->setEnabled(false); 89 89 /* Create status-bar editor: */ 90 90 UIStatusBarEditorWindow *pStatusBarEditor = new UIStatusBarEditorWindow(activeMachineWindow()); … … 106 106 { 107 107 /* Make sure status-bar is enabled: */ 108 const bool fEnabled = g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->isChecked();108 const bool fEnabled = gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->isChecked(); 109 109 AssertReturnVoid(fEnabled); 110 110 111 111 /* Allow user to open editor and toggle status-bar again: */ 112 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)->setEnabled(true);113 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->setEnabled(true);112 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)->setEnabled(true); 113 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->setEnabled(true); 114 114 } 115 115 … … 134 134 135 135 /* Add default contents: */ 136 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow));137 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize));136 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow)); 137 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)); 138 138 pMenu->addSeparator(); 139 139 … … 233 233 AssertMsg(pMenu, ("This slot should be called only on Hard Disks menu show!\n")); 234 234 pMenu->clear(); 235 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings));235 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives_S_Settings)); 236 236 } 237 237 … … 241 241 AssertMsg(menu, ("This slot should be called only on Shared Folders menu show!\n")); 242 242 menu->clear(); 243 menu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings));243 menu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders_S_Settings)); 244 244 } 245 245 … … 249 249 AssertMsg(pMenu, ("This slot should be called only on Video Capture menu show!\n")); 250 250 pMenu->clear(); 251 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings));252 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start));251 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_S_Settings)); 252 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture_T_Start)); 253 253 } 254 254 … … 258 258 AssertMsg(pMenu, ("This slot should be called only on Keyboard menu show!\n")); 259 259 pMenu->clear(); 260 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings));260 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard_S_Settings)); 261 261 } 262 262 … … 266 266 AssertMsg(menu, ("This slot should be called only on Mouse Integration Menu show!\n")); 267 267 menu->clear(); 268 menu->addAction(g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration));268 menu->addAction(gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)); 269 269 } 270 270 … … 275 275 276 276 /* "View" actions connections: */ 277 connect(g ActionPool->action(UIActionIndexRT_M_ViewPopup)->menu(), SIGNAL(aboutToShow()),277 connect(gpActionPool->action(UIActionIndexRT_M_ViewPopup)->menu(), SIGNAL(aboutToShow()), 278 278 this, SLOT(sltPrepareMenuViewPopup())); 279 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),279 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 280 280 this, SLOT(sltChangeVisualStateToFullscreen())); 281 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),281 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 282 282 this, SLOT(sltChangeVisualStateToSeamless())); 283 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),283 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 284 284 this, SLOT(sltChangeVisualStateToScale())); 285 connect(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings), SIGNAL(triggered(bool)),285 connect(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings), SIGNAL(triggered(bool)), 286 286 this, SLOT(sltOpenStatusBarSettings())); 287 connect(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility), SIGNAL(triggered(bool)),287 connect(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility), SIGNAL(triggered(bool)), 288 288 this, SLOT(sltToggleStatusBar())); 289 289 290 290 /* "Device" actions connections: */ 291 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives)->menu(), SIGNAL(aboutToShow()),291 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives)->menu(), SIGNAL(aboutToShow()), 292 292 this, SLOT(sltPrepareHardDisksMenu())); 293 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders)->menu(), SIGNAL(aboutToShow()),293 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders)->menu(), SIGNAL(aboutToShow()), 294 294 this, SLOT(sltPrepareSharedFoldersMenu())); 295 connect(g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture)->menu(), SIGNAL(aboutToShow()),295 connect(gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture)->menu(), SIGNAL(aboutToShow()), 296 296 this, SLOT(sltPrepareVideoCaptureMenu())); 297 connect(g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard)->menu(), SIGNAL(aboutToShow()),297 connect(gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard)->menu(), SIGNAL(aboutToShow()), 298 298 this, SLOT(sltPrepareKeyboardMenu())); 299 connect(g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse)->menu(), SIGNAL(aboutToShow()),299 connect(gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse)->menu(), SIGNAL(aboutToShow()), 300 300 this, SLOT(sltPrepareMouseIntegrationMenu())); 301 301 } … … 343 343 { 344 344 /* "View" actions disconnections: */ 345 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),345 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 346 346 this, SLOT(sltChangeVisualStateToFullscreen())); 347 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),347 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 348 348 this, SLOT(sltChangeVisualStateToSeamless())); 349 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),349 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 350 350 this, SLOT(sltChangeVisualStateToScale())); 351 disconnect(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings), SIGNAL(triggered(bool)),351 disconnect(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings), SIGNAL(triggered(bool)), 352 352 this, SLOT(sltOpenStatusBarSettings())); 353 disconnect(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility), SIGNAL(triggered(bool)),353 disconnect(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility), SIGNAL(triggered(bool)), 354 354 this, SLOT(sltToggleStatusBar())); 355 355 … … 364 364 365 365 /* Get corresponding menu: */ 366 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_View)->menu();366 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_View)->menu(); 367 367 AssertPtrReturnVoid(pMenu); 368 368 … … 373 373 if (uisession()->allowedActionsMenuView() & RuntimeMenuViewActionType_AdjustWindow) 374 374 { 375 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow));375 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow)); 376 376 fSeparator1 = true; 377 377 } 378 378 else 379 g ActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow)->setEnabled(false);379 gpActionPool->action(UIActionIndexRT_M_View_S_AdjustWindow)->setEnabled(false); 380 380 381 381 /* 'Guest Autoresize' action: */ 382 382 if (uisession()->allowedActionsMenuView() & RuntimeMenuViewActionType_GuestAutoresize) 383 383 { 384 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize));384 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)); 385 385 fSeparator1 = true; 386 386 } 387 387 else 388 g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->setEnabled(false);388 gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->setEnabled(false); 389 389 390 390 /* Separator #1: */ … … 394 394 /* 'Status Bar' submenu: */ 395 395 if (uisession()->allowedActionsMenuView() & RuntimeMenuViewActionType_StatusBar) 396 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar));396 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar)); 397 397 else 398 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar)->setEnabled(false);398 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar)->setEnabled(false); 399 399 updateMenuViewStatusBar(); 400 400 } … … 403 403 { 404 404 /* Get corresponding menu: */ 405 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar)->menu();405 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar)->menu(); 406 406 AssertPtrReturnVoid(pMenu); 407 407 /* Clear contents: */ … … 410 410 /* 'Status Bar Settings' action: */ 411 411 if (uisession()->allowedActionsMenuView() & RuntimeMenuViewActionType_StatusBarSettings) 412 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings));412 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)); 413 413 else 414 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)->setEnabled(false);414 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings)->setEnabled(false); 415 415 416 416 /* 'Toggle Status Bar' action: */ 417 417 if (uisession()->allowedActionsMenuView() & RuntimeMenuViewActionType_ToggleStatusBar) 418 pMenu->addAction(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility));418 pMenu->addAction(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)); 419 419 else 420 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->setEnabled(false);421 } 422 420 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->setEnabled(false); 421 } 422 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/normal/UIMachineViewNormal.cpp
r52133 r52151 48 48 #endif 49 49 ) 50 , m_bIsGuestAutoresizeEnabled(g ActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->isChecked())50 , m_bIsGuestAutoresizeEnabled(gpActionPool->action(UIActionIndexRT_M_View_T_GuestAutoresize)->isChecked()) 51 51 { 52 52 /* Resend the last resize hint if there was a fullscreen or -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/normal/UIMachineWindowNormal.cpp
r52133 r52151 120 120 const bool fEnabled = gEDataManager->statusBarEnabled(vboxGlobal().managedVMUuid()); 121 121 /* Update settings action 'enable' state: */ 122 QAction *pActionStatusBarSettings = g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings);122 QAction *pActionStatusBarSettings = gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_S_Settings); 123 123 pActionStatusBarSettings->setEnabled(fEnabled); 124 124 /* Update switch action 'checked' state: */ 125 QAction *pActionStatusBarSwitch = g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility);125 QAction *pActionStatusBarSwitch = gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility); 126 126 pActionStatusBarSwitch->blockSignals(true); 127 127 pActionStatusBarSwitch->setChecked(fEnabled); … … 139 139 { 140 140 /* Raise action's context-menu: */ 141 g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar)->menu()->exec(statusBar()->mapToGlobal(position));141 gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar)->menu()->exec(statusBar()->mapToGlobal(position)); 142 142 } 143 143 … … 148 148 switch (indicatorType) 149 149 { 150 case IndicatorType_HardDisks: pAction = g ActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives); break;151 case IndicatorType_OpticalDisks: pAction = g ActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices); break;152 case IndicatorType_FloppyDisks: pAction = g ActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices); break;153 case IndicatorType_USB: pAction = g ActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices); break;154 case IndicatorType_Network: pAction = g ActionPool->action(UIActionIndexRT_M_Devices_M_Network); break;155 case IndicatorType_SharedFolders: pAction = g ActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders); break;156 case IndicatorType_Display: pAction = g ActionPool->action(UIActionIndexRT_M_ViewPopup); break;157 case IndicatorType_VideoCapture: pAction = g ActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture); break;158 case IndicatorType_Mouse: pAction = g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse); break;159 case IndicatorType_Keyboard: pAction = g ActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard); break;150 case IndicatorType_HardDisks: pAction = gpActionPool->action(UIActionIndexRT_M_Devices_M_HardDrives); break; 151 case IndicatorType_OpticalDisks: pAction = gpActionPool->action(UIActionIndexRT_M_Devices_M_OpticalDevices); break; 152 case IndicatorType_FloppyDisks: pAction = gpActionPool->action(UIActionIndexRT_M_Devices_M_FloppyDevices); break; 153 case IndicatorType_USB: pAction = gpActionPool->action(UIActionIndexRT_M_Devices_M_USBDevices); break; 154 case IndicatorType_Network: pAction = gpActionPool->action(UIActionIndexRT_M_Devices_M_Network); break; 155 case IndicatorType_SharedFolders: pAction = gpActionPool->action(UIActionIndexRT_M_Devices_M_SharedFolders); break; 156 case IndicatorType_Display: pAction = gpActionPool->action(UIActionIndexRT_M_ViewPopup); break; 157 case IndicatorType_VideoCapture: pAction = gpActionPool->action(UIActionIndexRT_M_Devices_M_VideoCapture); break; 158 case IndicatorType_Mouse: pAction = gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse); break; 159 case IndicatorType_Keyboard: pAction = gpActionPool->action(UIActionIndexRT_M_Machine_M_Keyboard); break; 160 160 default: break; 161 161 } … … 286 286 #endif /* !Q_WS_MAC */ 287 287 /* Update status-bar visibility: */ 288 statusBar()->setVisible(g ActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->isChecked());288 statusBar()->setVisible(gpActionPool->action(UIActionIndexRT_M_View_M_StatusBar_T_Visibility)->isChecked()); 289 289 m_pIndicatorsPool->setAutoUpdateIndicatorStates(statusBar()->isVisible()); 290 290 } -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/scale/UIMachineLogicScale.cpp
r52133 r52151 48 48 * the linked key without the 'Host+' part we are adding it here. */ 49 49 QString strHotKey = QString("Host+%1") 50 .arg(VBoxGlobal::extractKeyFromActionText(g ActionPool->action(UIActionIndexRT_M_View_T_Scale)->text()));50 .arg(VBoxGlobal::extractKeyFromActionText(gpActionPool->action(UIActionIndexRT_M_View_T_Scale)->text())); 51 51 Assert(!strHotKey.isEmpty()); 52 52 … … 76 76 77 77 /* Take care of view-action toggle state: */ 78 UIAction *pActionScale = g ActionPool->action(UIActionIndexRT_M_View_T_Scale);78 UIAction *pActionScale = gpActionPool->action(UIActionIndexRT_M_View_T_Scale); 79 79 if (!pActionScale->isChecked()) 80 80 { … … 82 82 pActionScale->setChecked(true); 83 83 pActionScale->blockSignals(false); 84 pActionScale->update();85 84 } 86 85 } … … 92 91 93 92 /* "View" actions connections: */ 94 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),93 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 95 94 this, SLOT(sltChangeVisualStateToNormal())); 96 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),95 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 97 96 this, SLOT(sltChangeVisualStateToFullscreen())); 98 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),97 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 99 98 this, SLOT(sltChangeVisualStateToSeamless())); 100 99 } … … 171 170 { 172 171 /* "View" actions disconnections: */ 173 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),172 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 174 173 this, SLOT(sltChangeVisualStateToNormal())); 175 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),174 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 176 175 this, SLOT(sltChangeVisualStateToFullscreen())); 177 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),176 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 178 177 this, SLOT(sltChangeVisualStateToSeamless())); 179 178 … … 186 185 { 187 186 /* Take care of view-action toggle state: */ 188 UIAction *pActionScale = g ActionPool->action(UIActionIndexRT_M_View_T_Scale);187 UIAction *pActionScale = gpActionPool->action(UIActionIndexRT_M_View_T_Scale); 189 188 if (pActionScale->isChecked()) 190 189 { … … 192 191 pActionScale->setChecked(false); 193 192 pActionScale->blockSignals(false); 194 pActionScale->update();195 193 } 196 194 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/seamless/UIMachineLogicSeamless.cpp
r52133 r52151 75 75 * the linked key without the 'Host+' part we are adding it here. */ 76 76 QString hotKey = QString("Host+%1") 77 .arg(VBoxGlobal::extractKeyFromActionText(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless)->text()));77 .arg(VBoxGlobal::extractKeyFromActionText(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless)->text())); 78 78 Assert(!hotKey.isEmpty()); 79 79 … … 204 204 205 205 /* Disable mouse-integration isn't allowed in seamless: */ 206 g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)->setVisible(false);206 gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)->setVisible(false); 207 207 208 208 /* Take care of view-action toggle state: */ 209 UIAction *pActionSeamless = g ActionPool->action(UIActionIndexRT_M_View_T_Seamless);209 UIAction *pActionSeamless = gpActionPool->action(UIActionIndexRT_M_View_T_Seamless); 210 210 if (!pActionSeamless->isChecked()) 211 211 { … … 213 213 pActionSeamless->setChecked(true); 214 214 pActionSeamless->blockSignals(false); 215 pActionSeamless->update();216 215 } 217 216 } … … 223 222 224 223 /* "View" actions connections: */ 225 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),224 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 226 225 this, SLOT(sltChangeVisualStateToNormal())); 227 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),226 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 228 227 this, SLOT(sltChangeVisualStateToFullscreen())); 229 connect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),228 connect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 230 229 this, SLOT(sltChangeVisualStateToScale())); 231 230 } … … 304 303 { 305 304 /* "View" actions disconnections: */ 306 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)),305 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SIGNAL(triggered(bool)), 307 306 this, SLOT(sltChangeVisualStateToNormal())); 308 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)),307 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Fullscreen), SIGNAL(triggered(bool)), 309 308 this, SLOT(sltChangeVisualStateToFullscreen())); 310 disconnect(g ActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)),309 disconnect(gpActionPool->action(UIActionIndexRT_M_View_T_Scale), SIGNAL(triggered(bool)), 311 310 this, SLOT(sltChangeVisualStateToScale())); 312 311 … … 318 317 { 319 318 /* Take care of view-action toggle state: */ 320 UIAction *pActionSeamless = g ActionPool->action(UIActionIndexRT_M_View_T_Seamless);319 UIAction *pActionSeamless = gpActionPool->action(UIActionIndexRT_M_View_T_Seamless); 321 320 if (pActionSeamless->isChecked()) 322 321 { … … 324 323 pActionSeamless->setChecked(false); 325 324 pActionSeamless->blockSignals(false); 326 pActionSeamless->update();327 325 } 328 326 329 327 /* Reenable mouse-integration action: */ 330 g ActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)->setVisible(true);328 gpActionPool->action(UIActionIndexRT_M_Machine_M_Mouse_T_Integration)->setVisible(true); 331 329 332 330 /* Call to base-class: */ … … 340 338 341 339 /* Get corresponding menu: */ 342 QMenu *pMenu = g ActionPool->action(UIActionIndexRT_M_View)->menu();340 QMenu *pMenu = gpActionPool->action(UIActionIndexRT_M_View)->menu(); 343 341 AssertPtrReturnVoid(pMenu); 344 342 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/seamless/UIMachineWindowSeamless.cpp
r52133 r52151 119 119 connect(m_pMiniToolBar, SIGNAL(sigMinimizeAction()), this, SLOT(showMinimized())); 120 120 connect(m_pMiniToolBar, SIGNAL(sigExitAction()), 121 g ActionPool->action(UIActionIndexRT_M_View_T_Seamless), SLOT(trigger()));121 gpActionPool->action(UIActionIndexRT_M_View_T_Seamless), SLOT(trigger())); 122 122 connect(m_pMiniToolBar, SIGNAL(sigCloseAction()), 123 g ActionPool->action(UIActionIndexRT_M_Machine_S_Close), SLOT(trigger()));123 gpActionPool->action(UIActionIndexRT_M_Machine_S_Close), SLOT(trigger())); 124 124 connect(m_pMiniToolBar, SIGNAL(sigNotifyAboutFocusStolen()), this, SLOT(sltRevokeFocus())); 125 125 } -
trunk/src/VBox/Frontends/VirtualBox/src/selector/UIActionPoolSelector.cpp
r51931 r52151 599 599 600 600 601 class UIActionStateCommonStartOrShow : public UIAction State601 class UIActionStateCommonStartOrShow : public UIActionPolymorphic 602 602 { 603 603 Q_OBJECT; … … 606 606 607 607 UIActionStateCommonStartOrShow(UIActionPool *pParent) 608 : UIAction State(pParent,608 : UIActionPolymorphic(pParent, 609 609 ":/vm_start_32px.png", ":/vm_start_16px.png", 610 610 ":/vm_start_disabled_32px.png", ":/vm_start_disabled_16px.png") … … 622 622 void retranslateUi() 623 623 { 624 switch ( m_iState)624 switch (state()) 625 625 { 626 626 case 0: -
trunk/src/VBox/Frontends/VirtualBox/src/selector/UISelectorWindow.cpp
r51992 r52151 1096 1096 { 1097 1097 /* Prepare File-menu: */ 1098 m_pFileMenu = g ActionPool->action(UIActionIndexSelector_Menu_File)->menu();1098 m_pFileMenu = gpActionPool->action(UIActionIndexSelector_Menu_File)->menu(); 1099 1099 prepareMenuFile(m_pFileMenu); 1100 1100 menuBar()->addMenu(m_pFileMenu); 1101 1101 1102 1102 /* Prepare 'Group' / 'Close' menu: */ 1103 m_pGroupCloseMenuAction = g ActionPool->action(UIActionIndexSelector_Menu_Group_Close);1103 m_pGroupCloseMenuAction = gpActionPool->action(UIActionIndexSelector_Menu_Group_Close); 1104 1104 m_pGroupCloseMenu = m_pGroupCloseMenuAction->menu(); 1105 1105 prepareMenuGroupClose(m_pGroupCloseMenu); 1106 1106 1107 1107 /* Prepare 'Machine' / 'Close' menu: */ 1108 m_pMachineCloseMenuAction = g ActionPool->action(UIActionIndexSelector_Menu_Machine_Close);1108 m_pMachineCloseMenuAction = gpActionPool->action(UIActionIndexSelector_Menu_Machine_Close); 1109 1109 m_pMachineCloseMenu = m_pMachineCloseMenuAction->menu(); 1110 1110 prepareMenuMachineClose(m_pMachineCloseMenu); … … 1116 1116 1117 1117 /* Prepare Group-menu: */ 1118 m_pGroupMenu = g ActionPool->action(UIActionIndexSelector_Menu_Group)->menu();1118 m_pGroupMenu = gpActionPool->action(UIActionIndexSelector_Menu_Group)->menu(); 1119 1119 prepareMenuGroup(m_pGroupMenu); 1120 1120 m_pGroupMenuAction = menuBar()->addMenu(m_pGroupMenu); 1121 1121 1122 1122 /* Prepare Machine-menu: */ 1123 m_pMachineMenu = g ActionPool->action(UIActionIndexSelector_Menu_Machine)->menu();1123 m_pMachineMenu = gpActionPool->action(UIActionIndexSelector_Menu_Machine)->menu(); 1124 1124 prepareMenuMachine(m_pMachineMenu); 1125 1125 m_pMachineMenuAction = menuBar()->addMenu(m_pMachineMenu); … … 1130 1130 1131 1131 /* Prepare Help-menu: */ 1132 m_pHelpMenu = g ActionPool->action(UIActionIndex_Menu_Help)->menu();1132 m_pHelpMenu = gpActionPool->action(UIActionIndex_Menu_Help)->menu(); 1133 1133 prepareMenuHelp(m_pHelpMenu); 1134 1134 menuBar()->addMenu(m_pHelpMenu); … … 1145 1145 1146 1146 /* Populate File-menu: */ 1147 m_pMediumManagerDialogAction = g ActionPool->action(UIActionIndexSelector_Simple_File_MediumManagerDialog);1147 m_pMediumManagerDialogAction = gpActionPool->action(UIActionIndexSelector_Simple_File_MediumManagerDialog); 1148 1148 pMenu->addAction(m_pMediumManagerDialogAction); 1149 m_pImportApplianceWizardAction = g ActionPool->action(UIActionIndexSelector_Simple_File_ImportApplianceWizard);1149 m_pImportApplianceWizardAction = gpActionPool->action(UIActionIndexSelector_Simple_File_ImportApplianceWizard); 1150 1150 pMenu->addAction(m_pImportApplianceWizardAction); 1151 m_pExportApplianceWizardAction = g ActionPool->action(UIActionIndexSelector_Simple_File_ExportApplianceWizard);1151 m_pExportApplianceWizardAction = gpActionPool->action(UIActionIndexSelector_Simple_File_ExportApplianceWizard); 1152 1152 pMenu->addAction(m_pExportApplianceWizardAction); 1153 1153 #ifndef Q_WS_MAC … … 1155 1155 #endif /* Q_WS_MAC */ 1156 1156 #ifdef DEBUG 1157 m_pExtraDataManagerWindowAction = g ActionPool->action(UIActionIndexSelector_Simple_File_ExtraDataManagerWindow);1157 m_pExtraDataManagerWindowAction = gpActionPool->action(UIActionIndexSelector_Simple_File_ExtraDataManagerWindow); 1158 1158 pMenu->addAction(m_pExtraDataManagerWindowAction); 1159 1159 #endif /* DEBUG */ 1160 m_pPreferencesDialogAction = g ActionPool->action(UIActionIndex_Simple_Preferences);1160 m_pPreferencesDialogAction = gpActionPool->action(UIActionIndex_Simple_Preferences); 1161 1161 pMenu->addAction(m_pPreferencesDialogAction); 1162 1162 #ifndef Q_WS_MAC 1163 1163 pMenu->addSeparator(); 1164 1164 #endif /* Q_WS_MAC */ 1165 m_pExitAction = g ActionPool->action(UIActionIndexSelector_Simple_File_Exit);1165 m_pExitAction = gpActionPool->action(UIActionIndexSelector_Simple_File_Exit); 1166 1166 pMenu->addAction(m_pExitAction); 1167 1167 } … … 1169 1169 void UISelectorWindow::prepareCommonActions() 1170 1170 { 1171 m_pAction_Common_StartOrShow = g ActionPool->action(UIActionIndexSelector_State_Common_StartOrShow)->toStateAction();1172 m_pAction_Common_PauseAndResume = g ActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume);1173 m_pAction_Common_Reset = g ActionPool->action(UIActionIndexSelector_Simple_Common_Reset);1174 m_pAction_Common_Discard = g ActionPool->action(UIActionIndexSelector_Simple_Common_Discard);1175 m_pAction_Common_Refresh = g ActionPool->action(UIActionIndexSelector_Simple_Common_Refresh);1176 m_pAction_Common_ShowInFileManager = g ActionPool->action(UIActionIndexSelector_Simple_Common_ShowInFileManager);1177 m_pAction_Common_CreateShortcut = g ActionPool->action(UIActionIndexSelector_Simple_Common_CreateShortcut);1171 m_pAction_Common_StartOrShow = gpActionPool->action(UIActionIndexSelector_State_Common_StartOrShow)->toActionPolymorphic(); 1172 m_pAction_Common_PauseAndResume = gpActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume); 1173 m_pAction_Common_Reset = gpActionPool->action(UIActionIndexSelector_Simple_Common_Reset); 1174 m_pAction_Common_Discard = gpActionPool->action(UIActionIndexSelector_Simple_Common_Discard); 1175 m_pAction_Common_Refresh = gpActionPool->action(UIActionIndexSelector_Simple_Common_Refresh); 1176 m_pAction_Common_ShowInFileManager = gpActionPool->action(UIActionIndexSelector_Simple_Common_ShowInFileManager); 1177 m_pAction_Common_CreateShortcut = gpActionPool->action(UIActionIndexSelector_Simple_Common_CreateShortcut); 1178 1178 } 1179 1179 1180 1180 void UISelectorWindow::prepareGroupActions() 1181 1181 { 1182 m_pAction_Group_New = g ActionPool->action(UIActionIndexSelector_Simple_Group_New);1183 m_pAction_Group_Add = g ActionPool->action(UIActionIndexSelector_Simple_Group_Add);1184 m_pAction_Group_Rename = g ActionPool->action(UIActionIndexSelector_Simple_Group_Rename);1185 m_pAction_Group_Remove = g ActionPool->action(UIActionIndexSelector_Simple_Group_Remove);1186 m_pAction_Group_Sort = g ActionPool->action(UIActionIndexSelector_Simple_Group_Sort);1182 m_pAction_Group_New = gpActionPool->action(UIActionIndexSelector_Simple_Group_New); 1183 m_pAction_Group_Add = gpActionPool->action(UIActionIndexSelector_Simple_Group_Add); 1184 m_pAction_Group_Rename = gpActionPool->action(UIActionIndexSelector_Simple_Group_Rename); 1185 m_pAction_Group_Remove = gpActionPool->action(UIActionIndexSelector_Simple_Group_Remove); 1186 m_pAction_Group_Sort = gpActionPool->action(UIActionIndexSelector_Simple_Group_Sort); 1187 1187 } 1188 1188 1189 1189 void UISelectorWindow::prepareMachineActions() 1190 1190 { 1191 m_pAction_Machine_New = g ActionPool->action(UIActionIndexSelector_Simple_Machine_New);1192 m_pAction_Machine_Add = g ActionPool->action(UIActionIndexSelector_Simple_Machine_Add);1193 m_pAction_Machine_Settings = g ActionPool->action(UIActionIndexSelector_Simple_Machine_Settings);1194 m_pAction_Machine_Clone = g ActionPool->action(UIActionIndexSelector_Simple_Machine_Clone);1195 m_pAction_Machine_Remove = g ActionPool->action(UIActionIndexSelector_Simple_Machine_Remove);1196 m_pAction_Machine_AddGroup = g ActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup);1197 m_pAction_Machine_LogDialog = g ActionPool->action(UIActionIndex_Simple_LogDialog);1198 m_pAction_Machine_SortParent = g ActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent);1191 m_pAction_Machine_New = gpActionPool->action(UIActionIndexSelector_Simple_Machine_New); 1192 m_pAction_Machine_Add = gpActionPool->action(UIActionIndexSelector_Simple_Machine_Add); 1193 m_pAction_Machine_Settings = gpActionPool->action(UIActionIndexSelector_Simple_Machine_Settings); 1194 m_pAction_Machine_Clone = gpActionPool->action(UIActionIndexSelector_Simple_Machine_Clone); 1195 m_pAction_Machine_Remove = gpActionPool->action(UIActionIndexSelector_Simple_Machine_Remove); 1196 m_pAction_Machine_AddGroup = gpActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup); 1197 m_pAction_Machine_LogDialog = gpActionPool->action(UIActionIndex_Simple_LogDialog); 1198 m_pAction_Machine_SortParent = gpActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent); 1199 1199 } 1200 1200 … … 1279 1279 1280 1280 /* Populate 'Group' / 'Close' menu: */ 1281 m_pGroupSaveAction = g ActionPool->action(UIActionIndexSelector_Simple_Group_Close_Save);1281 m_pGroupSaveAction = gpActionPool->action(UIActionIndexSelector_Simple_Group_Close_Save); 1282 1282 pMenu->addAction(m_pGroupSaveAction); 1283 m_pGroupACPIShutdownAction = g ActionPool->action(UIActionIndexSelector_Simple_Group_Close_ACPIShutdown);1283 m_pGroupACPIShutdownAction = gpActionPool->action(UIActionIndexSelector_Simple_Group_Close_ACPIShutdown); 1284 1284 pMenu->addAction(m_pGroupACPIShutdownAction); 1285 m_pGroupPowerOffAction = g ActionPool->action(UIActionIndexSelector_Simple_Group_Close_PowerOff);1285 m_pGroupPowerOffAction = gpActionPool->action(UIActionIndexSelector_Simple_Group_Close_PowerOff); 1286 1286 pMenu->addAction(m_pGroupPowerOffAction); 1287 1287 … … 1299 1299 1300 1300 /* Populate 'Machine' / 'Close' menu: */ 1301 m_pMachineSaveAction = g ActionPool->action(UIActionIndexSelector_Simple_Machine_Close_Save);1301 m_pMachineSaveAction = gpActionPool->action(UIActionIndexSelector_Simple_Machine_Close_Save); 1302 1302 pMenu->addAction(m_pMachineSaveAction); 1303 m_pMachineACPIShutdownAction = g ActionPool->action(UIActionIndexSelector_Simple_Machine_Close_ACPIShutdown);1303 m_pMachineACPIShutdownAction = gpActionPool->action(UIActionIndexSelector_Simple_Machine_Close_ACPIShutdown); 1304 1304 pMenu->addAction(m_pMachineACPIShutdownAction); 1305 m_pMachinePowerOffAction = g ActionPool->action(UIActionIndexSelector_Simple_Machine_Close_PowerOff);1305 m_pMachinePowerOffAction = gpActionPool->action(UIActionIndexSelector_Simple_Machine_Close_PowerOff); 1306 1306 pMenu->addAction(m_pMachinePowerOffAction); 1307 1307 … … 1319 1319 1320 1320 /* Populate Help-menu: */ 1321 m_pHelpAction = g ActionPool->action(UIActionIndex_Simple_Contents);1321 m_pHelpAction = gpActionPool->action(UIActionIndex_Simple_Contents); 1322 1322 pMenu->addAction(m_pHelpAction); 1323 m_pWebAction = g ActionPool->action(UIActionIndex_Simple_WebSite);1323 m_pWebAction = gpActionPool->action(UIActionIndex_Simple_WebSite); 1324 1324 pMenu->addAction(m_pWebAction); 1325 1325 pMenu->addSeparator(); 1326 m_pResetWarningsAction = g ActionPool->action(UIActionIndex_Simple_ResetWarnings);1326 m_pResetWarningsAction = gpActionPool->action(UIActionIndex_Simple_ResetWarnings); 1327 1327 pMenu->addAction(m_pResetWarningsAction); 1328 1328 #ifdef VBOX_GUI_WITH_NETWORK_MANAGER 1329 1329 pMenu->addSeparator(); 1330 m_pNetworkAccessManager = g ActionPool->action(UIActionIndex_Simple_NetworkAccessManager);1330 m_pNetworkAccessManager = gpActionPool->action(UIActionIndex_Simple_NetworkAccessManager); 1331 1331 pMenu->addAction(m_pNetworkAccessManager); 1332 m_pUpdateAction = g ActionPool->action(UIActionIndex_Simple_CheckForUpdates);1332 m_pUpdateAction = gpActionPool->action(UIActionIndex_Simple_CheckForUpdates); 1333 1333 if (gEDataManager->applicationUpdateEnabled()) 1334 1334 pMenu->addAction(m_pUpdateAction); … … 1339 1339 pMenu->addSeparator(); 1340 1340 #endif /* !Q_WS_MAC */ 1341 m_pAboutAction = g ActionPool->action(UIActionIndex_Simple_About);1341 m_pAboutAction = gpActionPool->action(UIActionIndex_Simple_About); 1342 1342 pMenu->addAction(m_pAboutAction); 1343 1343 } … … 1658 1658 m_pAction_Common_PauseAndResume->blockSignals(true); 1659 1659 m_pAction_Common_PauseAndResume->setChecked(pFirstStartedAction && UIVMItem::isItemPaused(pFirstStartedAction)); 1660 m_pAction_Common_PauseAndResume-> update();1660 m_pAction_Common_PauseAndResume->retranslateUi(); 1661 1661 m_pAction_Common_PauseAndResume->blockSignals(false); 1662 1662 -
trunk/src/VBox/Frontends/VirtualBox/src/selector/UISelectorWindow.h
r51931 r52151 31 31 class QMenu; 32 32 class UIAction; 33 class UIAction State;33 class UIActionPolymorphic; 34 34 class UIMainBar; 35 35 class UIToolBar; … … 191 191 192 192 /* Common Group/Machine actions: */ 193 UIAction State*m_pAction_Common_StartOrShow;193 UIActionPolymorphic *m_pAction_Common_StartOrShow; 194 194 UIAction *m_pAction_Common_PauseAndResume; 195 195 UIAction *m_pAction_Common_Reset; -
trunk/src/VBox/Frontends/VirtualBox/src/selector/graphics/chooser/UIGChooserItemMachine.cpp
r51579 r52151 1141 1141 1142 1142 connect(m_pSettingsButton, SIGNAL(sigButtonClicked()), 1143 g ActionPool->action(UIActionIndexSelector_Simple_Machine_Settings), SLOT(trigger()),1143 gpActionPool->action(UIActionIndexSelector_Simple_Machine_Settings), SLOT(trigger()), 1144 1144 Qt::QueuedConnection); 1145 1145 connect(m_pStartButton, SIGNAL(sigButtonClicked()), 1146 g ActionPool->action(UIActionIndexSelector_State_Common_StartOrShow), SLOT(trigger()),1146 gpActionPool->action(UIActionIndexSelector_State_Common_StartOrShow), SLOT(trigger()), 1147 1147 Qt::QueuedConnection); 1148 1148 connect(m_pPauseButton, SIGNAL(sigButtonClicked()), 1149 g ActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume), SLOT(trigger()),1149 gpActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume), SLOT(trigger()), 1150 1150 Qt::QueuedConnection); 1151 1151 connect(m_pCloseButton, SIGNAL(sigButtonClicked()), 1152 g ActionPool->action(UIActionIndexSelector_Simple_Machine_Close_PowerOff), SLOT(trigger()),1152 gpActionPool->action(UIActionIndexSelector_Simple_Machine_Close_PowerOff), SLOT(trigger()), 1153 1153 Qt::QueuedConnection); 1154 1154 } -
trunk/src/VBox/Frontends/VirtualBox/src/selector/graphics/chooser/UIGChooserModel.cpp
r51679 r52151 530 530 void UIGChooserModel::activateMachineItem() 531 531 { 532 g ActionPool->action(UIActionIndexSelector_State_Common_StartOrShow)->activate(QAction::Trigger);532 gpActionPool->action(UIActionIndexSelector_State_Common_StartOrShow)->activate(QAction::Trigger); 533 533 } 534 534 … … 699 699 { 700 700 /* Check if action is enabled: */ 701 if (!g ActionPool->action(UIActionIndexSelector_Simple_Group_Rename)->isEnabled())701 if (!gpActionPool->action(UIActionIndexSelector_Simple_Group_Rename)->isEnabled()) 702 702 return; 703 703 … … 713 713 { 714 714 /* Check if action is enabled: */ 715 if (!g ActionPool->action(UIActionIndexSelector_Simple_Group_Sort)->isEnabled())715 if (!gpActionPool->action(UIActionIndexSelector_Simple_Group_Sort)->isEnabled()) 716 716 return; 717 717 … … 727 727 { 728 728 /* Check if action is enabled: */ 729 if (!g ActionPool->action(UIActionIndexSelector_Simple_Group_Remove)->isEnabled())729 if (!gpActionPool->action(UIActionIndexSelector_Simple_Group_Remove)->isEnabled()) 730 730 return; 731 731 … … 803 803 { 804 804 /* Check if action is enabled: */ 805 if (!g ActionPool->action(UIActionIndexSelector_Simple_Machine_New)->isEnabled())805 if (!gpActionPool->action(UIActionIndexSelector_Simple_Machine_New)->isEnabled()) 806 806 return; 807 807 … … 827 827 { 828 828 /* Check if action is enabled: */ 829 if (!g ActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup)->isEnabled())829 if (!gpActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup)->isEnabled()) 830 830 return; 831 831 … … 902 902 { 903 903 /* Check if action is enabled: */ 904 if (!g ActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent)->isEnabled())904 if (!gpActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent)->isEnabled()) 905 905 return; 906 906 … … 916 916 { 917 917 /* Check if action is enabled: */ 918 if (!g ActionPool->action(UIActionIndexSelector_Simple_Common_Refresh)->isEnabled())918 if (!gpActionPool->action(UIActionIndexSelector_Simple_Common_Refresh)->isEnabled()) 919 919 return; 920 920 … … 957 957 { 958 958 /* Check if action is enabled: */ 959 if (!g ActionPool->action(UIActionIndexSelector_Simple_Machine_Remove)->isEnabled())959 if (!gpActionPool->action(UIActionIndexSelector_Simple_Machine_Remove)->isEnabled()) 960 960 return; 961 961 … … 1126 1126 /* Context menu for group(s): */ 1127 1127 m_pContextMenuGroup = new QMenu; 1128 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Group_New));1129 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Group_Add));1128 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Group_New)); 1129 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Group_Add)); 1130 1130 m_pContextMenuGroup->addSeparator(); 1131 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Group_Rename));1132 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Group_Remove));1131 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Group_Rename)); 1132 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Group_Remove)); 1133 1133 m_pContextMenuGroup->addSeparator(); 1134 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_State_Common_StartOrShow));1135 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume));1136 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_Reset));1137 m_pContextMenuGroup->addMenu(g ActionPool->action(UIActionIndexSelector_Menu_Group_Close)->menu());1134 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_State_Common_StartOrShow)); 1135 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume)); 1136 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_Reset)); 1137 m_pContextMenuGroup->addMenu(gpActionPool->action(UIActionIndexSelector_Menu_Group_Close)->menu()); 1138 1138 m_pContextMenuGroup->addSeparator(); 1139 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_Discard));1140 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_Refresh));1139 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_Discard)); 1140 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_Refresh)); 1141 1141 m_pContextMenuGroup->addSeparator(); 1142 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_ShowInFileManager));1143 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_CreateShortcut));1142 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_ShowInFileManager)); 1143 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_CreateShortcut)); 1144 1144 m_pContextMenuGroup->addSeparator(); 1145 m_pContextMenuGroup->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Group_Sort));1145 m_pContextMenuGroup->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Group_Sort)); 1146 1146 1147 1147 /* Context menu for machine(s): */ 1148 1148 m_pContextMenuMachine = new QMenu; 1149 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Machine_Settings));1150 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Machine_Clone));1151 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Machine_Remove));1152 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup));1149 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Machine_Settings)); 1150 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Machine_Clone)); 1151 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Machine_Remove)); 1152 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup)); 1153 1153 m_pContextMenuMachine->addSeparator(); 1154 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_State_Common_StartOrShow));1155 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume));1156 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_Reset));1157 m_pContextMenuMachine->addMenu(g ActionPool->action(UIActionIndexSelector_Menu_Machine_Close)->menu());1154 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_State_Common_StartOrShow)); 1155 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Toggle_Common_PauseAndResume)); 1156 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_Reset)); 1157 m_pContextMenuMachine->addMenu(gpActionPool->action(UIActionIndexSelector_Menu_Machine_Close)->menu()); 1158 1158 m_pContextMenuMachine->addSeparator(); 1159 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_Discard));1160 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndex_Simple_LogDialog));1161 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_Refresh));1159 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_Discard)); 1160 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndex_Simple_LogDialog)); 1161 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_Refresh)); 1162 1162 m_pContextMenuMachine->addSeparator(); 1163 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_ShowInFileManager));1164 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Common_CreateShortcut));1163 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_ShowInFileManager)); 1164 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Common_CreateShortcut)); 1165 1165 m_pContextMenuMachine->addSeparator(); 1166 m_pContextMenuMachine->addAction(g ActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent));1166 m_pContextMenuMachine->addAction(gpActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent)); 1167 1167 1168 1168 connect(m_pContextMenuGroup, SIGNAL(hovered(QAction*)), this, SLOT(sltActionHovered(QAction*))); 1169 1169 connect(m_pContextMenuMachine, SIGNAL(hovered(QAction*)), this, SLOT(sltActionHovered(QAction*))); 1170 1170 1171 connect(g ActionPool->action(UIActionIndexSelector_Simple_Group_New), SIGNAL(triggered()),1171 connect(gpActionPool->action(UIActionIndexSelector_Simple_Group_New), SIGNAL(triggered()), 1172 1172 this, SLOT(sltCreateNewMachine())); 1173 connect(g ActionPool->action(UIActionIndexSelector_Simple_Machine_New), SIGNAL(triggered()),1173 connect(gpActionPool->action(UIActionIndexSelector_Simple_Machine_New), SIGNAL(triggered()), 1174 1174 this, SLOT(sltCreateNewMachine())); 1175 connect(g ActionPool->action(UIActionIndexSelector_Simple_Group_Rename), SIGNAL(triggered()),1175 connect(gpActionPool->action(UIActionIndexSelector_Simple_Group_Rename), SIGNAL(triggered()), 1176 1176 this, SLOT(sltEditGroupName())); 1177 connect(g ActionPool->action(UIActionIndexSelector_Simple_Group_Remove), SIGNAL(triggered()),1177 connect(gpActionPool->action(UIActionIndexSelector_Simple_Group_Remove), SIGNAL(triggered()), 1178 1178 this, SLOT(sltUngroupSelectedGroup())); 1179 connect(g ActionPool->action(UIActionIndexSelector_Simple_Machine_Remove), SIGNAL(triggered()),1179 connect(gpActionPool->action(UIActionIndexSelector_Simple_Machine_Remove), SIGNAL(triggered()), 1180 1180 this, SLOT(sltRemoveSelectedMachine())); 1181 connect(g ActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup), SIGNAL(triggered()),1181 connect(gpActionPool->action(UIActionIndexSelector_Simple_Machine_AddGroup), SIGNAL(triggered()), 1182 1182 this, SLOT(sltGroupSelectedMachines())); 1183 connect(g ActionPool->action(UIActionIndexSelector_Simple_Common_Refresh), SIGNAL(triggered()),1183 connect(gpActionPool->action(UIActionIndexSelector_Simple_Common_Refresh), SIGNAL(triggered()), 1184 1184 this, SLOT(sltPerformRefreshAction())); 1185 connect(g ActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent), SIGNAL(triggered()),1185 connect(gpActionPool->action(UIActionIndexSelector_Simple_Machine_SortParent), SIGNAL(triggered()), 1186 1186 this, SLOT(sltSortParentGroup())); 1187 connect(g ActionPool->action(UIActionIndexSelector_Simple_Group_Sort), SIGNAL(triggered()),1187 connect(gpActionPool->action(UIActionIndexSelector_Simple_Group_Sort), SIGNAL(triggered()), 1188 1188 this, SLOT(sltSortGroup())); 1189 1189
Note:
See TracChangeset
for help on using the changeset viewer.