de.grogra.pf.ui.util
Class WidgetAdapter

java.lang.Object
  extended by de.grogra.pf.ui.util.WidgetSupport
      extended by de.grogra.pf.ui.util.WidgetAdapter
All Implemented Interfaces:
Command, ComponentWrapper, Widget, Disposable, java.beans.PropertyChangeListener, java.util.EventListener

public final class WidgetAdapter
extends WidgetSupport
implements java.beans.PropertyChangeListener, Command


Field Summary
 
Fields inherited from interface de.grogra.pf.ui.Command
DISPOSE
 
Fields inherited from interface de.grogra.pf.ui.Widget
WIDGET_VALUE_PROPERTY
 
Constructor Summary
WidgetAdapter(Widget widget, Context context)
           
 
Method Summary
 java.lang.String getCommandName()
          Returns a name which can be used in the graphical user interface to represent this command.
 java.lang.Object getComponent()
           
protected  void installListener(boolean hasListeners)
           
 void propertyChange(java.beans.PropertyChangeEvent event)
           
 void run(java.lang.Object info, Context ctx)
          Performs the actions of this command.
 void setEnabled(boolean enabled)
           
 void updateValue(java.lang.Object value)
           
 
Methods inherited from class de.grogra.pf.ui.util.WidgetSupport
addPropertyChangeListener, addVetoableChangeListener, convert, dispose, disposeImpl, firePropertyChange, firePropertyChange, fireVetoableChange, fireVetoableChange, removePropertyChangeListener, removeVetoableChangeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WidgetAdapter

public WidgetAdapter(Widget widget,
                     Context context)
Method Detail

getCommandName

public java.lang.String getCommandName()
Description copied from interface: Command
Returns a name which can be used in the graphical user interface to represent this command.

Specified by:
getCommandName in interface Command
Returns:
this commands's name

getComponent

public java.lang.Object getComponent()
Specified by:
getComponent in interface ComponentWrapper

installListener

protected void installListener(boolean hasListeners)
Overrides:
installListener in class WidgetSupport

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent event)
Specified by:
propertyChange in interface java.beans.PropertyChangeListener

run

public void run(java.lang.Object info,
                Context ctx)
Description copied from interface: Command
Performs the actions of this command. This method is invoked by the JobManager after the command has been submitted to the job manager by one of execute, runAt, or runLater-methods. The arguments info and context are the arguments which have been provided as arguments to the JobManager-methods.

Specified by:
run in interface Command
Parameters:
info - an argument
ctx - a context

setEnabled

public void setEnabled(boolean enabled)
Specified by:
setEnabled in interface Widget

updateValue

public void updateValue(java.lang.Object value)
Specified by:
updateValue in interface Widget