- Timestamp:
- Oct 20, 2020 2:59:16 PM (4 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/manager
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManager.cpp
r86345 r86655 512 512 } 513 513 514 void UIVirtualBoxManager::sltHandleCloudUpdateProgressChange() 515 { 516 updateActionsAppearance(); 517 } 518 514 519 void UIVirtualBoxManager::sltHandleToolTypeChange() 515 520 { … … 2087 2092 connect(m_pWidget, &UIVirtualBoxManagerWidget::sigGroupSavingStateChanged, 2088 2093 this, &UIVirtualBoxManager::sltHandleGroupSavingProgressChange); 2094 connect(m_pWidget, &UIVirtualBoxManagerWidget::sigCloudUpdateStateChanged, 2095 this, &UIVirtualBoxManager::sltHandleCloudUpdateProgressChange); 2089 2096 connect(m_pWidget, &UIVirtualBoxManagerWidget::sigStartOrShowRequest, 2090 2097 this, &UIVirtualBoxManager::sltPerformStartOrShowMachine); … … 2380 2387 } 2381 2388 2389 bool UIVirtualBoxManager::isCloudUpdateInProgress() const 2390 { 2391 return m_pWidget->isCloudUpdateInProgress(); 2392 } 2393 2382 2394 void UIVirtualBoxManager::openAddMachineDialog(const QString &strFileName /* = QString() */) 2383 2395 { … … 3178 3190 { 3179 3191 return !isGroupSavingInProgress() && 3192 (isItemsLocal(items) || !isCloudUpdateInProgress()) && 3180 3193 isAtLeastOneItemRemovable(items); 3181 3194 } -
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManager.h
r86344 r86655 131 131 /** Handles signal about group saving progress change. */ 132 132 void sltHandleGroupSavingProgressChange(); 133 /** Handles signal about cloud update progress change. */ 134 void sltHandleCloudUpdateProgressChange(); 133 135 134 136 /** Handles singal about Tool type change. */ … … 360 362 /** Returns whether single cloud profile group is selected. */ 361 363 bool isSingleCloudProfileGroupSelected() const; 364 365 /** Returns whether cloud update is in progress. */ 366 bool isCloudUpdateInProgress() const; 362 367 /** @} */ 363 368 -
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.cpp
r86344 r86655 117 117 } 118 118 119 bool UIVirtualBoxManagerWidget::isCloudUpdateInProgress() const 120 { 121 return m_pPaneChooser->isCloudUpdateInProgress(); 122 } 123 119 124 void UIVirtualBoxManagerWidget::openGroupNameEditor() 120 125 { … … 675 680 connect(m_pPaneChooser, &UIChooser::sigGroupSavingStateChanged, 676 681 this, &UIVirtualBoxManagerWidget::sigGroupSavingStateChanged); 682 connect(m_pPaneChooser, &UIChooser::sigCloudUpdateStateChanged, 683 this, &UIVirtualBoxManagerWidget::sigCloudUpdateStateChanged); 677 684 connect(m_pPaneChooser, &UIChooser::sigToolMenuRequested, 678 685 this, &UIVirtualBoxManagerWidget::sltHandleToolMenuRequested); … … 940 947 disconnect(m_pPaneChooser, &UIChooser::sigGroupSavingStateChanged, 941 948 this, &UIVirtualBoxManagerWidget::sigGroupSavingStateChanged); 949 disconnect(m_pPaneChooser, &UIChooser::sigCloudUpdateStateChanged, 950 this, &UIVirtualBoxManagerWidget::sigCloudUpdateStateChanged); 942 951 disconnect(m_pPaneChooser, &UIChooser::sigToolMenuRequested, 943 952 this, &UIVirtualBoxManagerWidget::sltHandleToolMenuRequested); -
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.h
r86233 r86655 70 70 /** Notifies about Chooser-pane group saving change. */ 71 71 void sigGroupSavingStateChanged(); 72 /** Notifies about Chooser-pane cloud update change. */ 73 void sigCloudUpdateStateChanged(); 72 74 73 75 /** Notifies about state change for cloud machine with certain @a uId. */ … … 145 147 /** Returns whether group saving is in progress. */ 146 148 bool isGroupSavingInProgress() const; 149 /** Returns whether cloud update is in progress. */ 150 bool isCloudUpdateInProgress() const; 147 151 148 152 /** Opens group name editor. */ -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooser.cpp
r85508 r86655 46 46 } 47 47 48 bool UIChooser::isCloudUpdateInProgress() const 49 { 50 AssertPtrReturn(model(), false); 51 return model()->isCloudUpdateInProgress(); 52 } 53 48 54 UIVirtualMachineItem *UIChooser::currentItem() const 49 55 { … … 241 247 connect(model(), &UIChooserModel::sigGroupSavingStateChanged, 242 248 this, &UIChooser::sigGroupSavingStateChanged); 249 connect(model(), &UIChooserModel::sigCloudUpdateStateChanged, 250 this, &UIChooser::sigCloudUpdateStateChanged); 243 251 244 252 /* Chooser-model connections: */ … … 287 295 disconnect(model(), &UIChooserModel::sigGroupSavingStateChanged, 288 296 this, &UIChooser::sigGroupSavingStateChanged); 297 disconnect(model(), &UIChooserModel::sigCloudUpdateStateChanged, 298 this, &UIChooser::sigCloudUpdateStateChanged); 289 299 290 300 /* Chooser-model connections: */ -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooser.h
r85508 r86655 53 53 /** @} */ 54 54 55 /** @name Cloud update stuff. 56 * @{ */ 57 /** Notifies listeners about cloud update state change. */ 58 void sigCloudUpdateStateChanged(); 59 /** @} */ 60 55 61 /** @name Tool stuff. 56 62 * @{ */ … … 103 109 /** Returns whether group saving is in progress. */ 104 110 bool isGroupSavingInProgress() const; 111 /** @} */ 112 113 /** @name Cloud update stuff. 114 * @{ */ 115 /** Returns whether cloud update is in progress. */ 116 bool isCloudUpdateInProgress() const; 105 117 /** @} */ 106 118 -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserAbstractModel.cpp
r86631 r86655 585 585 { 586 586 m_cloudAccountKeysBeingUpdated.insert(key); 587 emit sigCloudUpdateStateChanged(); 587 588 } 588 589 … … 590 591 { 591 592 m_cloudAccountKeysBeingUpdated.remove(key); 593 emit sigCloudUpdateStateChanged(); 592 594 } 593 595 … … 595 597 { 596 598 return m_cloudAccountKeysBeingUpdated.contains(key); 599 } 600 601 bool UIChooserAbstractModel::isCloudUpdateInProgress() const 602 { 603 return !m_cloudAccountKeysBeingUpdated.isEmpty(); 597 604 } 598 605 … … 1059 1066 strProfileName, 1060 1067 true /* with refresh? */); 1061 if (pTask)1062 1068 AssertPtrReturnVoid(pTask); 1069 uiCommon().threadPoolCloud()->enqueueTask(pTask); 1063 1070 } 1064 1071 } -
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserAbstractModel.h
r86631 r86655 65 65 /** @} */ 66 66 67 /** @name Cloud update stuff. 68 * @{ */ 69 /** Notifies listeners about cloud update state changed. */ 70 void sigCloudUpdateStateChanged(); 71 /** @} */ 72 67 73 public: 68 74 … … 133 139 /** Returns whether cloud account @a key is a part of key set currently being updated. */ 134 140 bool containsCloudAccountKey(const UICloudAccountKey &key) const; 141 /** Returns whether at least one cloud account update is in progress. */ 142 bool isCloudUpdateInProgress() const; 135 143 /** @} */ 136 144
Note:
See TracChangeset
for help on using the changeset viewer.