diff options
author | Kenneth Russel <[email protected]> | 2008-06-30 20:12:47 +0000 |
---|---|---|
committer | Kenneth Russel <[email protected]> | 2008-06-30 20:12:47 +0000 |
commit | 252efbfd61fb62883df028cba5743e458a5b18c7 (patch) | |
tree | a5f5d87bca24309a4c6c5ac48497a30a70cd442c /src/classes/com/sun/javafx/newt/InputEvent.java | |
parent | 7be2d71e458dd37789ceac43dede4b308eff45c2 (diff) |
Refactored more C compiler setup into gluegen-cpptasks.xml to make it
easier to build native sources via Ant. Provided new
gluegen.cpptasks.setup.compiler target which sets up
platform-independent compiler and linker IDs and other properties
which can be used in other projects' build files. Refactored JOGL
build to use some of these new properties and eliminate duplication;
more code savings possible. Added new GLWindow class to Newt
implementing GLAutoDrawable to increase code sharing, and supporting
making OpenGL calls inside of EventListener callbacks. Moved repaint()
method from GLAutoDrawable to AWTGLAutoDrawable. Added WindowEvent and
WindowListener interfaces to Newt, currently implemented on Windows
and AWT backends (X11 backend would need to support and watch for
window resizes -- FIXME added). Refactored common functionality into
Newt Event class. Renumbered event IDs to avoid collisions. Fixed
potential problems with removing event listeners inside of
EventListener callbacks.
git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/branches/JOGL_2_SANDBOX@1702 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/classes/com/sun/javafx/newt/InputEvent.java')
-rw-r--r-- | src/classes/com/sun/javafx/newt/InputEvent.java | 23 |
1 files changed, 5 insertions, 18 deletions
diff --git a/src/classes/com/sun/javafx/newt/InputEvent.java b/src/classes/com/sun/javafx/newt/InputEvent.java index e8644f953..dc36be34d 100644 --- a/src/classes/com/sun/javafx/newt/InputEvent.java +++ b/src/classes/com/sun/javafx/newt/InputEvent.java @@ -33,7 +33,7 @@ package com.sun.javafx.newt; -public abstract class InputEvent +public abstract class InputEvent extends Event { public static int SHIFT_MASK = 1 << 0; public static int CTRL_MASK = 1 << 1; @@ -41,18 +41,12 @@ public abstract class InputEvent public static int ALT_MASK = 1 << 3; public static int ALT_GRAPH_MASK = 1 << 5; - protected InputEvent(boolean sysEvent, Window source, long when, int modifiers) { + protected InputEvent(boolean sysEvent, int eventType, Window source, long when, int modifiers) { + super(sysEvent, eventType, source, when); this.consumed=false; - this.sysEvent=sysEvent; - this.source=source; - this.when=when; this.modifiers=modifiers; } - protected boolean isSysEvent() { - return sysEvent; - } - public void consume() { consumed=true; } @@ -63,9 +57,6 @@ public abstract class InputEvent public int getModifiers() { return modifiers; } - public long getWhen() { - return when; - } public boolean isAltDown() { return (modifiers&ALT_MASK)!=0; } @@ -83,13 +74,9 @@ public abstract class InputEvent } public String toString() { - return "InputEvent[sys:"+sysEvent+", source:"+source+", when:"+when+", modifiers:"+modifiers+"]"; + return "InputEvent[modifiers:"+modifiers+"]"; } - private boolean sysEvent, consumed; - private Window source; + private boolean consumed; private int modifiers; - private long when; - } - |