- Timestamp:
- Jul 30, 2020 9:36:35 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/monitor/resource/UIResourceMonitor.cpp
r85547 r85548 1302 1302 updateColumnsMenu(); 1303 1303 1304 if (m_pShowPerformanceMonitorAction)1305 m_pShowPerformanceMonitorAction->setText(tr("Show Performance Monitor"));1306 1304 if (m_pModel) 1307 1305 m_pModel->setColumnCaptions(m_columnTitles); … … 1313 1311 void UIResourceMonitorWidget::showEvent(QShowEvent *pEvent) 1314 1312 { 1315 QAction *pSwitchAction = m_pActionPool->action(UIActionIndexST_M_VMResourceMonitor_S_SwitchToMachinePerformance); 1316 if (pSwitchAction && m_pTableView) 1317 pSwitchAction->setEnabled(m_pTableView->hasSelection()); 1313 if (m_pShowPerformanceMonitorAction && m_pTableView) 1314 m_pShowPerformanceMonitorAction->setEnabled(m_pTableView->hasSelection()); 1318 1315 1319 1316 QIWithRetranslateUI<QWidget>::showEvent(pEvent); … … 1417 1414 { 1418 1415 updateColumnsMenu(); 1419 m_pShowPerformanceMonitorAction = new QAction(this);1420 connect(m_pShowPerformanceMonitorAction, &QAction::triggered, this, &UIResourceMonitorWidget::sltHandleShowPerformanceMonitor);1421 QAction *pSwitchAction = m_pActionPool->action(UIActionIndexST_M_VMResourceMonitor_S_SwitchToMachinePerformance); 1422 if ( pSwitchAction)1423 connect( pSwitchAction, &QAction::triggered, this, &UIResourceMonitorWidget::sltHandleShowPerformanceMonitor);1416 m_pShowPerformanceMonitorAction = 1417 m_pActionPool->action(UIActionIndexST_M_VMResourceMonitor_S_SwitchToMachinePerformance); 1418 1419 if (m_pShowPerformanceMonitorAction) 1420 connect(m_pShowPerformanceMonitorAction, &QAction::triggered, this, &UIResourceMonitorWidget::sltHandleShowPerformanceMonitor); 1424 1421 } 1425 1422 … … 1517 1514 { 1518 1515 Q_UNUSED(deselected); 1519 QAction *pSwitchAction = m_pActionPool->action(UIActionIndexST_M_VMResourceMonitor_S_SwitchToMachinePerformance); 1520 if (pSwitchAction) 1521 pSwitchAction->setEnabled(!selected.isEmpty()); 1516 if (m_pShowPerformanceMonitorAction) 1517 m_pShowPerformanceMonitorAction->setEnabled(!selected.isEmpty()); 1522 1518 } 1523 1519
Note:
See TracChangeset
for help on using the changeset viewer.