public class DesktopEventManagementPolicy extends Object implements EventHandler
While no renderable consumes the events, they are sent to the renderable that is under the pointer (see
Desktop.panelAt(int, int)
and Panel.getWidgetAt(int, int)
), then sent to all its parent hierarchy.
Once a renderable has consumed an event, it will be the only one to receive the next events during the session.
Widget.hasFocus()
), then sent to all its
parent hierarchy while the event is not consumed.Constructor and Description |
---|
DesktopEventManagementPolicy(Desktop desktop)
Creates a desktop event manager.
|
Modifier and Type | Method and Description |
---|---|
boolean |
handleEvent(int event)
Handles an event.
|
public DesktopEventManagementPolicy(Desktop desktop)
desktop
- the desktop to dispatch in.public boolean handleEvent(int event)
EventHandler
handleEvent
in interface EventHandler
event
- the event to handle.true
if the event is consumed, false
otherwise.Event
,
DispatchHelper