org.springframework.richclient.widget
Class AbstractWidget
java.lang.Object
org.springframework.richclient.application.support.ApplicationServicesAccessor
org.springframework.richclient.widget.AbstractWidget
- All Implemented Interfaces:
- Widget
- Direct Known Subclasses:
- AbstractTitledWidget, ButtonSwitcherWidget, GlazedListTableWidget, HTMLViewWidget, ImageViewWidget, ScreenSimulationWidget
public abstract class AbstractWidget
- extends ApplicationServicesAccessor
- implements Widget
Default behavior implementation of AbstractWidget
Field Summary |
protected boolean |
showing
|
Method Summary |
boolean |
canClose()
Checks whether this component can be closed visually, for example when there
are no unsaved changes. |
List<? extends AbstractCommand> |
getCommands()
Returns a list of commands for this widget. |
boolean |
isShowing()
Encompasses the status of the widget between onAboutToShow() and onAboutToHide(). |
void |
onAboutToHide()
Hook method called before moving the component to the background (=hiding) |
void |
onAboutToShow()
Hook method called before showing the component on screen. |
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 |
Methods inherited from interface org.springframework.richclient.widget.Widget |
getComponent |
showing
protected boolean showing
AbstractWidget
public AbstractWidget()
onAboutToShow
public void onAboutToShow()
- Hook method called before showing the component on screen.
- Specified by:
onAboutToShow
in interface Widget
onAboutToHide
public void onAboutToHide()
- Hook method called before moving the component to the background (=hiding)
- Specified by:
onAboutToHide
in interface Widget
isShowing
public boolean isShowing()
- Description copied from interface:
Widget
- Encompasses the status of the widget between onAboutToShow() and onAboutToHide().
A component does not know when it's active, even if there is an isShowing() method
in it's API (due to tab panels or scroll panes).
- Specified by:
isShowing
in interface Widget
- Returns:
true
if the widget is shown in the foreground.
canClose
public boolean canClose()
- Checks whether this component can be closed visually, for example when there
are no unsaved changes.
Default: Widget can be closed.
- Specified by:
canClose
in interface Widget
- Returns:
true
if the widget can be closed without problems.
getCommands
public List<? extends AbstractCommand> getCommands()
- Returns a list of commands for this widget.
- Specified by:
getCommands
in interface Widget
Copyright © 2004-2009 The Spring Framework. All Rights Reserved.