Changeset 83720 in vbox
- Timestamp:
- Apr 16, 2020 4:41:10 PM (5 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/globals
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/UICloudNetworkingStuff.cpp
r83704 r83720 119 119 } 120 120 121 Q List<UICloudMachine> UICloudNetworkingStuff::listInstances(const CCloudClient &comCloudClient,122 QString &strErrorMessage,123 QWidget *pParent /* = 0 */)121 QMap<QString, QString> UICloudNetworkingStuff::listInstances(const CCloudClient &comCloudClient, 122 QString &strErrorMessage, 123 QWidget *pParent /* = 0 */) 124 124 { 125 125 /* Prepare VM names, ids and states. … … 158 158 else 159 159 { 160 /* Fetch acquired objects to lists: */160 /* Fetch acquired objects to map: */ 161 161 const QVector<QString> instanceIds = comIDs.GetValues(); 162 162 const QVector<QString> instanceNames = comNames.GetValues(); 163 Q List<UICloudMachine> resultList;163 QMap<QString, QString> resultMap; 164 164 for (int i = 0; i < instanceIds.size(); ++i) 165 result List << UICloudMachine(comCloudClient, instanceIds.at(i), instanceNames.at(i));166 return result List;167 } 168 } 169 170 /* Return empty listby default: */171 return Q List<UICloudMachine>();165 resultMap[instanceIds.at(i)] = instanceNames.at(i); 166 return resultMap; 167 } 168 } 169 170 /* Return empty map by default: */ 171 return QMap<QString, QString>(); 172 172 } 173 173 -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UICloudNetworkingStuff.h
r83704 r83720 23 23 24 24 /* GUI includes: */ 25 #include "UICloudMachine.h"26 25 #include "UILibraryDefs.h" 27 26 … … 52 51 const QUuid &uMachineId); 53 52 54 /** Acquires instance list.53 /** Acquires instance map. 55 54 * @param comCloudClient Brings cloud client object. 56 55 * @param strErrorMessage Brings error message container. 57 56 * @param pWidget Brings parent widget to show messages according to, 58 57 * if no parent set, progress will be executed in blocking way. */ 59 SHARED_LIBRARY_STUFF Q List<UICloudMachine> listInstances(const CCloudClient &comCloudClient,60 QString &strErrorMessage,61 QWidget *pParent = 0);62 /** Acquires cloud machine list.58 SHARED_LIBRARY_STUFF QMap<QString, QString> listInstances(const CCloudClient &comCloudClient, 59 QString &strErrorMessage, 60 QWidget *pParent = 0); 61 /** Acquires cloud machine vector. 63 62 * @param comCloudClient Brings cloud client object. 64 63 * @param strErrorMessage Brings error message container.
Note:
See TracChangeset
for help on using the changeset viewer.