- Timestamp:
- Jul 31, 2020 11:01:41 AM (4 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/globals
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.cpp
r85571 r85572 2270 2270 virtual QString shortcutExtraDataID() const /* override */ 2271 2271 { 2272 return QString("PerformanceM enu");2272 return QString("PerformanceMonitorMenu"); 2273 2273 } 2274 2274 … … 2280 2280 }; 2281 2281 2282 /** Simple action extension, used as ' Export' action class. */2283 class UIActionMenuSelectorPerformance Export : public UIActionSimple2284 { 2285 Q_OBJECT; 2286 2287 public: 2288 2289 /** Constructs action passing @a pParent to the base-class. */ 2290 UIActionMenuSelectorPerformance Export(UIActionPool *pParent)2282 /** Simple action extension, used as 'Perform Export' action class. */ 2283 class UIActionMenuSelectorPerformancePerformExport : public UIActionSimple 2284 { 2285 Q_OBJECT; 2286 2287 public: 2288 2289 /** Constructs action passing @a pParent to the base-class. */ 2290 UIActionMenuSelectorPerformancePerformExport(UIActionPool *pParent) 2291 2291 : UIActionSimple(pParent, 2292 2292 ":/log_viewer_save_32px.png", ":/log_viewer_save_16px.png", … … 2526 2526 m_pool[UIActionIndex_M_Log_S_Refresh] = new UIActionMenuSelectorLogPerformRefresh(this); 2527 2527 m_pool[UIActionIndex_M_Log_S_Save] = new UIActionMenuSelectorLogPerformSave(this); 2528 2529 /* Create 'Performance Monitor' actions: */ 2530 m_pool[UIActionIndex_M_Performance] = new UIActionMenuSelectorPerformance(this); 2531 m_pool[UIActionIndex_M_Performance_S_Export] = new UIActionMenuSelectorPerformancePerformExport(this); 2528 2532 2529 2533 /* Create 'File Manager' actions: */ … … 2564 2568 m_pool[UIActionIndex_M_FileManager_S_Guest_ShowProperties] = new UIActionMenuFileManagerShowProperties(this); 2565 2569 2566 /* Performance Monitor actions: */2567 m_pool[UIActionIndex_M_Performance] = new UIActionMenuSelectorPerformance(this);2568 m_pool[UIActionIndex_M_Performance_S_Export] = new UIActionMenuSelectorPerformanceExport(this);2569 2570 2570 /* Prepare update-handlers for known menus: */ 2571 2571 #ifdef VBOX_WS_MAC … … 2576 2576 m_menuUpdateHandlers[UIActionIndex_M_LogWindow].ptf = &UIActionPool::updateMenuLogViewerWindow; 2577 2577 m_menuUpdateHandlers[UIActionIndex_M_Log].ptf = &UIActionPool::updateMenuLogViewer; 2578 2578 m_menuUpdateHandlers[UIActionIndex_M_Performance].ptf = &UIActionPool::updateMenuPerformanceMonitor; 2579 2579 m_menuUpdateHandlers[UIActionIndex_M_FileManager].ptf = &UIActionPool::updateMenuFileManager; 2580 2580 … … 2875 2875 } 2876 2876 2877 void UIActionPool::updateMenuPerformanceMonitor() 2878 { 2879 /* Get corresponding menu: */ 2880 UIMenu *pMenu = action(UIActionIndex_M_Performance)->menu(); 2881 AssertPtrReturnVoid(pMenu); 2882 /* Clear contents: */ 2883 pMenu->clear(); 2884 2885 /* 'Export' action: */ 2886 pMenu->addAction(action(UIActionIndex_M_Performance_S_Export)); 2887 2888 /* Mark menu as valid: */ 2889 m_invalidations.remove(UIActionIndex_M_Performance); 2890 } 2891 2877 2892 void UIActionPool::updateMenuFileManager() 2878 2893 { -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.h
r85571 r85572 100 100 UIActionIndex_M_Log_S_Refresh, 101 101 UIActionIndex_M_Log_S_Save, 102 103 /* 'Performance' menu actions: */ 104 UIActionIndex_M_Performance, 105 UIActionIndex_M_Performance_S_Export, 102 106 103 107 /* File Manager actions: */ … … 136 140 UIActionIndex_M_FileManager_S_Guest_ShowProperties, 137 141 138 /* Performance Monitor actions: */139 UIActionIndex_M_Performance,140 UIActionIndex_M_Performance_S_Export,141 142 142 /* Maximum index: */ 143 143 UIActionIndex_Max … … 626 626 /** Updates 'Log Viewer' @a pMenu. */ 627 627 virtual void updateMenuLogViewerWrapper(UIMenu *pMenu); 628 628 /** Updates 'Performance Monitor' menu. */ 629 virtual void updateMenuPerformanceMonitor(); 629 630 /** Updates 'File Manager' menu. */ 630 631 virtual void updateMenuFileManager(); -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPoolManager.cpp
r85571 r85572 4201 4201 /* Mark menu as valid: */ 4202 4202 m_invalidations.remove(UIActionIndexST_M_Snapshot); 4203 }4204 4205 void UIActionPoolManager::updateMenuPerformanceMonitor()4206 {4207 /* Get corresponding menu: */4208 UIMenu *pMenu = action(UIActionIndex_M_Performance)->menu();4209 AssertPtrReturnVoid(pMenu);4210 /* Clear contents: */4211 pMenu->clear();4212 4213 /* Populate Performance-menu: */4214 pMenu->addAction(action(UIActionIndex_M_Performance_S_Export));4215 4216 /* Mark menu as valid: */4217 m_invalidations.remove(UIActionIndex_M_Performance);4218 4203 } 4219 4204 -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPoolManager.h
r85571 r85572 287 287 void updateMenuSnapshot(); 288 288 289 /** Updates 'Performance' menu. */290 void updateMenuPerformanceMonitor();291 292 293 289 /** Updates shortcuts. */ 294 290 virtual void updateShortcuts() /* override */;
Note:
See TracChangeset
for help on using the changeset viewer.