|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--javax.swing.AbstractAction | +--com.borland.primetime.actions.UpdateAction | +--com.borland.primetime.wizard.WizardAction
A WizardAction is a type of UpdateAction that represents a Wizard.
WizardActions are registered by calling the static method:
WizardManager.registerWizardAction(WizardAction wizard)
A WizardAction functions as a regular Action object - it stores the shortText, longText, icon, and enabled state for a Wizard. When invoked, a WizardAction will create the associated Wizard and display it in the WizardDialog.
The WizardAction adds several properties to the UpdateAction designed to support different aspects of Wizards. The 'galleryWizard' property is used to define where the Wizard should appear in the Browser UI. The 'category' property is used to define a sub-category (Gallery tab) to place Wizard under. The 'largeIcon' property is used to when the WizardAction is displayed in the Gallery.
The only WizardAction method that needs to be overridden by a subclass
is the createWizard() method. When the WizardAction is invoked, the a
WizardDialog is created with the contained Wizard, and the Wizard session is
started. The protected method protected abstract Wizard createWizard()
must be overridden to instantiate the Wizard when it is invoked. This
method is called each time the Wizard is invoked, and the resources are
released after the Wizard is complete.
UpdateAction
,
Wizard
, Serialized FormField Summary | |
static java.lang.String |
CATEGORY
The storage attribute key for the CATEGORY (String) property. |
static java.lang.String |
GALLERY_WIZARD
The storage attribute key for the GALLERY_WIZARD (Boolean) property. |
Fields inherited from class com.borland.primetime.actions.UpdateAction |
ACCELERATOR,
EMPTY_ARRAY,
HELP_TOPIC,
LARGE_ICON,
MNEMONIC |
Fields inherited from class javax.swing.AbstractAction |
changeSupport,
enabled |
Constructor Summary | |
WizardAction()
Constructs a WizardAction will all default properties. |
|
WizardAction(java.lang.String shortText)
Constructs a WizardAction will the specified short text. |
|
WizardAction(java.lang.String shortText,
char mnemonic)
Constructs a WizardAction will the specified short text and mnemonic. |
|
WizardAction(java.lang.String shortText,
char mnemonic,
java.lang.String longText)
Constructs a WizardAction will the specified short text, mnemonic, and long text. |
|
WizardAction(java.lang.String shortText,
char mnemonic,
java.lang.String longText,
javax.swing.Icon smallIcon)
Constructs a WizardAction will the specified short text, mnemonic, long text, and small icon. |
|
WizardAction(java.lang.String shortText,
char mnemonic,
java.lang.String longText,
javax.swing.Icon smallIcon,
javax.swing.Icon largeIcon)
Constructs a WizardAction will the specified short text, mnemonic, long text, small icon, and large icon. |
|
WizardAction(java.lang.String shortText,
char mnemonic,
java.lang.String longText,
javax.swing.Icon smallIcon,
javax.swing.Icon largeIcon,
boolean galleryWizard)
Constructs a WizardAction will the specified short text, mnemonic, long text, small icon, large icon, and galleryWizard setting. |
|
WizardAction(java.lang.String shortText,
char mnemonic,
java.lang.String longText,
javax.swing.Icon smallIcon,
javax.swing.Icon largeIcon,
boolean galleryWizard,
java.lang.String category)
Constructs a WizardAction will the specified short text, mnemonic, long text, small icon, large icon, galleryWizard setting, and category. |
Method Summary | |
void |
actionPerformed(java.awt.event.ActionEvent e)
The default behavior of this method is to invoke the wizard. |
protected abstract Wizard |
createWizard()
Override this method to defer the instantiation of the Wizard until is is actually invoked. |
java.lang.String |
getCategory()
Returns the category for this WizardAction. |
void |
invokeWizard(Browser browser)
The default behavior of this method is to obtain a new Wizard instance and invoke the WizardDialog with it. |
boolean |
isGalleryWizard()
Returns the galleryWizard property setting. |
void |
setCategory(java.lang.String category)
Sets the category for this WizardAction. |
void |
setGalleryWizard(boolean galleryWizard)
Sets the boolean galleryWizard flag for this WizardAction. |
Methods inherited from class com.borland.primetime.actions.UpdateAction |
getHelpTopic,
getLargeIcon,
getLongText,
getMnemonic,
getShortText,
getSmallIcon,
setHelpTopic,
setLargeIcon,
setLongText,
setMnemonic,
setShortText,
setSmallIcon,
update |
Methods inherited from class javax.swing.AbstractAction |
addPropertyChangeListener,
clone,
firePropertyChange,
getValue,
isEnabled,
putValue,
removePropertyChangeListener,
setEnabled |
Methods inherited from class java.lang.Object |
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
Field Detail |
public static final java.lang.String GALLERY_WIZARD
public static final java.lang.String CATEGORY
Constructor Detail |
public WizardAction()
public WizardAction(java.lang.String shortText)
shortText
- The short text for the WizardActionpublic WizardAction(java.lang.String shortText, char mnemonic)
shortText
- The short text for the WizardActionmnemonic
- The mnemonic character for the WizardActionpublic WizardAction(java.lang.String shortText, char mnemonic, java.lang.String longText)
shortText
- The short text for the WizardActionmnemonic
- The mnemonic character for the WizardActionlongText
- The long text for the WizardActionpublic WizardAction(java.lang.String shortText, char mnemonic, java.lang.String longText, javax.swing.Icon smallIcon)
shortText
- The short text for the WizardActionmnemonic
- The mnemonic character for the WizardActionlongText
- The long text for the WizardActionsmallIcon
- The small icon for the WizardAction (16x16)public WizardAction(java.lang.String shortText, char mnemonic, java.lang.String longText, javax.swing.Icon smallIcon, javax.swing.Icon largeIcon)
shortText
- The short text for the WizardActionmnemonic
- The mnemonic character for the WizardActionlongText
- The long text for the WizardActionsmallIcon
- The small icon for the WizardAction (16x16)largeIcon
- The large icon for the WizardAction (32x32)public WizardAction(java.lang.String shortText, char mnemonic, java.lang.String longText, javax.swing.Icon smallIcon, javax.swing.Icon largeIcon, boolean galleryWizard)
shortText
- The short text for the WizardActionmnemonic
- The mnemonic character for the WizardActionlongText
- The long text for the WizardActionsmallIcon
- The small icon for the WizardAction (16x16)largeIcon
- The large icon for the WizardAction (32x32)galleryWizard
- true to appear in the gallery, false to appear on the
wizards menupublic WizardAction(java.lang.String shortText, char mnemonic, java.lang.String longText, javax.swing.Icon smallIcon, javax.swing.Icon largeIcon, boolean galleryWizard, java.lang.String category)
shortText
- The short text for the WizardActionmnemonic
- The mnemonic character for the WizardActionlongText
- The long text for the WizardActionsmallIcon
- The small icon for the WizardAction (16x16)largeIcon
- The large icon for the WizardAction (32x32)galleryWizard
- true to appear in the gallery, false to appear on the
wizards menucategory
- The category for this WizardActionMethod Detail |
public void setGalleryWizard(boolean galleryWizard)
galleryWizard
- true for the wizard to appear in the gallery, false
for the wizard to appear on the wizards menupublic boolean isGalleryWizard()
public void setCategory(java.lang.String category)
category
- The category for the WizardActionpublic java.lang.String getCategory()
protected abstract Wizard createWizard()
public final void invokeWizard(Browser browser)
The default behavior of this method is to obtain a new Wizard instance and invoke the WizardDialog with it. This method cannot be overridden, but createWizard *must* be.
public final void actionPerformed(java.awt.event.ActionEvent e)
The default behavior of this method is to invoke the wizard.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |