Changeset 78166 in vbox for trunk/src/VBox
- Timestamp:
- Apr 17, 2019 2:46:26 PM (6 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.cpp
r77190 r78166 1660 1660 } 1661 1661 1662 void UIMessageCenter::cannotAcquireCloudClientParameter(const CProgress &comProgress, QWidget *pParent /* = 0 */) const 1663 { 1664 error(pParent, MessageType_Error, 1665 tr("Failed to acquire cloud client parameter."), 1666 UIErrorString::formatErrorInfo(comProgress)); 1667 } 1668 1662 1669 bool UIMessageCenter::confirmCloudProfileRemoval(const QString &strName, QWidget *pParent /* = 0 */) const 1663 1670 { -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIMessageCenter.h
r77190 r78166 373 373 void cannotCreateCloudClient(const CCloudProfile &comProfile, QWidget *pParent = 0) const; 374 374 void cannotAcquireCloudClientParameter(const CCloudClient &comClient, QWidget *pParent = 0) const; 375 void cannotAcquireCloudClientParameter(const CProgress &comProgress, QWidget *pParent = 0) const; 375 376 bool confirmCloudProfileRemoval(const QString &strName, QWidget *pParent = 0) const; 376 377 bool confirmCloudProfilesImport(QWidget *pParent = 0) const; -
trunk/src/VBox/Frontends/VirtualBox/src/wizards/importappliance/UIWizardImportAppPageBasic1.cpp
r78148 r78166 37 37 #include "UIWizardImportAppPageBasic1.h" 38 38 #include "UIWizardImportAppPageBasic2.h" 39 40 /* COM includes: */ 41 #include "CStringArray.h" 39 42 40 43 … … 278 281 else 279 282 { 280 #if 0 281 /* Read Cloud Client instances: */282 QVector<QString> vmNames;283 /*const QVector<QString> vmIDs =*/284 m_comCloudClient.ListInstances(KCloudMachineState_Running, vmNames); 283 /* Read Cloud Client VM instances: */ 284 CStringArray comNames; 285 CStringArray comIDs; 286 CProgress comProgress = m_comCloudClient.ListInstances(KCloudMachineState_Running, comNames, comIDs); 287 285 288 /* Show error message if necessary: */ 286 289 if (!m_comCloudClient.isOk()) … … 288 291 else 289 292 { 290 /* Push acquired names to list rows: */ 291 for (int i = 0; i < vmNames.size(); ++i) 293 /* Show "Acquire cloud instances" progress: */ 294 msgCenter().showModalProgressDialog(comProgress, 295 UIWizardImportApp::tr("Acquire cloud instances..."), 296 ":/progress_reading_appliance_90px.png"); 297 298 /* Show error message if necessary: */ 299 if (!comProgress.isOk() || comProgress.GetResultCode() != 0) 300 msgCenter().cannotAcquireCloudClientParameter(comProgress); 301 else 292 302 { 293 /* Create list item: */ 294 QListWidgetItem *pItem = new QListWidgetItem(vmNames.at(i), m_pAccountInstanceList); 295 if (pItem) 303 /* Push acquired names to list rows: */ 304 foreach (const QString &strName, comNames.GetValues()) 296 305 { 297 /* Make item non-editable: */ 298 pItem->setFlags(pItem->flags() & ~Qt::ItemIsEditable); 306 /* Create list item: */ 307 QListWidgetItem *pItem = new QListWidgetItem(strName, m_pAccountInstanceList); 308 if (pItem) 309 { 310 /* Make item non-editable: */ 311 pItem->setFlags(pItem->flags() & ~Qt::ItemIsEditable); 312 } 299 313 } 300 314 } 301 315 } 302 #else // XXX: uwe303 msgCenter().cannotAcquireCloudClientParameter(m_comCloudClient);304 #endif305 316 } 306 317 } … … 729 740 if (isSourceCloudOne()) 730 741 { 742 /* Read Cloud Client description form: */ 731 743 CVirtualSystemDescriptionForm comForm; 732 744 CProgress comProgress = m_comCloudClient.GetExportLaunchDescriptionForm(comForm); 745 733 746 /* Show error message if necessary: */ 734 747 if (!m_comCloudClient.isOk()) 735 748 { 736 /// @todo add real error message 737 //msgCenter().cannotAcquireExportLaunchDescriptionForm(comCloudClient, this); 749 msgCenter().cannotAcquireCloudClientParameter(m_comCloudClient); 738 750 return false; 739 751 } … … 741 753 { 742 754 /* Show "Acquire export form" progress: */ 743 msgCenter().showModalProgressDialog(comProgress, UIWizardImportApp::tr("Acquire export form..."), 744 ":/progress_media_move_90px.png", this); 755 msgCenter().showModalProgressDialog(comProgress, 756 UIWizardImportApp::tr("Acquire export form..."), 757 ":/progress_reading_appliance_90px.png"); 745 758 746 759 /* Show error message if necessary: */ 747 760 if (!comProgress.isOk() || comProgress.GetResultCode() != 0) 748 761 { 749 /// @todo add real error message 750 //msgCenter().cannotAcquireExportLaunchDescriptionForm(comProgress, this); 762 msgCenter().cannotAcquireCloudClientParameter(m_comCloudClient); 751 763 return false; 752 764 }
Note:
See TracChangeset
for help on using the changeset viewer.