CHAPTER 14

image

It’s the Event of the Year: Events in Swing Applications

I have been referencing events, of all sorts, in many of the preceding chapters. It seems like a good time to take a better look at how events are handled in Swing applications.

This chapter is all about events, such as mouse clicks, and preparing an application to handle these kinds of events when they occur. You’ll also see how easy it is in Jython to associate a method with an event. It is important to note that methods that are called when specific events occur are called listeners. The association of a listener method with a specific kind of event is a kind of registration. ...

Get Swing for Jython: Graphical Jython UI and Scripts Development using Java Swing and WebSphere Application Server now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.