|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object bibliothek.gui.dock.control.DefaultGlobalMouseDispatcher
public class DefaultGlobalMouseDispatcher
This default implementation of a GlobalMouseDispatcher
uses an AWTEventListener
is possible, or
just forwards events that are delivered to the dispatch(MouseEvent)
method.
Constructor Summary | |
---|---|
DefaultGlobalMouseDispatcher(DockController controller,
ControllerSetupCollection setup)
Creates a new dispatcher. |
Method Summary | |
---|---|
void |
addMouseListener(MouseListener listener)
Adds the observer listener to this dispatcher. |
void |
addMouseMotionListener(MouseMotionListener listener)
Adds the observer listener to this dispatcher. |
void |
addMouseWheelListener(MouseWheelListener listener)
Adds the observer listener to this dispatcher. |
protected AWTEventListener |
createListener()
Creates a listener which will receive mouse-events. |
void |
dispatch(MouseEvent event)
Called by various Component s when they register a MouseEvent . |
protected MouseListener[] |
getMouseListeners()
Gets all the MouseListener s that are currently registered. |
protected MouseMotionListener[] |
getMouseMotionListeners()
Gets all the MouseMotionListener s that are currently registered. |
protected MouseWheelListener[] |
getMouseWheelListeners()
Gets all the MouseWheelListener s that are currently registered. |
void |
kill()
Releases any resources this dispatcher holds. |
void |
removeMouseListener(MouseListener listener)
Removes the observer listener from this dispacher. |
void |
removeMouseMotionListener(MouseMotionListener listener)
Removes the observer listener from this dispacher. |
void |
removeMouseWheelListener(MouseWheelListener listener)
Removes the observer listener from this dispacher. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultGlobalMouseDispatcher(DockController controller, ControllerSetupCollection setup)
controller
- the controller in whose realm this dispatcher workssetup
- tells when the setup phase of controller
is finishedMethod Detail |
---|
public void dispatch(MouseEvent event)
GlobalMouseDispatcher
Component
s when they register a MouseEvent
. Calls to this method are only
necessary when in a restricted environment
. The
GlobalMouseDispatcher
may filter the events, but usually the event is forwarded to all
registered MouseListener
s.
dispatch
in interface GlobalMouseDispatcher
event
- the event to forwardpublic void addMouseListener(MouseListener listener)
GlobalMouseDispatcher
listener
to this dispatcher.
addMouseListener
in interface GlobalMouseDispatcher
listener
- the new listener, not null
public void removeMouseListener(MouseListener listener)
GlobalMouseDispatcher
listener
from this dispacher.
removeMouseListener
in interface GlobalMouseDispatcher
listener
- the listener to removeprotected MouseListener[] getMouseListeners()
MouseListener
s that are currently registered.
public void addMouseMotionListener(MouseMotionListener listener)
GlobalMouseDispatcher
listener
to this dispatcher.
addMouseMotionListener
in interface GlobalMouseDispatcher
listener
- the new listener, not null
public void removeMouseMotionListener(MouseMotionListener listener)
GlobalMouseDispatcher
listener
from this dispacher.
removeMouseMotionListener
in interface GlobalMouseDispatcher
listener
- the listener to removeprotected MouseMotionListener[] getMouseMotionListeners()
MouseMotionListener
s that are currently registered.
public void addMouseWheelListener(MouseWheelListener listener)
GlobalMouseDispatcher
listener
to this dispatcher.
addMouseWheelListener
in interface GlobalMouseDispatcher
listener
- the new listener, not null
public void removeMouseWheelListener(MouseWheelListener listener)
GlobalMouseDispatcher
listener
from this dispacher.
removeMouseWheelListener
in interface GlobalMouseDispatcher
listener
- the listener to removeprotected MouseWheelListener[] getMouseWheelListeners()
MouseWheelListener
s that are currently registered.
public void kill()
GlobalMouseDispatcher
kill
in interface GlobalMouseDispatcher
protected AWTEventListener createListener()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |