]> source.dussan.org Git - vaadin-framework.git/commitdiff
Does not draw window contents if we're going to another URL. Fixes #2144
authorMarc Englund <marc.englund@itmill.com>
Fri, 10 Oct 2008 05:33:57 +0000 (05:33 +0000)
committerMarc Englund <marc.englund@itmill.com>
Fri, 10 Oct 2008 05:33:57 +0000 (05:33 +0000)
svn changeset:5620/svn branch:trunk

src/com/itmill/toolkit/terminal/gwt/client/ui/IView.java

index 8e601bd140d282da9343085cc833922247f06e2a..5f831124fcbde6b9528933d6a81e121f5983acd0 100644 (file)
@@ -149,6 +149,7 @@ public class IView extends SimplePanel implements Container,
         int childIndex = 0;
 
         // Open URL:s
+        boolean isClosed = false; // was this window closed?
         while (childIndex < uidl.getChildCount()
                 && "open".equals(uidl.getChildUIDL(childIndex).getTag())) {
             final UIDL open = uidl.getChildUIDL(childIndex);
@@ -157,6 +158,7 @@ public class IView extends SimplePanel implements Container,
             if (target == null) {
                 // This window is closing. Send close event before
                 // going to the new url
+                isClosed = true;
                 onWindowClosed();
                 goTo(url);
             } else {
@@ -165,6 +167,10 @@ public class IView extends SimplePanel implements Container,
             }
             childIndex++;
         }
+        if (isClosed) {
+            // don't render the content
+            return;
+        }
 
         // Draw this application level window
         UIDL childUidl = uidl.getChildUIDL(childIndex);