From 1cbe45b9d7f21a751332d6f8dd948992e75dfe99 Mon Sep 17 00:00:00 2001
From: Sven Gothel <sgothel@jausoft.com>
Date: Tue, 21 Mar 2023 14:12:48 +0100
Subject: GraphUI Scene: Move reshape() below init from in-between display()
 impls

---
 .../classes/com/jogamp/graph/ui/gl/Scene.java      | 38 +++++++++++-----------
 1 file changed, 19 insertions(+), 19 deletions(-)

(limited to 'src/graphui/classes')

diff --git a/src/graphui/classes/com/jogamp/graph/ui/gl/Scene.java b/src/graphui/classes/com/jogamp/graph/ui/gl/Scene.java
index 24df8c80a..0755b31b9 100644
--- a/src/graphui/classes/com/jogamp/graph/ui/gl/Scene.java
+++ b/src/graphui/classes/com/jogamp/graph/ui/gl/Scene.java
@@ -245,6 +245,25 @@ public final class Scene implements GLEventListener {
         renderer.init(drawable.getGL().getGL2ES2());
     }
 
+    /**
+     * Reshape scene using {@link #setupMatrix(PMVMatrix, int, int, int, int)} using {@link PMVMatrixSetup}.
+     * <p>
+     * {@inheritDoc}
+     * </p>
+     * @see PMVMatrixSetup
+     * @see #setPMVMatrixSetup(PMVMatrixSetup)
+     * @see #setupMatrix(PMVMatrix, int, int, int, int)
+     * @see #getBounds()
+     * @see #getBoundsCenter()
+     */
+    @Override
+    public void reshape(final GLAutoDrawable drawable, final int x, final int y, final int width, final int height) {
+        renderer.reshapeNotify(x, y, width, height);
+
+        setupMatrix(renderer.getMatrix(), x, y, width, height);
+        pmvMatrixSetup.setPlaneBox(planeBox, renderer.getMatrix(), x, y, width, height);
+    }
+
     private static Comparator<Shape> shapeZAscComparator = new Comparator<Shape>() {
         @Override
         public int compare(final Shape s1, final Shape s2) {
@@ -268,25 +287,6 @@ public final class Scene implements GLEventListener {
         display(drawable, shapesS, false);
     }
 
-    /**
-     * Reshape scene using {@link #setupMatrix(PMVMatrix, int, int, int, int)} using {@link PMVMatrixSetup}.
-     * <p>
-     * {@inheritDoc}
-     * </p>
-     * @see PMVMatrixSetup
-     * @see #setPMVMatrixSetup(PMVMatrixSetup)
-     * @see #setupMatrix(PMVMatrix, int, int, int, int)
-     * @see #getBounds()
-     * @see #getBoundsCenter()
-     */
-    @Override
-    public void reshape(final GLAutoDrawable drawable, final int x, final int y, final int width, final int height) {
-        renderer.reshapeNotify(x, y, width, height);
-
-        setupMatrix(renderer.getMatrix(), x, y, width, height);
-        pmvMatrixSetup.setPlaneBox(planeBox, renderer.getMatrix(), x, y, width, height);
-    }
-
     private static final int[] sampleCountGLSelect = { -1 };
 
     private void display(final GLAutoDrawable drawable, final Object[] shapesS, final boolean glSelect) {
-- 
cgit v1.2.3