Author: nbelaevski
Date: 2008-05-20 20:19:11 -0400 (Tue, 20 May 2008)
New Revision: 8665
Modified:
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js
Log:
http://jira.jboss.com/jira/browse/RF-3461
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-05-20
18:35:01 UTC (rev 8664)
+++
trunk/ui/menu-components/src/main/resources/org/richfaces/renderkit/html/scripts/menu.js 2008-05-21
00:19:11 UTC (rev 8665)
@@ -39,6 +39,14 @@
levels:
['','','','','','','','','','',''],
detectWidth: function(){
this.IE = (navigator.userAgent.indexOf('MSIE') > -1) &&
(navigator.userAgent.indexOf('Opera') < 0);
+
+ if (this.IE) {
+ var agentSplit = /MSIE\s+(\d+(?:\.\d+)?)/.exec(navigator.userAgent);
+ if (agentSplit) {
+ this.IE_VERSION = parseFloat(agentSplit[1]);
+ }
+ }
+
this.NS = (navigator.userAgent.indexOf('Netscape') > -1);
}
,
@@ -144,12 +152,12 @@
initIFrame: function(layer) {
var menu = $(layer);
var iframe = new Insertion.Before(menu,
- "<iframe src=\"javascript:''\" id=\"" + menu.id +
"_iframe\" style=\" position: absolute; z-index: 1;\"
class=\"underneath_iframe\">" + "</iframe>");
+ "<iframe src=\"javascript:''\" id=\"" + menu.id +
"_iframe\" style=\" position: absolute; z-index: 1;\"
frameborder=\"0\" scrolling=\"no\"
class=\"underneath_iframe\">" + "</iframe>");
return iframe;
},
ieSelectWorkAround: function(menuName, on){
- if(this.IE || this.NS) {
+ if((this.IE && this.IE_VERSION < 7) || this.NS) {
var menu = $(menuName);
menuName = menu.id;
var iframe = $(menuName + "_iframe");