summaryrefslogtreecommitdiff
path: root/java/gjt/MouseController.java
blob: f044adee5ba60e0909fa5856e2dd36f46468ad64 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
package gjt;

import java.awt.Event;

/**
 * An interface for handling mouse events.<p>
 *
 * Components delegate handling of mouse events to a 
 * MouseController derivation.<p>
 *
 * For instance:<p>
 *<pre> 
 *      mouseDown(Event event, int x, int y) {
 *          return controller.mouseDown(event,x,y);
 *      }
 *</pre>
 * @version 1.0, Apr 1 1996
 * @author  David Geary
 * @see     ImageButton
 * @see     ImageButtonController
 * @see     SpringyImageButtonController
 * @see     StickyImageButtonController
 */
public interface MouseController {
    public boolean mouseEnter(Event event, int x, int y);
    public boolean mouseExit (Event event, int x, int y);

    public boolean mouseMove (Event event, int x, int y);
    public boolean mouseDown (Event event, int x, int y);
    public boolean mouseUp   (Event event, int x, int y);
    public boolean mouseDrag (Event event, int x, int y);
}