]> source.dussan.org Git - vaadin-framework.git/commitdiff
Fix broken newlines from previous commit
authorLeif Åstrand <leif@vaadin.com>
Tue, 7 Feb 2012 11:22:09 +0000 (13:22 +0200)
committerLeif Åstrand <leif@vaadin.com>
Tue, 7 Feb 2012 11:22:09 +0000 (13:22 +0200)
src/com/vaadin/terminal/gwt/client/ui/VAbstractPaintableWidgetContainer.java

index 87bf245217207327325a8499fc1e60d7985a25e0..e69de29bb2d1d6434b8b29ae775ad8c2e48c5391 100644 (file)
@@ -1,51 +0,0 @@
-/*\r
-@VaadinApache2LicenseForJavaFiles@\r
- */\r
-package com.vaadin.terminal.gwt.client.ui;\r
-\r
-import java.util.ArrayList;\r
-import java.util.Collection;\r
-\r
-import com.google.gwt.user.client.ui.HasWidgets;\r
-import com.google.gwt.user.client.ui.Widget;\r
-import com.vaadin.terminal.gwt.client.VPaintableMap;\r
-import com.vaadin.terminal.gwt.client.VPaintableWidget;\r
-import com.vaadin.terminal.gwt.client.VPaintableWidgetContainer;\r
-\r
-public abstract class VAbstractPaintableWidgetContainer extends\r
-        VAbstractPaintableWidget implements VPaintableWidgetContainer {\r
-\r
-    /**\r
-     * Default constructor\r
-     */\r
-    public VAbstractPaintableWidgetContainer() {\r
-    }\r
-\r
-    public Collection<VPaintableWidget> getChildren() {\r
-        Collection<VPaintableWidget> children = new ArrayList<VPaintableWidget>();\r
-\r
-        addDescendantPaintables(getWidgetForPaintable(), children,\r
-                VPaintableMap.get(getConnection()));\r
-\r
-        return children;\r
-    }\r
-\r
-    private static void addDescendantPaintables(Widget widget,\r
-            Collection<VPaintableWidget> paintables, VPaintableMap paintableMap) {\r
-        // FIXME: Store hierarchy instead of doing lookup every time\r
-\r
-        if (widget instanceof HasWidgets) {\r
-            for (Widget child : (HasWidgets) widget) {\r
-                VPaintableWidget paintable = paintableMap.getPaintable(child);\r
-                if (paintable != null) {\r
-                    // If child is a paintable, add it to the collection\r
-                    paintables.add(paintable);\r
-                } else {\r
-                    // Else keep looking for paintables inside the child widget\r
-                    addDescendantPaintables(child, paintables, paintableMap);\r
-                }\r
-            }\r
-        }\r
-    }\r
-\r
-}\r