]> source.dussan.org Git - vaadin-framework.git/commitdiff
Fix NPE caused by setting ApplicationConnection too late (#12736)
authorArtur Signell <artur@vaadin.com>
Mon, 4 Nov 2013 09:25:50 +0000 (11:25 +0200)
committerVaadin Code Review <review@vaadin.com>
Mon, 4 Nov 2013 09:39:53 +0000 (09:39 +0000)
Change-Id: Ib5b3bc7123ffd2f212fb6e242ee07175ff743b0f

client/src/com/vaadin/client/ui/window/WindowConnector.java

index 4b839384a23dfe78de602a8e277e72af4970e260..ff2e93a3b2d0e703ea89baad3ec9be53508a3431 100644 (file)
@@ -99,6 +99,8 @@ public class WindowConnector extends AbstractSingleComponentContainerConnector
         super.init();
 
         VWindow window = getWidget();
+        window.id = getConnectorId();
+        window.client = getConnection();
 
         getLayoutManager().registerDependency(this,
                 window.contentPanel.getElement());
@@ -127,9 +129,6 @@ public class WindowConnector extends AbstractSingleComponentContainerConnector
         VWindow window = getWidget();
         String connectorId = getConnectorId();
 
-        window.id = getConnectorId();
-        window.client = client;
-
         // Workaround needed for Testing Tools (GWT generates window DOM
         // slightly different in different browsers).
         window.closeBox.setId(connectorId + "_window_close");