|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.springframework.richclient.application.support.ApplicationServicesAccessor
org.springframework.richclient.dialog.ApplicationDialog
org.springframework.richclient.dialog.TitledWidgetApplicationDialog
public class TitledWidgetApplicationDialog
Allows to create an applicationDialog in which a given widget can be shown
Don't forget to set the parent component if the parent isn't the application window
| Field Summary | |
|---|---|
static String |
CANCEL_COMMAND_ID
Default Id for cancel command. |
static int |
CANCEL_MODE
Cancel-mode: Cancel button. |
static String |
EXIT_COMMAND_ID
Default Id for exit command. |
static String |
OK_COMMAND_ID
Default Id for ok command. |
static int |
OK_MODE
Ok-mode: OK + Finish button. |
static int |
SELECT_CANCEL_MODE
Select-mode: Select + Cancel button. |
static String |
SELECT_COMMAND_ID
Default Id for select command. |
static String |
SELECT_NONE_COMMAND_ID
Default Id for select command. |
| Fields inherited from class org.springframework.richclient.dialog.ApplicationDialog |
|---|
DEFAULT_CANCEL_COMMAND_ID, DEFAULT_FINISH_COMMAND_ID, DEFAULT_FINISH_SUCCESS_MESSAGE_KEY, DEFAULT_FINISH_SUCCESS_TITLE_KEY, logger, SUCCESS_FINISH_MESSAGE_KEY, SUCCESS_FINISH_TITLE_KEY |
| Fields inherited from interface org.springframework.richclient.dialog.Messagable |
|---|
MESSAGE_PROPERTY |
| Constructor Summary | |
|---|---|
TitledWidgetApplicationDialog(Widget widget)
Create dialog with only OK button |
|
TitledWidgetApplicationDialog(Widget widget,
int mode)
Create dialog in specified mode |
|
TitledWidgetApplicationDialog(Widget widget,
int mode,
String finishId,
String cancelId)
Creation of dialog with full configuration |
|
| Method Summary | |
|---|---|
protected void |
addDialogComponents()
Subclasses may override to customize how this dialog is built. |
void |
addPropertyChangeListener(PropertyChangeListener propertyChangeListener)
Register a listener to all properties of this publisher. |
void |
addPropertyChangeListener(String property,
PropertyChangeListener propertyChangeListener)
Register a listener to a specific property. |
protected JComponent |
createButtonBar()
Return a standardized row of command buttons, right-justified and all of the same size, with OK as the default button, and no mnemonics used, as per the Java Look and Feel guidelines. |
protected JComponent |
createDialogContentPane()
Return the GUI which allows the user to manipulate the business objects related to this dialog. |
protected String |
getCancelCommandId()
Returns the id for the cancel command. |
protected Object[] |
getCommandGroupMembers()
Template getter method to return the commands to populate the dialog button bar. |
protected String |
getFinishCommandId()
Subclasses may override to return a custom message key, default is "okCommand", corresponding to the "&OK" label. |
protected ActionCommand |
getSelectNoneCommand()
|
Widget |
getWidget()
|
protected void |
onAboutToShow()
Template lifecycle method invoked right before the dialog is to become visible. |
protected boolean |
onFinish()
Request invocation of the action taken when the user hits the OK (finish) button. |
protected boolean |
onSelectNone()
Hook called upon executing the select none command. |
protected void |
onWindowClosing()
Template lifecycle method invoked when the dialog's window is closing. |
void |
removePropertyChangeListener(PropertyChangeListener propertyChangeListener)
Remove the listener from all properties of this publisher. |
void |
removePropertyChangeListener(String property,
PropertyChangeListener propertyChangeListener)
Remove the listener from a specific property. |
void |
setCaption(String shortDescription)
|
void |
setDescription(String longDescription)
|
void |
setMessage(Message message)
Set the message. |
void |
setTitle(String title)
Sets the title. |
| Methods inherited from class org.springframework.richclient.application.support.ApplicationServicesAccessor |
|---|
getActiveWindow, getApplication, getApplicationContext, getApplicationName, getApplicationServices, getCommandConfigurer, getComponentFactory, getConversionService, getIconSource, getImageSource, getMessage, getMessage, getMessage, getMessage, getMessages, getMessageSource, getObjectConfigurer, getService |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String OK_COMMAND_ID
public static final String CANCEL_COMMAND_ID
public static final String EXIT_COMMAND_ID
public static final String SELECT_COMMAND_ID
public static final String SELECT_NONE_COMMAND_ID
public static final int OK_MODE
public static final int CANCEL_MODE
public static final int SELECT_CANCEL_MODE
| Constructor Detail |
|---|
public TitledWidgetApplicationDialog(Widget widget)
widget - The widget to show in the dialog
public TitledWidgetApplicationDialog(Widget widget,
int mode)
widget - The widget to show in the dialogmode - The mode of the dialog:
OK_MODE, CANCEL_MODE of SELECT_CANCEL_MODE.
public TitledWidgetApplicationDialog(Widget widget,
int mode,
String finishId,
String cancelId)
widget - The widget to show in the dialogmode - The mode of the dialog:
OK_MODE, CANCEL_MODE of SELECT_CANCEL_MODE.finishId - specific id for the finish commandcancelId - specific id for the cancel command.| Method Detail |
|---|
public Widget getWidget()
protected JComponent createButtonBar()
ApplicationDialog
createButtonBar in class ApplicationDialogprotected Object[] getCommandGroupMembers()
ApplicationDialog
getCommandGroupMembers in class ApplicationDialogprotected ActionCommand getSelectNoneCommand()
protected void addDialogComponents()
ApplicationDialog
addDialogComponents in class ApplicationDialogprotected void onAboutToShow()
ApplicationDialog
onAboutToShow in class ApplicationDialogprotected void onWindowClosing()
ApplicationDialog
onWindowClosing in class ApplicationDialogprotected boolean onFinish()
ApplicationDialogOK (finish) button.
onFinish in class ApplicationDialogprotected boolean onSelectNone()
protected JComponent createDialogContentPane()
OK
and Cancel buttons, in a standard manner.
Any components/objects created at this point need to be disposed in
ApplicationDialog.disposeDialogContentPane().
createDialogContentPane in class ApplicationDialogApplicationDialog.disposeDialogContentPane()public void setTitle(String title)
setTitle in interface TitleConfigurablesetTitle in class ApplicationDialogtitle - the titleprotected String getFinishCommandId()
getFinishCommandId in class ApplicationDialogprotected String getCancelCommandId()
getCancelCommandId in class ApplicationDialogpublic void setCaption(String shortDescription)
setCaption in interface DescriptionConfigurablepublic void setDescription(String longDescription)
setDescription in interface DescriptionConfigurablepublic void setMessage(Message message)
setMessage in interface Messagablepublic void addPropertyChangeListener(PropertyChangeListener propertyChangeListener)
addPropertyChangeListener in interface PropertyChangePublisherpropertyChangeListener - the PropertyChangeListener to register.
public void addPropertyChangeListener(String property,
PropertyChangeListener propertyChangeListener)
addPropertyChangeListener in interface PropertyChangePublisherproperty - the property to monitor.propertyChangeListener - the PropertyChangeListener to register.public void removePropertyChangeListener(PropertyChangeListener propertyChangeListener)
removePropertyChangeListener in interface PropertyChangePublisherpropertyChangeListener - the PropertyChangeListener to remove.
public void removePropertyChangeListener(String property,
PropertyChangeListener propertyChangeListener)
removePropertyChangeListener in interface PropertyChangePublisherproperty - the property that was being monitored.propertyChangeListener - the PropertyChangeListener to remove.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||