Search in sources :

Example 1 with StorageAccountConfig

use of com.microsoft.azure.toolkit.lib.storage.model.StorageAccountConfig in project azure-tools-for-java by Microsoft.

the class SettingsStep method showNewStorageForm.

private void showNewStorageForm() {
    final CreateArmStorageAccountForm form = new CreateArmStorageAccountForm(PluginUtil.getParentShell(), wizard.getSubscription(), wizard.getRegion());
    form.setOnCreate(new Runnable() {

        @Override
        public void run() {
            StorageAccountConfig newStorageAccount = form.getStorageAccount();
            if (newStorageAccount != null) {
                wizard.setNewStorageAccount(newStorageAccount);
                wizard.setWithNewStorageAccount(true);
                wizard.setStorageAccount(null);
                AzureTaskManager.getInstance().runLater(() -> {
                    storageComboBox.add(newStorageAccount.getName() + " (New)", 0);
                    storageComboBox.select(0);
                });
            }
        }
    });
    form.open();
}
Also used : CreateArmStorageAccountForm(com.microsoft.azuretools.azureexplorer.forms.CreateArmStorageAccountForm) StorageAccountConfig(com.microsoft.azure.toolkit.lib.storage.model.StorageAccountConfig)

Aggregations

StorageAccountConfig (com.microsoft.azure.toolkit.lib.storage.model.StorageAccountConfig)1 CreateArmStorageAccountForm (com.microsoft.azuretools.azureexplorer.forms.CreateArmStorageAccountForm)1