summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFabian Lange <lange.fabian@gmail.com>2013-07-13 22:12:28 +0200
committerVaadin Code Review <review@vaadin.com>2013-07-15 05:31:46 +0000
commita93426164d5766fd7e0a687c1a7c98ce53aaa1c7 (patch)
tree50e50b09d817fc7cda2af679951c61a067756c2e
parent7f52b2e8221f58586b5c66dfa11b2bc2a79af204 (diff)
downloadvaadin-framework-a93426164d5766fd7e0a687c1a7c98ce53aaa1c7.tar.gz
vaadin-framework-a93426164d5766fd7e0a687c1a7c98ce53aaa1c7.zip
Improving performance of ConnectorTracker (#12218)
Swapping the if check in cleanConnectorMap to prevent unnecessary calls to isComponentVisible when the connector is in uninitializedConnectors set. Change-Id: If6305a908364f8a7bb51fd7302449c6f54c274a3
-rw-r--r--server/src/com/vaadin/ui/ConnectorTracker.java6
1 files changed, 3 insertions, 3 deletions
diff --git a/server/src/com/vaadin/ui/ConnectorTracker.java b/server/src/com/vaadin/ui/ConnectorTracker.java
index 85cdcdf65c..c2aeebcd44 100644
--- a/server/src/com/vaadin/ui/ConnectorTracker.java
+++ b/server/src/com/vaadin/ui/ConnectorTracker.java
@@ -296,9 +296,9 @@ public class ConnectorTracker implements Serializable {
uninitializedConnectors.remove(connector);
diffStates.remove(connector);
iterator.remove();
- } else if (!LegacyCommunicationManager
- .isConnectorVisibleToClient(connector)
- && !uninitializedConnectors.contains(connector)) {
+ } else if (!uninitializedConnectors.contains(connector)
+ && !LegacyCommunicationManager
+ .isConnectorVisibleToClient(connector)) {
uninitializedConnectors.add(connector);
diffStates.remove(connector);
if (getLogger().isLoggable(Level.FINE)) {