Author: nbelaevski
Date: 2008-08-31 17:50:20 -0400 (Sun, 31 Aug 2008)
New Revision: 10253
Modified:
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js
Log:
https://jira.jboss.org/jira/browse/RF-4181
Modified:
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js
===================================================================
---
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js 2008-08-31
20:35:40 UTC (rev 10252)
+++
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js 2008-08-31
21:50:20 UTC (rev 10253)
@@ -617,7 +617,13 @@
}
this.event = e;
- this.element = Event.findElement(e, 'div');
+
+ var elt = Event.element(e);
+ while (elt && (!elt.tagName || elt.tagName.toLowerCase() != 'div')) {
+ elt = elt.parentNode;
+ } //Event.findElement(e, 'div');
+
+ this.element = elt;
if (this.element.id.indexOf(":folder") == (this.element.id.length -7) ) {
this.element = this.element.parentNode;
}