1 11 package org.eclipse.update.internal.ui.wizards; 12 13 import org.eclipse.core.runtime.*; 14 import org.eclipse.jface.dialogs.*; 15 import org.eclipse.jface.wizard.*; 16 import org.eclipse.swt.*; 17 import org.eclipse.swt.widgets.*; 18 import org.eclipse.update.internal.ui.parts.*; 19 import org.eclipse.update.operations.*; 20 21 public class ResizableInstallWizardDialog extends WizardDialog { 22 private String title; 23 24 27 public ResizableInstallWizardDialog(Shell parent, IWizard wizard, String title) { 28 super(parent, wizard); 29 setShellStyle(getShellStyle() | SWT.RESIZE); 30 this.title = title; 31 } 32 33 34 37 public void create() { 38 super.create(); 39 40 getShell().setText(title); 41 SWTUtil.setDialogSize(this, 600, 500); 42 } 43 44 45 48 public int open() { 49 IStatus status = OperationsManager.getValidator().validatePlatformConfigValid(); 50 if (status != null) { 51 ErrorDialog.openError( 52 getShell(), 53 null, 54 null, 55 status); 56 return IDialogConstants.ABORT_ID; 57 } 58 59 return super.open(); 60 } 61 } 62 | Popular Tags |