org.xith3d.ui.hud.listeners
Class WidgetContainerAdapter

java.lang.Object
  extended by org.xith3d.ui.hud.listeners.WidgetContainerAdapter
All Implemented Interfaces:
WidgetContainerListener

public abstract class WidgetContainerAdapter
extends java.lang.Object
implements WidgetContainerListener

If a Widget makes use of other Widgets to be built and these Widgets produce events, that are to be catched be the Widget only, then you should create an inner class and let it extend this class to catch them, since it already implements all known Widget-Listeners (with empty method stubs).


Constructor Summary
WidgetContainerAdapter()
           
 
Method Summary
 void onWidgetAddedToContainer(WidgetContainer container, Widget widget)
          This event is fired, when a Widget is added to a WidgetContainer.
 void onWidgetAddedToHUD(HUD hud, Widget widget)
          This event is fired, when a Widget is added to a WidgetContainer and the container itself is already added to the HUD or is the HUD itself.
 void onWidgetRemovedFromContainer(WidgetContainer container, Widget widget)
          This event is fired, when a Widget is removed from a WidgetContainer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WidgetContainerAdapter

public WidgetContainerAdapter()
Method Detail

onWidgetAddedToContainer

public void onWidgetAddedToContainer(WidgetContainer container,
                                     Widget widget)
This event is fired, when a Widget is added to a WidgetContainer.

Specified by:
onWidgetAddedToContainer in interface WidgetContainerListener
Parameters:
container - the WidgetContainer, the Widget is added to
widget - the Widget, which is added to a WidgetContainer

onWidgetAddedToHUD

public void onWidgetAddedToHUD(HUD hud,
                               Widget widget)
This event is fired, when a Widget is added to a WidgetContainer and the container itself is already added to the HUD or is the HUD itself.

Specified by:
onWidgetAddedToHUD in interface WidgetContainerListener
Parameters:
hud - the HUD, the Widget is added to
widget - the Widget, which is added to a WidgetContainer

onWidgetRemovedFromContainer

public void onWidgetRemovedFromContainer(WidgetContainer container,
                                         Widget widget)
This event is fired, when a Widget is removed from a WidgetContainer.

Specified by:
onWidgetRemovedFromContainer in interface WidgetContainerListener
Parameters:
container - the WidgetContainer, the Widget is removed from
widget - the Widget, which is removed from a WidgetContainer