diff options
author | michaelvogt <michael@vaadin.com> | 2013-04-15 17:35:18 +0300 |
---|---|---|
committer | Vaadin Code Review <review@vaadin.com> | 2013-04-24 07:01:08 +0000 |
commit | 7900166360dac2d2ae8885e0151f46cad472805f (patch) | |
tree | a8734d0c3ad12ed6f437a5923f158486e6775c26 /client | |
parent | c8ed703a5899d62f711bc184ada5309a0b81564e (diff) | |
download | vaadin-framework-7900166360dac2d2ae8885e0151f46cad472805f.tar.gz vaadin-framework-7900166360dac2d2ae8885e0151f46cad472805f.zip |
TestBench test for tree (#11612)
Together with fix for tree to pass the test
Change-Id: I3d6bead220ab61b171a267d15bda2570f7351d49
Diffstat (limited to 'client')
-rw-r--r-- | client/src/com/vaadin/client/ui/VTree.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/client/src/com/vaadin/client/ui/VTree.java b/client/src/com/vaadin/client/ui/VTree.java index e08b483c8c..51c00ca310 100644 --- a/client/src/com/vaadin/client/ui/VTree.java +++ b/client/src/com/vaadin/client/ui/VTree.java @@ -877,7 +877,8 @@ public class VTree extends FocusElementPanel implements VHasDropHandler, String labelId = DOM.createUniqueId(); addStyleName(CLASSNAME); - getElement().setId(DOM.createUniqueId()); + String treeItemId = DOM.createUniqueId(); + getElement().setId(treeItemId); Roles.getTreeitemRole().set(getElement()); Roles.getTreeitemRole().setAriaSelectedState(getElement(), SelectedValue.FALSE); @@ -889,6 +890,7 @@ public class VTree extends FocusElementPanel implements VHasDropHandler, + "-caption"); Element wrapper = DOM.createDiv(); wrapper.setId(labelId); + wrapper.setAttribute("for", treeItemId); nodeCaptionSpan = DOM.createSpan(); DOM.appendChild(getElement(), nodeCaptionDiv); |