Browse Source

Fix issue with no drawing not updated due to its size.

Holt59 3 years ago
parent
commit
f2f65b85d4
1 changed files with 4 additions and 1 deletions
  1. 4
    1
      src/main/org/insa/base/Launch.java

+ 4
- 1
src/main/org/insa/base/Launch.java View File

@@ -1,5 +1,6 @@
1 1
 package org.insa.base;
2 2
 
3
+import java.awt.BorderLayout;
3 4
 import java.awt.Dimension;
4 5
 import java.io.BufferedInputStream;
5 6
 import java.io.DataInputStream;
@@ -29,10 +30,12 @@ public class Launch {
29 30
             @Override
30 31
             public void run() {
31 32
                 JFrame frame = new JFrame("BE Graphes - Launch");
32
-                frame.setContentPane(basicDrawing);
33
+                frame.setLayout(new BorderLayout());
33 34
                 frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
34 35
                 frame.setVisible(true);
35 36
                 frame.setSize(new Dimension(800, 600));
37
+                frame.setContentPane(basicDrawing);
38
+                frame.validate();
36 39
             }
37 40
         });
38 41
         return basicDrawing;

Loading…
Cancel
Save