11.3 Capturing an event



The basis of event-driven programming is tying events to code that responds to those events.

A handle to an Event object is passed into action() method.  The object contains the object the event happened and some other information.  Only some types of controls have a "standard action" that occurs will causes the call to action().

Case Study: Button2.java


Next Page