Changeset 52555 in vbox
- Timestamp:
- Sep 1, 2014 4:29:03 PM (11 years ago)
- svn:sync-xref-src-repo-rev:
- 95816
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/globals
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.cpp
r52477 r52555 59 59 UIMenu::UIMenu() 60 60 : m_fShowToolTip(false) 61 #ifdef Q_WS_MAC 62 , m_fConsumable(false) 63 , m_fConsumed(false) 64 #endif /* Q_WS_MAC */ 61 65 { 62 66 } … … 97 101 * It will be set explicitly later. */ 98 102 setMenuRole(QAction::NoRole); 103 } 104 105 UIMenu* UIAction::menu() const 106 { 107 return qobject_cast<UIMenu*>(QAction::menu()); 99 108 } 100 109 -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.h
r52470 r52555 80 80 81 81 82 /** QMenu extension 83 * allowing to show tool-tips. */ 82 /** QMenu extension. */ 84 83 class UIMenu : public QMenu 85 84 { … … 94 93 void setShowToolTip(bool fShowToolTips) { m_fShowToolTip = fShowToolTips; } 95 94 95 #ifdef Q_WS_MAC 96 /** Mac OS X: Returns whether this menu is consumable by the menu-bar. */ 97 bool isConsumable() const { return m_fConsumable; } 98 /** Mac OS X: Defines whether this menu is @a fConsumable by the menu-bar. */ 99 void setConsumable(bool fConsumable) { m_fConsumable = fConsumable; } 100 101 /** Mac OS X: Returns whether this menu is consumed by the menu-bar. */ 102 bool isConsumed() const { return m_fConsumed; } 103 /** Mac OS X: Defines whether this menu is @a fConsumed by the menu-bar. */ 104 void setConsumed(bool fConsumed) { m_fConsumed = fConsumed; } 105 #endif /* Q_WS_MAC */ 106 96 107 protected: 97 108 … … 103 114 /** Holds whether tool-tip should be shown. */ 104 115 bool m_fShowToolTip; 116 117 #ifdef Q_WS_MAC 118 /** Mac OS X: Holds whether this menu can be consumed by the menu-bar. */ 119 bool m_fConsumable; 120 /** Mac OS X: Holds whether this menu is consumed by the menu-bar. */ 121 bool m_fConsumed; 122 #endif /* Q_WS_MAC */ 105 123 }; 106 124 … … 115 133 /** Returns action type. */ 116 134 UIActionType type() const { return m_type; } 135 136 /** Returns menu contained by this action. */ 137 UIMenu* menu() const; 117 138 118 139 /** Returns action-pool this action belongs to. */
Note:
See TracChangeset
for help on using the changeset viewer.