Changeset 86570 in vbox for trunk/src/VBox/Frontends/VirtualBox
- Timestamp:
- Oct 14, 2020 11:20:30 AM (4 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserAbstractModel.cpp
r86569 r86570 637 637 638 638 void UIChooserAbstractModel::sltCloudMachineRegistered(const QString &strProviderShortName, const QString &strProfileName, 639 const QUuid &u Id, const bool fRegistered)639 const QUuid &uMachineId, const bool fRegistered) 640 640 { 641 641 /* Search for profile node: */ … … 651 651 { 652 652 /* Remove machine-items with passed id: */ 653 pProfileNode->removeAllNodes(u Id);653 pProfileNode->removeAllNodes(uMachineId); 654 654 655 655 /* If there are no items left: */ … … 666 666 { 667 667 /* Add new machine-item: */ 668 const CCloudMachine comMachine = cloudMachineById(strProviderShortName, strProfileName, u Id);668 const CCloudMachine comMachine = cloudMachineById(strProviderShortName, strProfileName, uMachineId); 669 669 addCloudMachineIntoTheTree(strProfileNodeName, comMachine, true /* make it visible */); 670 670 … … 689 689 } 690 690 691 void UIChooserAbstractModel::sltHandleCloudProviderUninstall(const QUuid &u Id)691 void UIChooserAbstractModel::sltHandleCloudProviderUninstall(const QUuid &uProviderId) 692 692 { 693 693 /* Search for top-level provider node: */ … … 702 702 const QUuid uIteratedId = pGroupNode->property("id").toUuid(); 703 703 AssertReturnVoid(!uIteratedId.isNull()); 704 if (uIteratedId != u Id)704 if (uIteratedId != uProviderId) 705 705 continue; 706 706 -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserAbstractModel.h
r86569 r86570 149 149 * @param strProfileName Brings profile name. */ 150 150 virtual void sltCloudMachineRegistered(const QString &strProviderShortName, const QString &strProfileName, 151 const QUuid &u Id, const bool fRegistered);151 const QUuid &uMachineId, const bool fRegistered); 152 152 /** Handles session @a enmState change for machine with certain @a uMachineId. */ 153 153 virtual void sltSessionStateChanged(const QUuid &uMachineId, const KSessionState enmState); 154 154 /** Handles snapshot change for machine/snapshot with certain @a uMachineId / @a uSnapshotId. */ 155 155 virtual void sltSnapshotChanged(const QUuid &uMachineId, const QUuid &uSnapshotId); 156 /** Handles event about cloud provider with @a u Id being uninstalled. */157 virtual void sltHandleCloudProviderUninstall(const QUuid &u Id);156 /** Handles event about cloud provider with @a uProviderId being uninstalled. */ 157 virtual void sltHandleCloudProviderUninstall(const QUuid &uProviderId); 158 158 /** @} */ 159 159 -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserModel.cpp
r86569 r86570 1079 1079 } 1080 1080 1081 void UIChooserModel::sltLocalMachineRegistered(const QUuid &u Id, const bool fRegistered)1082 { 1083 /* Existing VM unregistered => make sure no item with passed u Id is selected: */1081 void UIChooserModel::sltLocalMachineRegistered(const QUuid &uMachineId, const bool fRegistered) 1082 { 1083 /* Existing VM unregistered => make sure no item with passed uMachineId is selected: */ 1084 1084 if (!fRegistered) 1085 makeSureNoItemWithCertainIdSelected(u Id);1085 makeSureNoItemWithCertainIdSelected(uMachineId); 1086 1086 1087 1087 /* Call to base-class: */ 1088 UIChooserAbstractModel::sltLocalMachineRegistered(u Id, fRegistered);1088 UIChooserAbstractModel::sltLocalMachineRegistered(uMachineId, fRegistered); 1089 1089 1090 1090 /* Existing VM unregistered? */ … … 1098 1098 { 1099 1099 /* Should we show this VM? */ 1100 if (gEDataManager->showMachineInVirtualBoxManagerChooser(u Id))1100 if (gEDataManager->showMachineInVirtualBoxManagerChooser(uMachineId)) 1101 1101 { 1102 1102 /* Rebuild tree for main root: */ 1103 1103 buildTreeForMainRoot(false /* preserve selection */); 1104 1104 /* Select newly added item: */ 1105 setSelectedItem(root()->searchForItem(u Id.toString(),1105 setSelectedItem(root()->searchForItem(uMachineId.toString(), 1106 1106 UIChooserItemSearchFlag_Machine | 1107 1107 UIChooserItemSearchFlag_ExactId)); … … 1111 1111 1112 1112 void UIChooserModel::sltCloudMachineRegistered(const QString &strProviderShortName, const QString &strProfileName, 1113 const QUuid &u Id, const bool fRegistered)1114 { 1115 /* Existing VM unregistered => make sure no item with passed u Id is selected: */1113 const QUuid &uMachineId, const bool fRegistered) 1114 { 1115 /* Existing VM unregistered => make sure no item with passed uMachineId is selected: */ 1116 1116 if (!fRegistered) 1117 makeSureNoItemWithCertainIdSelected(u Id);1117 makeSureNoItemWithCertainIdSelected(uMachineId); 1118 1118 1119 1119 /* Call to base-class: */ 1120 UIChooserAbstractModel::sltCloudMachineRegistered(strProviderShortName, strProfileName, u Id, fRegistered);1120 UIChooserAbstractModel::sltCloudMachineRegistered(strProviderShortName, strProfileName, uMachineId, fRegistered); 1121 1121 1122 1122 /* Existing VM unregistered? */ … … 1132 1132 buildTreeForMainRoot(false /* preserve selection */); 1133 1133 /* Select newly added item: */ 1134 setSelectedItem(root()->searchForItem(u Id.toString(),1134 setSelectedItem(root()->searchForItem(uMachineId.toString(), 1135 1135 UIChooserItemSearchFlag_Machine | 1136 1136 UIChooserItemSearchFlag_ExactId)); … … 1138 1138 } 1139 1139 1140 void UIChooserModel::sltHandleCloudProviderUninstall(const QUuid &u Id)1140 void UIChooserModel::sltHandleCloudProviderUninstall(const QUuid &uProviderId) 1141 1141 { 1142 1142 /* Search for selected cloud machine items: */ … … 1154 1154 1155 1155 /* Call to base-class: */ 1156 UIChooserAbstractModel::sltHandleCloudProviderUninstall(u Id);1156 UIChooserAbstractModel::sltHandleCloudProviderUninstall(uProviderId); 1157 1157 1158 1158 /* Notify about selection invalidated: */ … … 1160 1160 } 1161 1161 1162 void UIChooserModel::sltReloadMachine(const QUuid &u Id)1162 void UIChooserModel::sltReloadMachine(const QUuid &uMachineId) 1163 1163 { 1164 1164 /* Call to base-class: */ 1165 UIChooserAbstractModel::sltReloadMachine(u Id);1165 UIChooserAbstractModel::sltReloadMachine(uMachineId); 1166 1166 1167 1167 /* Should we show this VM? */ 1168 if (gEDataManager->showMachineInVirtualBoxManagerChooser(u Id))1168 if (gEDataManager->showMachineInVirtualBoxManagerChooser(uMachineId)) 1169 1169 { 1170 1170 /* Rebuild tree for main root: */ 1171 1171 buildTreeForMainRoot(false /* preserve selection */); 1172 1172 /* Select newly added item: */ 1173 setSelectedItem(root()->searchForItem(u Id.toString(),1173 setSelectedItem(root()->searchForItem(uMachineId.toString(), 1174 1174 UIChooserItemSearchFlag_Machine | 1175 1175 UIChooserItemSearchFlag_ExactId)); -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserModel.h
r86569 r86570 261 261 /** @name Main event handling stuff. 262 262 * @{ */ 263 /** Handles local machine registering/unregistering for machine with certain @a u Id. */264 virtual void sltLocalMachineRegistered(const QUuid &u Id, const bool fRegistered) /* override */;265 /** Handles cloud machine registering/unregistering for machine with certain @a u Id.263 /** Handles local machine registering/unregistering for machine with certain @a uMachineId. */ 264 virtual void sltLocalMachineRegistered(const QUuid &uMachineId, const bool fRegistered) /* override */; 265 /** Handles cloud machine registering/unregistering for machine with certain @a uMachineId. 266 266 * @param strProviderShortName Brings provider short name. 267 267 * @param strProfileName Brings profile name. */ 268 268 virtual void sltCloudMachineRegistered(const QString &strProviderShortName, const QString &strProfileName, 269 const QUuid &u Id, const bool fRegistered);270 /** Handles event about cloud provider with @a u Id being uninstalled. */271 virtual void sltHandleCloudProviderUninstall(const QUuid &u Id);269 const QUuid &uMachineId, const bool fRegistered); 270 /** Handles event about cloud provider with @a uProviderId being uninstalled. */ 271 virtual void sltHandleCloudProviderUninstall(const QUuid &uProviderId); 272 272 /** @} */ 273 273 274 274 /** @name Children stuff. 275 275 * @{ */ 276 /** Handles reload machine with certain @a u Id request. */277 virtual void sltReloadMachine(const QUuid &u Id) /* override */;276 /** Handles reload machine with certain @a uMachineId request. */ 277 virtual void sltReloadMachine(const QUuid &uMachineId) /* override */; 278 278 /** @} */ 279 279
Note:
See TracChangeset
for help on using the changeset viewer.