Package com.iizigo.swt
Class ValidateWizardDialog
- java.lang.Object
- org.eclipse.jface.window.Window
- org.eclipse.jface.dialogs.Dialog
- org.eclipse.jface.dialogs.TrayDialog
- org.eclipse.jface.dialogs.TitleAreaDialog
- org.eclipse.jface.wizard.WizardDialog
- com.iizigo.swt.ValidateWizardDialog
- All Implemented Interfaces:
org.eclipse.jface.dialogs.IPageChangeProvider
,org.eclipse.jface.operation.IRunnableContext
,org.eclipse.jface.window.IShellProvider
,org.eclipse.jface.wizard.IWizardContainer
,org.eclipse.jface.wizard.IWizardContainer2
public class ValidateWizardDialog extends org.eclipse.jface.wizard.WizardDialog
Overrides the Wizard Dialog to provide an extra Validate button.- Author:
- Christopher Mindus
Field Summary
Fields inherited from class org.eclipse.jface.dialogs.TitleAreaDialog
DLG_IMG_TITLE_BANNER, DLG_IMG_TITLE_ERROR, INFO_MESSAGE, WARNING_MESSAGE
Fields inherited from class org.eclipse.jface.dialogs.Dialog
blockedHandler, buttonBar, DIALOG_DEFAULT_BOUNDS, DIALOG_PERSISTLOCATION, DIALOG_PERSISTSIZE, dialogArea, DLG_IMG_ERROR, DLG_IMG_HELP, DLG_IMG_INFO, DLG_IMG_MESSAGE_ERROR, DLG_IMG_MESSAGE_INFO, DLG_IMG_MESSAGE_WARNING, DLG_IMG_QUESTION, DLG_IMG_WARNING, ELLIPSIS
Constructor Summary
Constructors Constructor Description ValidateWizardDialog(org.eclipse.swt.widgets.Shell parentShell, org.eclipse.jface.wizard.Wizard wizard, org.eclipse.swt.graphics.Image image)
Creates a new wizard dialog for the given wizard.
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
buttonPressed(int id)
Called when a button is pressed.protected void
configureShell(org.eclipse.swt.widgets.Shell newShell)
Processes shell configuration.protected void
createButtonsForButtonBar(org.eclipse.swt.widgets.Composite parent)
Creates the buttons for this dialog's button bar.protected org.eclipse.jface.wizard.ProgressMonitorPart
createProgressMonitorPart(org.eclipse.swt.widgets.Composite composite, org.eclipse.swt.layout.GridLayout pmlayout)
Hook method for subclasses to create a custom progress monitor part.void
run(boolean fork, boolean cancelable, org.eclipse.jface.operation.IRunnableWithProgress runnable)
Starts running a job.static void
setValidate(org.eclipse.jface.wizard.IWizardPage page, IWizardValidator validator)
Sets the validator from a control of a dialog page.void
setValidator(org.eclipse.jface.wizard.IWizardPage page, IWizardValidator validator)
Sets the validate state.Methods inherited from class org.eclipse.jface.wizard.WizardDialog
addPageChangedListener, addPageChangingListener, backPressed, cancelPressed, close, createContents, createDialogArea, finishPressed, firePageChanged, firePageChanging, getButton, getCurrentPage, getProgressMonitor, getSelectedPage, getShellStyle, getWizard, helpPressed, isModal, nextPressed, removePageChangedListener, removePageChangingListener, setButtonLayoutData, setMinimumPageSize, setMinimumPageSize, setModal, setPageSize, setPageSize, setShellStyle, setWizard, showPage, update, updateButtons, updateMessage, updateSize, updateSize, updateTitleBar, updateWindowTitle
Methods inherited from class org.eclipse.jface.dialogs.TitleAreaDialog
getErrorMessage, getInitialSize, getMessage, getTitleArea, getTitleImageLabel, setErrorMessage, setMessage, setMessage, setTitle, setTitleAreaColor, setTitleImage
Methods inherited from class org.eclipse.jface.dialogs.TrayDialog
closeTray, createButtonBar, createHelpControl, getLayout, getTray, handleShellCloseEvent, isDialogHelpAvailable, isHelpAvailable, openTray, setDialogHelpAvailable, setHelpAvailable
Methods inherited from class org.eclipse.jface.dialogs.Dialog
applyDialogFont, convertHeightInCharsToPixels, convertHeightInCharsToPixels, convertHorizontalDLUsToPixels, convertHorizontalDLUsToPixels, convertVerticalDLUsToPixels, convertVerticalDLUsToPixels, convertWidthInCharsToPixels, convertWidthInCharsToPixels, create, createButton, dialogFontIsDefault, getBlockedHandler, getButtonBar, getCancelButton, getDialogArea, getDialogBoundsSettings, getDialogBoundsStrategy, getImage, getInitialLocation, getOKButton, initializeBounds, initializeDialogUnits, isResizable, okPressed, setBlockedHandler, setButtonLayoutFormData, shortenText
Methods inherited from class org.eclipse.jface.window.Window
canHandleShellCloseEvent, constrainShellSize, createShell, getConstrainedShellBounds, getContents, getDefaultImage, getDefaultImages, getDefaultOrientation, getParentShell, getReturnCode, getShell, getShellListener, getWindowManager, handleFontChange, open, setBlockOnOpen, setDefaultImage, setDefaultImages, setDefaultModalParent, setDefaultOrientation, setExceptionHandler, setParentShell, setReturnCode, setWindowManager
Constructor Detail
ValidateWizardDialog
public ValidateWizardDialog(org.eclipse.swt.widgets.Shell parentShell, org.eclipse.jface.wizard.Wizard wizard, org.eclipse.swt.graphics.Image image)
Creates a new wizard dialog for the given wizard.- Parameters:
parentShell
- The parent shell.wizard
- The wizard this dialog is working on.image
- The icon image to use in the new shell.
Method Detail
configureShell
protected void configureShell(org.eclipse.swt.widgets.Shell newShell)
Processes shell configuration.- Overrides:
configureShell
in classorg.eclipse.jface.wizard.WizardDialog
createButtonsForButtonBar
protected void createButtonsForButtonBar(org.eclipse.swt.widgets.Composite parent)
Creates the buttons for this dialog's button bar.- Overrides:
createButtonsForButtonBar
in classorg.eclipse.jface.wizard.WizardDialog
- Parameters:
parent
- The parent composite to contain the buttons.
setValidator
public void setValidator(org.eclipse.jface.wizard.IWizardPage page, IWizardValidator validator)
Sets the validate state.
buttonPressed
protected void buttonPressed(int id)
Called when a button is pressed.- Overrides:
buttonPressed
in classorg.eclipse.jface.wizard.WizardDialog
- Parameters:
id
- The button ID.
run
public void run(boolean fork, boolean cancelable, org.eclipse.jface.operation.IRunnableWithProgress runnable) throws java.lang.reflect.InvocationTargetException, java.lang.InterruptedException
Starts running a job.- Specified by:
run
in interfaceorg.eclipse.jface.operation.IRunnableContext
- Overrides:
run
in classorg.eclipse.jface.wizard.WizardDialog
- Throws:
java.lang.reflect.InvocationTargetException
java.lang.InterruptedException
- See Also:
WizardDialog.run(boolean, boolean, org.eclipse.jface.operation.IRunnableWithProgress)
setValidate
public static void setValidate(org.eclipse.jface.wizard.IWizardPage page, IWizardValidator validator)
Sets the validator from a control of a dialog page.
createProgressMonitorPart
protected org.eclipse.jface.wizard.ProgressMonitorPart createProgressMonitorPart(org.eclipse.swt.widgets.Composite composite, org.eclipse.swt.layout.GridLayout pmlayout)
Hook method for subclasses to create a custom progress monitor part.- Overrides:
createProgressMonitorPart
in classorg.eclipse.jface.wizard.WizardDialog
- Parameters:
composite
- The parent composite-pmlayout
- The layout.- Returns:
- ProgressMonitorPart - the progress monitor part.