OSDN Git Service

["fixed"] resize stuff. not really working as expected in particle editor. and hiero...
authorbadlogicgames <badlogicgames@6c4fd544-2939-11df-bb46-9574ba5d0bfa>
Tue, 2 Nov 2010 00:20:00 +0000 (00:20 +0000)
committerbadlogicgames <badlogicgames@6c4fd544-2939-11df-bb46-9574ba5d0bfa>
Tue, 2 Nov 2010 00:20:00 +0000 (00:20 +0000)
extensions/hiero/src/com/badlogic/gdx/hiero/Hiero.java
extensions/particle-editor/src/com/badlogic/gdx/graphics/particles/ParticleEditor.java

index 039533d..a7b2df5 100644 (file)
@@ -1180,8 +1180,7 @@ public class Hiero extends JFrame {
                        int viewHeight = Gdx.graphics.getHeight();\r
                        if (viewWidth != glCanvas.getWidth() || viewHeight != glCanvas.getHeight()) {\r
                                viewWidth = Math.max(1, glCanvas.getWidth());\r
-                               viewHeight = Math.max(1, glCanvas.getHeight());\r
-                               app.setSize(viewWidth, viewHeight);\r
+                               viewHeight = Math.max(1, glCanvas.getHeight());                         \r
                        }\r
 \r
                        if (newUnicodeFont != null) {\r
index 0369f3a..d18334d 100644 (file)
@@ -256,6 +256,7 @@ public class ParticleEditor extends JFrame {
                \r
                @Override\r
                public void resize(int width, int height) {\r
+                       Gdx.gl.glViewport(0, 0, width, height);\r
                        spriteBatch.getProjectionMatrix().setToOrtho(0, width, height, 0, 0, 1);\r
 \r
                        synchronized (effect) {\r
@@ -269,8 +270,7 @@ public class ParticleEditor extends JFrame {
                                int viewHeight = Gdx.graphics.getHeight();\r
                                if (viewWidth != glCanvas.getWidth() || viewHeight != glCanvas.getHeight()) {\r
                                        viewWidth = Math.max(1, glCanvas.getWidth());\r
-                                       viewHeight = Math.max(1, glCanvas.getHeight());\r
-                                       app.setSize(viewWidth, viewHeight);\r
+                                       viewHeight = Math.max(1, glCanvas.getHeight());                                 \r
                                }\r
 \r
                                float delta = Gdx.graphics.getDeltaTime();\r