]> source.dussan.org Git - vaadin-framework.git/commitdiff
Fixed absolute layout class cast exception #10155 30/230/1
authorJohn Ahlroos <john@vaadin.com>
Thu, 8 Nov 2012 10:03:45 +0000 (12:03 +0200)
committerJohn Ahlroos <john@vaadin.com>
Thu, 8 Nov 2012 10:03:45 +0000 (12:03 +0200)
Change-Id: I5a9772e2d4082453923cfdca17bcef34e833adda

client/src/com/vaadin/client/ui/absolutelayout/VAbsoluteLayout.java

index 26ee4409fbbe01894b3bcad8b75c45c32907f83c..0cfd4fb8e5974ef8044092a049490805d58a8bef 100644 (file)
@@ -80,7 +80,7 @@ public class VAbsoluteLayout extends ComplexPanel {
             wrapper.destroy();
             return super.remove(wrapper);
         }
-        return false;
+        return super.remove(w);
     }
 
     /**
@@ -246,9 +246,11 @@ public class VAbsoluteLayout extends ComplexPanel {
      */
     protected AbsoluteWrapper getChildWrapper(Widget child) {
         for (Widget w : getChildren()) {
-            AbsoluteWrapper wrapper = (AbsoluteWrapper) w;
-            if (wrapper.getWidget() == child) {
-                return wrapper;
+            if (w instanceof AbsoluteWrapper) {
+                AbsoluteWrapper wrapper = (AbsoluteWrapper) w;
+                if (wrapper.getWidget() == child) {
+                    return wrapper;
+                }
             }
         }
         return null;