|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.globalmentor.beans.BoundPropertyObject
com.guiseframework.event.GuiseBoundPropertyObject
com.guiseframework.model.ui.AbstractPresentationModel
com.guiseframework.component.AbstractComponent
com.guiseframework.component.AbstractCompositeComponent
com.guiseframework.component.AbstractMultipleCompositeComponent
com.guiseframework.component.AbstractArrayCompositeComponent
com.guiseframework.component.AbstractEnumCompositeComponent<AbstractFrame.FrameComponent>
com.guiseframework.component.AbstractFrame
public abstract class AbstractFrame
Abstract implementation of a frame.
This implementation notifies the user when the frame does not validate in validate().
| Nested Class Summary | |
|---|---|
protected class |
AbstractFrame.DefaultPrototypeProvider
The default implementation of a prototype provider for a frame. |
protected static class |
AbstractFrame.FrameComponent
The enumeration of frame components. |
| Nested classes/interfaces inherited from class com.guiseframework.component.AbstractComponent |
|---|
AbstractComponent.AbstractFlyoverFrameStrategy<S extends Component>, AbstractComponent.AbstractFlyoverStrategy<S extends Component>, AbstractComponent.DefaultFlyoverStrategy<S extends Component> |
| Nested classes/interfaces inherited from interface com.guiseframework.component.Frame |
|---|
Frame.Mode, Frame.State |
| Field Summary |
|---|
| Fields inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
NO_PROPERTY_CHANGE_LISTENERS, NO_VETOABLE_CHANGE_LISTENERS |
| Fields inherited from interface com.guiseframework.component.Frame |
|---|
CLOSE_ACTION_CONTROL_PROPERTY, MENU_PROPERTY, MODAL_PROPERTY, MOVABLE_PROPERTY, OPEN_EFFECT_PROPERTY, RELATED_COMPONENT_PROPERTY, RESIZABLE_PROPERTY, STATE_PROPERTY, TITLE_BACKGROUND_COLOR_PROPERTY, TITLE_VISIBLE_PROPERTY, TOOLBAR_PROPERTY |
| Fields inherited from interface com.guiseframework.component.ContentComponent |
|---|
CONTENT_PROPERTY |
| Fields inherited from interface com.guiseframework.component.ModalComponent |
|---|
MODE_PROPERTY |
| Fields inherited from interface com.guiseframework.component.InputFocusGroupComponent |
|---|
INPUT_FOCUS_STRATEGY_PROPERTY, INPUT_FOCUSED_COMPONENT_PROPERTY |
| Constructor Summary | |
|---|---|
AbstractFrame(Component component)
Component constructor. |
|
| Method Summary | |
|---|---|
boolean |
canClose()
Determines whether the frame should be allowed to close. |
void |
close()
Closes the frame. |
protected void |
closeImpl()
Implementation of frame closing. |
ActionControl |
getCloseActionControl()
|
ActionPrototype |
getCloseActionPrototype()
|
Component |
getContent()
|
InputFocusableComponent |
getInputFocusedComponent()
Indicates the component within this group that has the input focus. |
InputFocusStrategy |
getInputFocusStrategy()
|
Menu |
getMenu()
|
Frame.Mode |
getMode()
|
Effect |
getOpenEffect()
|
protected FrameMenuToolPrototypeProvisionStrategy |
getPrototypeProvisionStrategy()
|
Component |
getRelatedComponent()
|
Frame.State |
getState()
|
Color |
getTitleBackgroundColor()
|
Toolbar |
getToolbar()
|
boolean |
isModal()
|
boolean |
isMovable()
|
boolean |
isResizable()
|
boolean |
isTitleVisible()
|
void |
open()
Opens the frame with the currently set modality. |
void |
open(boolean modal)
Opens the frame, specifying modality. |
void |
open(com.globalmentor.beans.GenericPropertyChangeListener<Frame.Mode> modeChangeListener)
Opens the frame as modal and installs the given property change listener to listen for the mode changing. |
protected java.util.Set<PrototypeProvision<?>> |
provideDefaultPrototypes()
Provides default prototype provisions to be integrated into the menu and/or toolbar. |
void |
setCloseActionControl(ActionControl newCloseActionControl)
Sets the action control for closing the frame. |
void |
setContent(Component newContent)
Sets the content child component. |
void |
setInputFocusedComponent(InputFocusableComponent newInputFocusedComponent)
Sets the focused component within this input focus group. |
void |
setInputFocusStrategy(InputFocusStrategy newInputFocusStrategy)
Sets the input focus strategy. |
void |
setMenu(Menu newMenu)
Sets the frame menu. |
void |
setModal(boolean newModal)
Sets whether the frame is modal if and when it is open. |
void |
setMode(Frame.Mode newMode)
Sets the mode of interaction. |
void |
setMovable(boolean newMovable)
Sets whether the frame is movable. |
void |
setOpenEffect(Effect newOpenEffect)
Sets the effect used for opening the frame. |
void |
setRelatedComponent(Component newRelatedComponent)
Sets the related component. |
void |
setResizable(boolean newResizable)
Sets whether the frame can be resized. |
protected void |
setState(Frame.State newState)
Sets the state of the frame. |
void |
setTitleBackgroundColor(Color newTitleBackgroundColor)
Sets the background color of the title. |
void |
setTitleVisible(boolean newTitleVisible)
Sets whether the title bar is visible. |
void |
setToolbar(Toolbar newToolbar)
Sets the frame toolbar. |
protected void |
updateDefaultPrototypeProvisions()
Updates the default prototype provisions. |
boolean |
validate()
Validates the user input of this component and all child components. |
| Methods inherited from class com.guiseframework.component.AbstractEnumCompositeComponent |
|---|
getComponent, setComponent |
| Methods inherited from class com.guiseframework.component.AbstractArrayCompositeComponent |
|---|
getChildComponents, getChildList, getComponent, hasChildComponents, setComponent |
| Methods inherited from class com.guiseframework.component.AbstractMultipleCompositeComponent |
|---|
addComponent, removeComponent |
| Methods inherited from class com.guiseframework.event.GuiseBoundPropertyObject |
|---|
getSession |
| Methods inherited from class com.globalmentor.beans.BoundPropertyObject |
|---|
addPropertyChangeListener, addPropertyChangeListener, addVetoableChangeListener, addVetoableChangeListener, createPostponedPropertyChangeEvent, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, fireVetoableChange, getForwardPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, getPropertyChangeSupport, getRepeatPropertyChangeListener, getRepeatVetoableChangeListener, getVetoableChangeListeners, getVetoableChangeListeners, getVetoableChangeSupport, hasPropertyChangeListeners, hasVetoableChangeListeners, removePropertyChangeListener, removePropertyChangeListener, removeVetoableChangeListener, removeVetoableChangeListener |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface com.guiseframework.component.CompositeComponent |
|---|
addCompositeComponentListener, getChildComponents, hasChildComponents, removeCompositeComponentListener |
| Constructor Detail |
|---|
public AbstractFrame(Component component)
component - The single child component, or null if this frame should have no child component.| Method Detail |
|---|
public Frame.State getState()
getState in interface Frameprotected void setState(Frame.State newState)
newState - The new state of the frame.
java.lang.NullPointerException - if the given state is null.Frame.STATE_PROPERTYpublic boolean isModal()
isModal in interface Framepublic void setModal(boolean newModal)
Boolean.
setModal in interface FramenewModal - true if the frame should be modal, else false.Frame.MODAL_PROPERTYpublic Frame.Mode getMode()
getMode in interface ModalComponent<Frame.Mode>null if the component is in a modeless state.public void setMode(Frame.Mode newMode)
setMode in interface ModalComponent<Frame.Mode>newMode - The new mode of component interaction.ModalComponent.MODE_PROPERTYpublic boolean isMovable()
isMovable in interface Framepublic void setMovable(boolean newMovable)
Boolean.
setMovable in interface FramenewMovable - true if the frame should be movable, else false.Frame.MOVABLE_PROPERTYpublic boolean isResizable()
isResizable in interface Framepublic void setResizable(boolean newResizable)
Boolean.
setResizable in interface FramenewResizable - true if the frame can be resized, else false.Frame.RESIZABLE_PROPERTYpublic Component getRelatedComponent()
getRelatedComponent in interface Framenull if the frame is not related to another component.public void setRelatedComponent(Component newRelatedComponent)
setRelatedComponent in interface FramenewRelatedComponent - The new related component, or null if the frame is not related to another component.Frame.RELATED_COMPONENT_PROPERTYpublic Color getTitleBackgroundColor()
getTitleBackgroundColor in interface Framenull if no background color is specified for the title.public void setTitleBackgroundColor(Color newTitleBackgroundColor)
setTitleBackgroundColor in interface FramenewTitleBackgroundColor - The background color of the title, or null if the default background color should be used.Frame.TITLE_BACKGROUND_COLOR_PROPERTYpublic boolean isTitleVisible()
isTitleVisible in interface Framepublic void setTitleVisible(boolean newTitleVisible)
Boolean.
setTitleVisible in interface FramenewTitleVisible - true if the title bar should be visible, else false.Frame.TITLE_VISIBLE_PROPERTYpublic Effect getOpenEffect()
getOpenEffect in interface Framenull if there is no open effect.public void setOpenEffect(Effect newOpenEffect)
setOpenEffect in interface FramenewEffect - The new effect used for opening the frame, or null if there should be no open effect.Frame.OPEN_EFFECT_PROPERTYpublic Component getContent()
getContent in interface ContentComponentnull if this frame does not have a content child component.AbstractFrame.FrameComponent.CONTENT_COMPONENTpublic void setContent(Component newContent)
setContent in interface ContentComponentnewContent - The content child component, or null if this frame does not have a content child component.AbstractFrame.FrameComponent.CONTENT_COMPONENT,
ContentComponent.CONTENT_PROPERTYpublic Menu getMenu()
getMenu in interface Framenull if this frame does not have a menu.AbstractFrame.FrameComponent.MENU_COMPONENTpublic void setMenu(Menu newMenu)
setMenu in interface FramenewMenu - The frame menu, or null if this frame does not have a menu.AbstractFrame.FrameComponent.MENU_COMPONENT,
Frame.MENU_PROPERTYpublic Toolbar getToolbar()
getToolbar in interface Framenull if this frame does not have a toolbar.AbstractFrame.FrameComponent.TOOLBAR_COMPONENTpublic void setToolbar(Toolbar newToolbar)
setToolbar in interface FramenewToolbar - The frame toolbar, or null if this frame does not have a toolbar.AbstractFrame.FrameComponent.TOOLBAR_COMPONENT,
Frame.TOOLBAR_PROPERTYprotected FrameMenuToolPrototypeProvisionStrategy getPrototypeProvisionStrategy()
public ActionControl getCloseActionControl()
getCloseActionControl in interface Framenull if this frame does not have a close action control.AbstractFrame.FrameComponent.CLOSE_ACTION_CONTROLpublic void setCloseActionControl(ActionControl newCloseActionControl)
setCloseActionControl in interface FramenewCloseActionControl - The action control for closing the frame, or null if this frame does not have a close action control.AbstractFrame.FrameComponent.CLOSE_ACTION_CONTROL,
Frame.CLOSE_ACTION_CONTROL_PROPERTYpublic InputFocusStrategy getInputFocusStrategy()
getInputFocusStrategy in interface InputFocusGroupComponentpublic void setInputFocusStrategy(InputFocusStrategy newInputFocusStrategy)
setInputFocusStrategy in interface InputFocusGroupComponentnewInputFocusStrategy - The input focus strategy for this group.
java.lang.NullPointerException - if the given input focus strategy is null.InputFocusGroupComponent.INPUT_FOCUS_STRATEGY_PROPERTYpublic InputFocusableComponent getInputFocusedComponent()
InputFocusGroupComponent, which in turn will have its own focused component.
getInputFocusedComponent in interface InputFocusGroupComponentnull if no component currently has the input focus.
public void setInputFocusedComponent(InputFocusableComponent newInputFocusedComponent)
throws java.beans.PropertyVetoException
setInputFocusedComponent in interface InputFocusGroupComponentnewInputFocusedComponent - The component to receive the input focus.
java.beans.PropertyVetoException - if the given component is not a focusable component within this input focus group, the component cannot receive the input focus, or the input focus change has otherwise been vetoed.getInputFocusStrategy(),
InputFocusGroupComponent.INPUT_FOCUSED_COMPONENT_PROPERTYpublic ActionPrototype getCloseActionPrototype()
getCloseActionPrototype in interface Framepublic void open()
open in interface FramegetState(),
Frame.STATE_PROPERTYpublic void open(boolean modal)
open in interface Framemodal - true if the frame should be opened as a modal frame, else false.getState(),
Frame.STATE_PROPERTYpublic void open(com.globalmentor.beans.GenericPropertyChangeListener<Frame.Mode> modeChangeListener)
ModalComponent.MODE_PROPERTY change listener using BoundPropertyObject.addPropertyChangeListener(String, PropertyChangeListener) and then calls open(boolean) with a value of true.
open in interface FramemodeChangeListener - The mode property change listener to add.ModalComponent.MODE_PROPERTYpublic boolean canClose()
true.
This method is called from close().
canClose in interface Frametrue if the frame should be allowed to close.public final void close()
canClose() and only performs closing functionality if that method returns true.
This method delegates actual closing to closeImpl(), and that method should be overridden rather than this one.
close in interface FramegetState(),
Frame.STATE_PROPERTYprotected void closeImpl()
public boolean validate()
validate in interface Componentvalidate in class AbstractCompositeComponentAbstractComponent.isValid() as a convenience.protected final void updateDefaultPrototypeProvisions()
provideDefaultPrototypes()protected java.util.Set<PrototypeProvision<?>> provideDefaultPrototypes()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||