VirtualBox

Ignore:
Timestamp:
Sep 21, 2020 2:42:17 PM (4 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:9653: Extend cloud provider uninstall event handling done in r140296; First of all, we should wait for current cloud machine refresh tasks to be done before unlocking this waitable event handling; Besides that, we should invalidate current selection to make sure Details pane has no cloud VM information cached.

Location:
trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserModel.cpp

    r85644 r86202  
    11361136                                              UIChooserItemSearchFlag_ExactId));
    11371137    }
     1138}
     1139
     1140void UIChooserModel::sltHandleCloudProviderUninstall(const QUuid &uId)
     1141{
     1142    /* Search for selected cloud machine items: */
     1143    foreach (UIVirtualMachineItem *pItem, selectedMachineItems())
     1144    {
     1145        /* Skip unrelated nodes: */
     1146        AssertPtrReturnVoid(pItem);
     1147        UIVirtualMachineItemCloud *pCloudItem = pItem->toCloud();
     1148        if (!pCloudItem)
     1149            continue;
     1150
     1151        /* Wait for cloud machine refresh task to complete: */
     1152        pCloudItem->waitForAsyncInfoUpdateFinished();
     1153    }
     1154
     1155    /* Call to base-class: */
     1156    UIChooserAbstractModel::sltHandleCloudProviderUninstall(uId);
     1157
     1158    /* Notify about selection invalidated: */
     1159    emit sigSelectionInvalidated();
    11381160}
    11391161
  • trunk/src/VBox/Frontends/VirtualBox/src/manager/chooser/UIChooserModel.h

    r85508 r86202  
    268268        virtual void sltCloudMachineRegistered(const QString &strProviderName, const QString &strProfileName,
    269269                                               const QUuid &uId, const bool fRegistered);
     270        /** Handles event about cloud provider with @a uId being uninstalled. */
     271        virtual void sltHandleCloudProviderUninstall(const QUuid &uId);
    270272    /** @} */
    271273
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette