All events are represented by the Event class. The instance variable, id, represents the type of the event, such as a button click. Another instance variable, target, specifies the object which generated the event, such as which button. |
Events are dispatched first to the handleEvent() method of the Component in which they occurred. If possible, this method will pass the event on to an appropriate specific event handler such as action(), mouseDown(), etc. |
If the event handler returns true, it handled the event and it's over. Otherwise, handleEvent passes the event on to the container in which that component resides, and so on. |