01: /*
02: * Copyright 2000,2005 wingS development team.
03: *
04: * This file is part of wingS (http://wingsframework.org).
05: *
06: * wingS is free software; you can redistribute it and/or modify
07: * it under the terms of the GNU Lesser General Public License
08: * as published by the Free Software Foundation; either version 2.1
09: * of the License, or (at your option) any later version.
10: *
11: * Please see COPYING for the complete licence.
12: */
13: package org.wings.event;
14:
15: /**
16: * An abstract adapter class for receiving component events.
17: * The methods in this class are empty. This class exists as
18: * convenience for creating listener objects.
19: * <p/>
20: * Extend this class to create a ComponentEvent listener
21: * and override the methods for the events of interest. (If you implement the
22: * ComponentListener interface, you have to define all of
23: * the methods in it. This abstract class defines null methods for them
24: * all, so you can only have to define methods for events you care about.)
25: * <p/>
26: * Create a listener object using your class and then register it with a
27: * component using the component's addComponentListener method. When the component's size, location, or visibility
28: * changes, the relevant method in the listener object is invoked,
29: * and the ComponentEvent is passed to it.
30: *
31: * @author <a href="mailto:andre@lison.de">Andre Lison</a>
32: * @see org.wings.event.SComponentEvent
33: * @see org.wings.event.SComponentListener
34: */
35: public abstract class SComponentAdapter implements SComponentListener {
36: /**
37: * Invoked when the component has been made invisible.
38: */
39: public void componentHidden(SComponentEvent e) {
40: }
41:
42: /**
43: * Invoked when the component's position changes.
44: */
45: public void componentMoved(SComponentEvent e) {
46: }
47:
48: /**
49: * Invoked when the component's size changes.
50: */
51: public void componentResized(SComponentEvent e) {
52: }
53:
54: /**
55: * Invoked when the component has been made visible.
56: */
57: public void componentShown(SComponentEvent e) {
58: }
59: }
|