| |
17. 89. 9. 引进类型事件听众 |
|
- Typed listeners use classes and interfaces specific to each possible event.
- For example, to listen for a button click, register a SelectionListener implementation with the button using the button's addSelectionListener() method.
- All typed events ultimately derive from a common class: TypedEvent.
- Many event classes have a boolean member called doit that you can set to false to cancel the processing of that event.
|
Member | Description | Object data | Contains application-specific data | Display display | The display where the event occurred | int time | The time at which the event occurred | Widget widget | The source of the event |
|
|