]> source.dussan.org Git - vaadin-framework.git/commitdiff
Re-added ApplicationConnection.updateCaption to ease porting
authorArtur Signell <artur@vaadin.com>
Thu, 12 Apr 2012 09:22:20 +0000 (12:22 +0300)
committerArtur Signell <artur@vaadin.com>
Thu, 12 Apr 2012 09:22:20 +0000 (12:22 +0300)
src/com/vaadin/terminal/gwt/client/ApplicationConnection.java
src/com/vaadin/terminal/gwt/client/ui/AbstractComponentConnector.java

index a2816728f97c03a5533413b03ab5fc2ec0702e66..5ececb21043aade69b678aa4330f64e7336dd374 100644 (file)
@@ -45,6 +45,7 @@ import com.vaadin.terminal.gwt.client.communication.MethodInvocation;
 import com.vaadin.terminal.gwt.client.communication.RpcManager;
 import com.vaadin.terminal.gwt.client.communication.SharedState;
 import com.vaadin.terminal.gwt.client.communication.StateChangeEvent;
+import com.vaadin.terminal.gwt.client.ui.AbstractComponentConnector;
 import com.vaadin.terminal.gwt.client.ui.VContextMenu;
 import com.vaadin.terminal.gwt.client.ui.dd.VDragAndDropManager;
 import com.vaadin.terminal.gwt.client.ui.notification.VNotification;
@@ -2337,7 +2338,29 @@ public class ApplicationConnection {
     @Deprecated
     public void handleTooltipEvent(Event event, Widget owner, Object key) {
         handleTooltipEvent(event, getConnectorMap().getConnector(owner), key);
+    }
+
+    /**
+     * Method provided for backwards compatibility. Duties previously done by
+     * this method is now handled by the state change event handler in
+     * AbstractComponentConnector. The only function this method has is to
+     * return true if the UIDL is a "cached" update.
+     * 
+     * @param component
+     * @param uidl
+     * @param manageCaption
+     * @return
+     */
+    @Deprecated
+    public boolean updateComponent(Widget component, UIDL uidl,
+            boolean manageCaption) {
+        ComponentConnector connector = getConnectorMap()
+                .getConnector(component);
+        if (!AbstractComponentConnector.isRealUpdate(uidl)) {
+            return true;
+        }
 
+        return false;
     }
 
     @Deprecated
index f5f177b5d100e2d848ecab46ab96468e2481f7c4..9542bb81d4e2fcf2d348db4d07fd1432db83d988 100644 (file)
@@ -75,6 +75,7 @@ public abstract class AbstractComponentConnector extends AbstractConnector
         return state;
     }
 
+    @Deprecated
     public static boolean isRealUpdate(UIDL uidl) {
         return !uidl.hasAttribute("cached");
     }