From 567bc6a7266ca782051e052b8bab732fc8f92671 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sun, 11 Dec 2011 05:38:57 +0100 Subject: JOGLNewtApplet1Run: Config and add GLEventListener before hooking GLWindow/NewtCanvasAWT to AWT Applet Container --- .../com/jogamp/newt/awt/applet/JOGLNewtApplet1Run.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src') diff --git a/src/newt/classes/com/jogamp/newt/awt/applet/JOGLNewtApplet1Run.java b/src/newt/classes/com/jogamp/newt/awt/applet/JOGLNewtApplet1Run.java index 105f8369a..a052f6f97 100755 --- a/src/newt/classes/com/jogamp/newt/awt/applet/JOGLNewtApplet1Run.java +++ b/src/newt/classes/com/jogamp/newt/awt/applet/JOGLNewtApplet1Run.java @@ -188,13 +188,6 @@ public class JOGLNewtApplet1Run extends Applet { container.add(new Button("East"), BorderLayout.EAST); container.add(new Button("West"), BorderLayout.WEST); } - if(glStandalone) { - newtCanvasAWT = null; - } else { - newtCanvasAWT = new NewtCanvasAWT(glWindow); - container.add(newtCanvasAWT, BorderLayout.CENTER); - container.validate(); - } base.init(glWindow); if(base.isValid()) { GLEventListener glEventListener = base.getGLEventListener(); @@ -209,6 +202,13 @@ public class JOGLNewtApplet1Run extends Applet { addKeyListener((KeyListener)glEventListener); } } + if(glStandalone) { + newtCanvasAWT = null; + } else { + newtCanvasAWT = new NewtCanvasAWT(glWindow); + container.add(newtCanvasAWT, BorderLayout.CENTER); + container.validate(); + } } catch (Throwable t) { throw new RuntimeException(t); } -- cgit v1.2.3