Author: tan_pham_dinh
Date: 2009-11-06 05:53:20 -0500 (Fri, 06 Nov 2009)
New Revision: 516
Modified:
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/portal/UIPortalNavigation.js
Log:
GTNPORTAL-85: Error in displaying ToolbarPortlet in IE
Modified:
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/portal/UIPortalNavigation.js
===================================================================
---
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/portal/UIPortalNavigation.js 2009-11-06
10:25:26 UTC (rev 515)
+++
portal/trunk/web/eXoResources/src/main/webapp/javascript/eXo/portal/UIPortalNavigation.js 2009-11-06
10:53:20 UTC (rev 516)
@@ -96,18 +96,19 @@
}
}
- // Sub menus items
- var menuItems = DOMUtil.findDescendantsByClass(topContainer, "div",
this.tabStyleClass);
- for(var i = 0; i < menuItems.length; i++) {
- var menuItem = menuItems[i];
- menuItem.onmouseover = eXo.portal.UIPortalNavigation.onMenuItemOver;
- menuItem.onmouseout = eXo.portal.UIPortalNavigation.onMenuItemOut;
-
- // Set an id to each container for future reference
- var cont = DOMUtil.findAncestorByClass(menuItem, this.containerStyleClass) ;
- if (!cont.id) cont.id = DOMUtil.generateId("PortalNavigationContainer");
- cont.resized = false;
- }
+ var itemConts = DOMUtil.findDescendantsByClass(topContainer, "div",
this.containerStyleClass);
+ for (var i = 0; i < itemConts.length; i++) {
+ var cont = itemConts[i];
+ if(!cont.id) cont.id = DOMUtil.generateId("PortalNavigationContainer");
+ cont.resized = false;
+
+ var items = DOMUtil.findDescendantsByClass(cont, "div", this.tabStyleClass);
+ if(items.length == 0) cont.parentNode.removeChild(cont);
+ for(var j = 0; j < items.length; j ++) {
+ items[i].onmouseover = eXo.portal.UIPortalNavigation.onMenuItemOver;
+ items[i].onmouseout = eXo.portal.UIPortalNavigation.onMenuItemOut;
+ }
+ }
};
/**
* Sets the tab style on mouse over and mouse out