diff options
author | Sven Gothel <[email protected]> | 2010-05-05 15:25:29 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2010-05-05 15:25:29 +0200 |
commit | ccc30b050b98d3ac19779e1dc2d0fcee68331863 (patch) | |
tree | 5f5d0db79c7ddbd61b4b8ebcbdcb9396884d4847 /src/newt | |
parent | 3464e222467b3af3d7316e960a7bd99d8065fd18 (diff) |
Newt Window: sendEvent -> public; GLWindow must pass down sendEvent and requestFocus calls
Diffstat (limited to 'src/newt')
-rwxr-xr-x | src/newt/classes/com/jogamp/newt/Window.java | 2 | ||||
-rw-r--r-- | src/newt/classes/com/jogamp/newt/opengl/GLWindow.java | 8 |
2 files changed, 9 insertions, 1 deletions
diff --git a/src/newt/classes/com/jogamp/newt/Window.java b/src/newt/classes/com/jogamp/newt/Window.java index e807ad6af..869ca2cf3 100755 --- a/src/newt/classes/com/jogamp/newt/Window.java +++ b/src/newt/classes/com/jogamp/newt/Window.java @@ -588,7 +588,7 @@ public abstract class Window implements NativeWindow // Generic Event Support // - protected void sendEvent(NEWTEvent e) { + public void sendEvent(NEWTEvent e) { if(e instanceof WindowEvent) { sendWindowEvent((WindowEvent)e); } else if(e instanceof KeyEvent) { diff --git a/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java b/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java index 0bbd38a4e..b47b580ed 100644 --- a/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java +++ b/src/newt/classes/com/jogamp/newt/opengl/GLWindow.java @@ -281,6 +281,10 @@ public class GLWindow extends Window implements GLAutoDrawable { return window.isUndecorated(); } + public void requestFocus() { + window.requestFocus(); + } + public void setSize(int width, int height) { window.setSize(width, height); } @@ -337,6 +341,10 @@ public class GLWindow extends Window implements GLAutoDrawable { window.surfaceUpdated(updater, window, when); } + public void sendEvent(NEWTEvent e) { + window.sendEvent(e); + } + public void addMouseListener(MouseListener l) { window.addMouseListener(l); } |