diff options
Diffstat (limited to 'src/demos/es1/angeles')
-rwxr-xr-x | src/demos/es1/angeles/AngelesES1.java | 3 | ||||
-rwxr-xr-x | src/demos/es1/angeles/AngelesGL.java | 3 | ||||
-rwxr-xr-x | src/demos/es1/angeles/AngelesGLil.java | 3 | ||||
-rwxr-xr-x | src/demos/es1/angeles/Main.java | 11 |
4 files changed, 18 insertions, 2 deletions
diff --git a/src/demos/es1/angeles/AngelesES1.java b/src/demos/es1/angeles/AngelesES1.java index 28369e2..a58a198 100755 --- a/src/demos/es1/angeles/AngelesES1.java +++ b/src/demos/es1/angeles/AngelesES1.java @@ -136,6 +136,9 @@ public class AngelesES1 implements GLEventListener { System.out.println("reshape .."); } + public void dispose(GLAutoDrawable drawable) { + } + public void display(GLAutoDrawable drawable) { long tick = System.currentTimeMillis(); diff --git a/src/demos/es1/angeles/AngelesGL.java b/src/demos/es1/angeles/AngelesGL.java index 7df2526..386d1db 100755 --- a/src/demos/es1/angeles/AngelesGL.java +++ b/src/demos/es1/angeles/AngelesGL.java @@ -168,6 +168,9 @@ public class AngelesGL implements GLEventListener { //System.out.println("reshape .."); } + public void dispose(GLAutoDrawable drawable) { + } + public void display(GLAutoDrawable drawable) { long tick = System.currentTimeMillis(); diff --git a/src/demos/es1/angeles/AngelesGLil.java b/src/demos/es1/angeles/AngelesGLil.java index 8e71840..415008e 100755 --- a/src/demos/es1/angeles/AngelesGLil.java +++ b/src/demos/es1/angeles/AngelesGLil.java @@ -180,6 +180,9 @@ public class AngelesGLil implements GLEventListener { //System.out.println("reshape .."); } + public void dispose(GLAutoDrawable drawable) { + } + public void display(GLAutoDrawable drawable) { long tick = System.currentTimeMillis(); diff --git a/src/demos/es1/angeles/Main.java b/src/demos/es1/angeles/Main.java index 4983619..a4e345b 100755 --- a/src/demos/es1/angeles/Main.java +++ b/src/demos/es1/angeles/Main.java @@ -5,11 +5,17 @@ import javax.media.nwi.*; import javax.media.opengl.*; import com.sun.javafx.newt.*; -public class Main implements MouseListener { +public class Main implements WindowListener, MouseListener { public boolean quit = false; public GLWindow window = null; + public void windowResized(WindowEvent e) { } + public void windowMoved(WindowEvent e) { } + public void windowDestroyNotify(WindowEvent e) { + quit = true; + } + public void mouseClicked(MouseEvent e) { if (e.getClickCount() > 1) { quit=true; @@ -57,6 +63,7 @@ public class Main implements MouseListener { } window = GLWindow.create(nWindow, caps); + window.addWindowListener(this); window.addMouseListener(this); window.enablePerfLog(true); @@ -86,7 +93,7 @@ public class Main implements MouseListener { } // Shut things down cooperatively - window.close(); + window.destroy(); window.getFactory().shutdown(); System.out.println("angeles.Main shut down cleanly."); } catch (GLException e) { |