Author: pyaschenko
Date: 2008-03-18 11:51:27 -0400 (Tue, 18 Mar 2008)
New Revision: 6914
Modified:
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js
Log:
RF-2202
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-03-18
15:48:28 UTC (rev 6913)
+++
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js 2008-03-18
15:51:27 UTC (rev 6914)
@@ -855,6 +855,9 @@
isWithin : function(event){
var within = true;
var targetElement = event.relatedTarget;
+
+ while (targetElement.nodeType!=1) targetElement = targetElement.parentNode;
+
var srcElement = event.target;
var layer = $(this.id);
if (targetElement) {
@@ -1186,8 +1189,9 @@
var within = false;
Event.extend(event);
var targetElement = event.relatedTarget;
- var srcElement = Event.element(event);
-
+
+ while (targetElement.nodeType!=1) targetElement = targetElement.parentNode;
+
if (targetElement) {
within = targetElement == element ||
$(targetElement).descendantOf(element);
Show replies by date