Changeset 84046 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Apr 28, 2020 12:57:40 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserModel.cpp
r83962 r84046 1406 1406 void UIChooserModel::saveLastSelectedItem() 1407 1407 { 1408 /* Acquire first selected item: */ 1409 UIChooserItem *pFirstSelectedItem = firstSelectedItem(); 1410 /* If this item is of machine type: */ 1411 if ( pFirstSelectedItem 1412 && pFirstSelectedItem->type() == UIChooserNodeType_Machine) 1413 { 1414 /* Cast to machine item: */ 1415 UIChooserItemMachine *pMachineItem = pFirstSelectedItem->toMachineItem(); 1416 AssertPtrReturnVoid(pMachineItem); 1417 /* If this machine item is of cloud type: */ 1418 if ( pMachineItem->cacheType() == UIVirtualMachineItemType_CloudFake 1419 || pMachineItem->cacheType() == UIVirtualMachineItemType_CloudReal) 1420 { 1421 /* Choose the parent (profile) group item as the last one selected: */ 1422 pFirstSelectedItem = pMachineItem->parentItem(); 1423 } 1424 } 1408 1425 /* Save last selected-item: */ 1409 gEDataManager->setSelectorWindowLastItemChosen( firstSelectedItem() ? firstSelectedItem()->definition() : QString());1426 gEDataManager->setSelectorWindowLastItemChosen(pFirstSelectedItem ? pFirstSelectedItem->definition() : QString()); 1410 1427 } 1411 1428
Note:
See TracChangeset
for help on using the changeset viewer.