Fix windows (and toolbar) rendering 99/13599/2
Bruno JOFRET [Thu, 30 Jan 2014 07:59:26 +0000 (08:59 +0100)]
Change-Id: Ia2c5a5cef09f52727136f92a46cd260105f3f870

scilab/modules/gui/src/java/org/scilab/modules/gui/SwingView.java
scilab/modules/gui/src/java/org/scilab/modules/gui/bridge/tab/SwingScilabCommonPanel.java

index a4cf151..b9697af 100644 (file)
@@ -429,7 +429,7 @@ public final class SwingView implements GraphicView {
                 tab.setEventHandler(figure.getEventHandlerString());
                 tab.setEventHandlerEnabled(figure.getEventHandlerEnable());                
 
-                window.setVisible(true);
+                
                 tab.setVisible(true);
                 tab.setName(figureTitle);
 
@@ -442,6 +442,7 @@ public final class SwingView implements GraphicView {
                 tab.update(__GO_SIZE__, GraphicController.getController().getProperty(id, __GO_SIZE__));
                 tab.update(__GO_POSITION__, GraphicController.getController().getProperty(id, __GO_POSITION__));
                 // TODO set other default properties
+                window.pack();
                 return tab;
             case Frame:
                 SwingScilabFrame frame = new SwingScilabFrame();
index cf5308f..67ad2b5 100644 (file)
@@ -113,7 +113,6 @@ public class SwingScilabCommonPanel {
                    ) {
                     Integer[] axesSize = (Integer[]) GraphicController.getController().getProperty(component.getId(), __GO_AXES_SIZE__);
                     Integer[] newAxesSize = {axesSize[0] + deltaFigureX, axesSize[1] + deltaFigureY};
-                    System.err.println("New Axes Size = " + newAxesSize);
                     GraphicController.getController().setProperty(component.getId(), __GO_AXES_SIZE__, newAxesSize);
                 }
                 break;