]> source.dussan.org Git - vaadin-framework.git/commitdiff
Another fix to ComponentLocator, this time fixed locators with
authorJohn Ahlroos <john@vaadin.com>
Wed, 5 Sep 2012 07:30:17 +0000 (10:30 +0300)
committerJohn Ahlroos <john@vaadin.com>
Wed, 5 Sep 2012 07:30:17 +0000 (10:30 +0300)
VBoxLayout/domChild

client/src/com/vaadin/client/ComponentLocator.java

index 017383e695e2db931f48d6c14c2002abfeb2c3e2..6cdccc0ff0aebef16024a86bfa72b023e0f17890 100644 (file)
@@ -269,6 +269,14 @@ public class ComponentLocator {
             if (part.startsWith("domChild[")) {
                 String childIndexString = part.substring("domChild[".length(),
                         part.length() - 1);
+
+                if (Util.findWidget(baseElement, null) instanceof VBoxLayout) {
+                    Element e = baseElement.getFirstChildElement().cast();
+                    if (e.getClassName().equals("v-expand")) {
+                        element = e;
+                    }
+                }
+
                 try {
                     int childIndex = Integer.parseInt(childIndexString);
                     element = DOM.getChild(element, childIndex);