use of org.ovirt.engine.ui.uicommonweb.ErrorPopupManager in project ovirt-engine by oVirt.
the class BaseImportNetworksModel method onProviderChosen.
private void onProviderChosen() {
final Provider<?> provider = providers.getSelectedItem();
if (provider == null) {
return;
}
startProgress();
AsyncQuery<List<StoragePool>> dataCenterQuery = new AsyncQuery<>(returnValue -> {
final List<StoragePool> dataCenters = new LinkedList<>(returnValue);
Collections.sort(dataCenters, new NameableComparator());
AsyncQuery<QueryReturnValue> externalNetworksQuery = new AsyncQuery<>(queryReturnValue -> {
if (queryReturnValue.getSucceeded()) {
Map<Network, Set<Guid>> externalNetworkToDataCenters = queryReturnValue.getReturnValue();
providerNetworks.setItems(getExternalNetworks(externalNetworkToDataCenters, dataCenters));
importedNetworks.setItems(new LinkedList<ExternalNetwork>());
} else {
final ErrorPopupManager popupManager = (ErrorPopupManager) TypeResolver.getInstance().resolve(ErrorPopupManager.class);
popupManager.show(ConstantsManager.getInstance().getMessages().failedToListExternalNetworks(queryReturnValue.getExceptionMessage()));
}
stopProgress();
}, true);
AsyncDataProvider.getInstance().getExternalNetworksByProviderId(externalNetworksQuery, provider.getId());
});
AsyncDataProvider.getInstance().getDataCenterList(dataCenterQuery);
}
use of org.ovirt.engine.ui.uicommonweb.ErrorPopupManager in project ovirt-engine by oVirt.
the class ImportVmsModel method showErrorPopup.
private void showErrorPopup(String message) {
final ErrorPopupManager popupManager = (ErrorPopupManager) TypeResolver.getInstance().resolve(ErrorPopupManager.class);
popupManager.show(message);
}
use of org.ovirt.engine.ui.uicommonweb.ErrorPopupManager in project ovirt-engine by oVirt.
the class WebClientConsoleInvoker method openingWindowFailed.
private void openingWindowFailed() {
final ErrorPopupManager popupManager = (ErrorPopupManager) TypeResolver.getInstance().resolve(ErrorPopupManager.class);
popupManager.show(constants.openingNewConsoleWindowFailed());
}
use of org.ovirt.engine.ui.uicommonweb.ErrorPopupManager in project ovirt-engine by oVirt.
the class ConsoleModel method displayUserCantReconnectDialog.
private void displayUserCantReconnectDialog() {
final ErrorPopupManager popupManager = (ErrorPopupManager) TypeResolver.getInstance().resolve(ErrorPopupManager.class);
popupManager.show(ConstantsManager.getInstance().getConstants().userCantReconnectToVm());
}
Aggregations