AWT Counter demo

You may want to use the bottom textfield to set the counter.

The Counter is implemented using the "Model View Controller" paradigm":

The sources are located in the source directory
and here are the javadoc pages (no frames)
You may also look to the applet with the Java Plugin.

Events generated from keyboard and mouse are handled by the Controller.
Controllers implements the "feel" of the application and calls Models that implements the application.
The Models notify to all the Views they knows about the changes in their internal status.

The Basic Controller is also a View: it disable the "-" button when the Counter reach zero.