Changeset 102422 in vbox
- Timestamp:
- Dec 1, 2023 2:17:26 PM (16 months ago)
- svn:sync-xref-src-repo-rev:
- 160565
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/manager
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.cpp
r102421 r102422 370 370 } 371 371 372 /* Recache current item info if machine or group item selected: */ 373 if (isMachineItemSelected() || isGroupItemSelected()) 374 recacheCurrentItemInformation(); 372 /* Recache current machine item information: */ 373 recacheCurrentMachineItemInformation(); 375 374 } 376 375 … … 454 453 updateToolsMenuGlobal(); 455 454 456 /* Recache current item info if machine or group item selected: */ 457 if (isMachineItemSelected() || isGroupItemSelected()) 458 recacheCurrentItemInformation(); 455 /* Recache current machine item information: */ 456 recacheCurrentMachineItemInformation(); 459 457 460 458 /* Calculate selection type: */ … … 1167 1165 } 1168 1166 1169 void UIVirtualBoxManagerWidget::recacheCurrentItemInformation(bool fDontRaiseErrorPane /* = false */) 1170 { 1167 void UIVirtualBoxManagerWidget::recacheCurrentMachineItemInformation(bool fDontRaiseErrorPane /* = false */) 1168 { 1169 /* Sanity check, this method is for machine or group of machine items: */ 1170 if (!isMachineItemSelected() && !isGroupItemSelected()) 1171 return; 1172 1171 1173 /* Get current item: */ 1172 1174 UIVirtualMachineItem *pItem = currentItem(); … … 1179 1181 if (m_pPaneToolsMachine->currentTool() == UIToolType_Error) 1180 1182 sltHandleToolsPaneIndexChange(); 1181 } 1182 else 1183 { 1184 /* If we were not asked separately: */ 1185 if (!fDontRaiseErrorPane) 1186 { 1187 /* Make sure Error pane raised: */ 1183 1184 /* Propagate current items to the Tools pane: */ 1185 m_pPaneToolsMachine->setItems(currentItems()); 1186 } 1187 /* Otherwise if we were not asked separately to calm down: */ 1188 else if (!fDontRaiseErrorPane) 1189 { 1190 /* Make sure Error pane raised: */ 1191 if (m_pPaneToolsMachine->currentTool() != UIToolType_Error) 1188 1192 m_pPaneToolsMachine->openTool(UIToolType_Error); 1189 1193 1190 /* Propagate last access error to update the Error-pane (if machine selected but inaccessible): */ 1191 if (pItem) 1192 m_pPaneToolsMachine->setErrorDetails(pItem->accessError()); 1193 } 1194 } 1195 1196 /* Propagate current items to update the Details-pane: */ 1197 m_pPaneToolsMachine->setItems(currentItems()); 1198 } 1194 /* Propagate last access error to the Error-pane: */ 1195 if (pItem) 1196 m_pPaneToolsMachine->setErrorDetails(pItem->accessError()); 1197 } 1198 } -
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.h
r102322 r102422 303 303 304 304 /** Handles signal about Chooser-pane selection invalidated. */ 305 void sltHandleChooserPaneSelectionInvalidated() { recacheCurrent ItemInformation(true /* fDontRaiseErrorPane */); }305 void sltHandleChooserPaneSelectionInvalidated() { recacheCurrentMachineItemInformation(true /* fDontRaiseErrorPane */); } 306 306 307 307 /** Handles sliding animation complete signal. … … 358 358 void updateToolsMenuMachine(UIVirtualMachineItem *pItem); 359 359 360 /** Recaches current item information.360 /** Recaches current machine item information. 361 361 * @param fDontRaiseErrorPane Brings whether we should not raise error-pane. */ 362 void recacheCurrent ItemInformation(bool fDontRaiseErrorPane = false);362 void recacheCurrentMachineItemInformation(bool fDontRaiseErrorPane = false); 363 363 /** @} */ 364 364
Note:
See TracChangeset
for help on using the changeset viewer.