private void commonInitialize() { super.initialize(); // Create and set commands UICommand onSaveCommand = new UICommand("OnSave", this); // $NON-NLS-1$ onSaveCommand.setTitle(constants.ok()); onSaveCommand.setIsDefault(true); getCommands().add(onSaveCommand); getCommands().add(getCancelCommand()); // Update data if (getVm() != null) { updateBootableDiskAvailable(); getIsUsingScsiReservation().setIsAvailable(true); } updateDatacenters(); }
protected void forceCreationWarning(ArrayList<String> usedLunsMessages) { ConfirmationModel confirmationModel = new ConfirmationModel(); setConfirmWindow(confirmationModel); confirmationModel.setTitle(constants.forceStorageDomainCreation()); confirmationModel.setMessage(constants.lunsAlreadyPartOfSD()); confirmationModel.setHelpTag(HelpTag.force_lun_disk_creation); confirmationModel.setHashName("force_lun_disk_creation"); // $NON-NLS-1$ confirmationModel.setItems(usedLunsMessages); UICommand forceSaveCommand = new UICommand("OnForceSave", this); // $NON-NLS-1$ forceSaveCommand.setTitle(constants.ok()); forceSaveCommand.setIsDefault(true); confirmationModel.getCommands().add(forceSaveCommand); UICommand cancelconfirmCommand = new UICommand("CancelConfirm", this); // $NON-NLS-1$ cancelconfirmCommand.setTitle(constants.cancel()); cancelconfirmCommand.setIsCancel(true); confirmationModel.getCommands().add(cancelconfirmCommand); }