/[libvob]/libvob/org/nongnu/libvob/impl/gl/GLScreen.java
ViewVC logotype

Diff of /libvob/org/nongnu/libvob/impl/gl/GLScreen.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by humppake, Fri May 16 11:02:41 2003 UTC revision 1.5 by tjl, Fri May 16 14:00:36 2003 UTC
# Line 29  import java.awt.Rectangle; Line 29  import java.awt.Rectangle;
29  import java.awt.Cursor;  import java.awt.Cursor;
30    
31  import java.awt.event.MouseEvent;  import java.awt.event.MouseEvent;
32    import java.awt.event.MouseWheelEvent;
33  import java.awt.event.InputEvent;  import java.awt.event.InputEvent;
34    
35  import java.util.HashMap;  import java.util.HashMap;
# Line 109  public static final String rcsid = "$Id$ Line 110  public static final String rcsid = "$Id$
110              }              }
111    
112              public void mouse(int x, int y, int button, int what) {              public void mouse(int x, int y, int button, int what) {
113                    // Handle mouse wheel.
114                    if(button == 4 || button == 5) {
115                        int r = (button == 4 ? 1 : -1);
116                        MouseWheelEvent ev = new MouseWheelEvent(fakeSource,
117                                MouseWheelEvent.MOUSE_WHEEL,
118                                0,
119                                0,
120                                x, y,
121                                1,
122                                false,
123                                MouseWheelEvent.WHEEL_UNIT_SCROLL,
124                                r, r);
125                        binder.mouse(ev);
126                        return;
127                    }
128    
129                  if(dbg) pa("GLScreen mouseEvent: "+x+" "+y+" "+button+" "+what);                  if(dbg) pa("GLScreen mouseEvent: "+x+" "+y+" "+button+" "+what);
130                  MouseEvent ev = null;                  MouseEvent ev = null;
131                  switch(what) {                  switch(what) {

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26