OSDN Git Service

Centered window for JOGL.
authornathan.sweet <nathan.sweet@6c4fd544-2939-11df-bb46-9574ba5d0bfa>
Thu, 21 Oct 2010 09:19:41 +0000 (09:19 +0000)
committernathan.sweet <nathan.sweet@6c4fd544-2939-11df-bb46-9574ba5d0bfa>
Thu, 21 Oct 2010 09:19:41 +0000 (09:19 +0000)
backends/gdx-backend-desktop/src/com/badlogic/gdx/backends/desktop/JoglGraphics.java

index 395071c..58a2bb5 100644 (file)
@@ -100,6 +100,7 @@ public final class JoglGraphics implements Graphics, RenderListener
         frame.pack();\r
         frame.setVisible( true );                \r
         frame.setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);\r
+        frame.setLocationRelativeTo(null);\r
         frame.addWindowListener(new WindowAdapter()\r
         {\r
             public void windowClosing(WindowEvent e)\r