diff options
author | Artur Signell <artur.signell@itmill.com> | 2009-10-02 08:13:30 +0000 |
---|---|---|
committer | Artur Signell <artur.signell@itmill.com> | 2009-10-02 08:13:30 +0000 |
commit | 837079f5edf9ffec370f871986ee7844bf3f2d4c (patch) | |
tree | ef9ea25b87f9805412982680ca9cba195825191e /src | |
parent | 7fe6d676515b00411764e8ed176f550cd9fd246a (diff) | |
download | vaadin-framework-837079f5edf9ffec370f871986ee7844bf3f2d4c.tar.gz vaadin-framework-837079f5edf9ffec370f871986ee7844bf3f2d4c.zip |
Fix for #3450 - isActive should wait until loading indicator has disappeared
svn changeset:9034/svn branch:6.1
Diffstat (limited to 'src')
-rwxr-xr-x | src/com/vaadin/terminal/gwt/client/ApplicationConnection.java | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java b/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java index 7c8f49d8bc..c65e787cce 100755 --- a/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java +++ b/src/com/vaadin/terminal/gwt/client/ApplicationConnection.java @@ -63,6 +63,7 @@ public class ApplicationConnection { /** * @deprecated use UIDL_SECURITY_TOKEN_ID instead */ + @Deprecated public static final String UIDL_SECURITY_HEADER = UIDL_SECURITY_TOKEN_ID; public static final String PARAM_UNLOADBURST = "onunloadburst"; @@ -162,7 +163,7 @@ public class ApplicationConnection { var ap = this; var client = {}; client.isActive = function() { - return ap.@com.vaadin.terminal.gwt.client.ApplicationConnection::hasActiveRequest()(); + return ap.@com.vaadin.terminal.gwt.client.ApplicationConnection::hasActiveRequest()() || ap.@com.vaadin.terminal.gwt.client.ApplicationConnection::isLoadingIndicatorVisible()(); } var vi = ap.@com.vaadin.terminal.gwt.client.ApplicationConnection::getVersionInfo()(); if (vi) { @@ -602,6 +603,17 @@ public class ApplicationConnection { } } + public boolean isLoadingIndicatorVisible() { + if (loadElement == null) { + return false; + } + if (loadElement.getStyle().getProperty("display").equals("none")) { + return false; + } + + return true; + } + private static native ValueMap parseJSONResponse(String jsonText) /*-{ return eval('(' + jsonText + ')'); |