com.hermetica.magician
Class GLEventMulticaster
java.lang.Object
|
+--com.hermetica.magician.GLEventMulticaster
- public class GLEventMulticaster
- extends java.lang.Object
- implements GLEventListener
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
_head
protected final GLEventListener _head
_tail
protected final GLEventListener _tail
GLEventMulticaster
protected GLEventMulticaster(GLEventListener head,
GLEventListener tail)
- Creates an event multicaster instance which chains two
listeners head and tail together.
add
public static GLEventListener add(GLEventListener head,
GLEventListener tail)
- Returns an event multicaster from listeners head and tail.
If either head or tail is null, the other is returned (no
multicaster is created). Otherwise, a new multicaster
is created which chains head and tail together.
remove
protected GLEventListener remove(GLEventListener removee)
- Removes a listener from this multicaster and returns the
resulting multicaster listener.
remove
public static GLEventListener remove(GLEventListener target,
GLEventListener removee)
- Returns the resulting multicaster listener after removing the
removee listener from the target listener.
If target is null or removee equals target, null is returned.
- Parameters:
target
- the listener removee is being removed fromremovee
- the listener being removed
initialize
public void initialize(GLDrawable component)
- Forwards the initialize event to both listeners _head and _tail.
- Specified by:
- initialize in interface GLEventListener
- Parameters:
component
- the GLComponent generating the event
display
public void display(GLDrawable component)
- Forwards the display event to both listeners _head and _tail.
- Specified by:
- display in interface GLEventListener
- Parameters:
component
- the GLComponent generating the event
reshape
public void reshape(GLDrawable component,
int x,
int y,
int width,
int height)
- Forwards the reshape event to both listeners _head and _tail.
- Specified by:
- reshape in interface GLEventListener
- Parameters:
component
- the GLComponent generating the event
getGL
public GL getGL()
- Returns a valid CoreGL pipeline
- Specified by:
- getGL in interface GLEventListener