-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hi, how to deny to select items in a tree? I do a tree menu and I do not want top level tree items to be selectable.
I have added onClick eventhander to a treecell, which does treeitem.setSelected(false). But the problem is, that:
- the other item is deselected, so nothing is selected
- the hover highlight dissapears
Thanks very much
Andy
@xmedeko
Hi xmedeko.
We have a method named setDisabled(boolean disabled), you can design like this:
<treeitem disabled="true">
But the disabled treeitem will have defferent CSS style, so just declare your own style if you need.
Regards
/Joy
Many thanks, that was it, I have added a sclass="main-index-menu" to the tree and style
.main-index-menu tr.z-tree-row-disd * { color: black !important; cursor: pointer !important; } .main-index-menu tr.z-tree-row-disd :hover { background: #DAE7F6 none repeat scroll 0 0; }
Asked: 2009-10-14 08:54:21 +0800
Seen: 332 times
Last updated: Oct 15 '09