2015-05-14 193 views
0

最近我們從IE 9升級到IE 11.菜單欄被禁用,所以當我在企業模式下打開菜單欄開始工作,但子菜單與主菜單欄重疊。子菜單重疊IE主菜單11

子菜單代碼

menubar.prototype=new menu(); 
menuitem.prototype.showsubmenu=function(bDelayed) 
{ 
    var sm=this.submenu(); 
    var pm=this.parentmenu(); 
    if(sm && !this.disabled) 
    { 
     pm._abouttoshowsubmenu=true; 
     var oThis=this; 
     sm._showTimer=window.setTimeout("eventListeners.menuItem.onshowtimer(\""+this.id+showtimeout)"); 
    } 
} 

menuitem.prototype.tohtml.funcyion() 
{ 
    var cssClass=this.getcssClass(); 
    var tooltips=this.gettooltips(); 
    return <tr> ("cssClass!= ""? "\cssClass :"") + 
      ("tooltips!= ""? "\tooltips:"") + 
      (!this.styles="" "display:none: "") + 
      ">"+ 
} 

Menuitem.prototype.positionSubmenu=function() 
{ 
    var dir=this.submenudirection;//its vertical 
    var e1=this._htmlelement; 
    var useInsets=this._useInsets; 
    var sm=this.submenu; 
    var oThis=this; 
    if(!sm._iscssfileloaded()) 
    { 
     window.setTimeout("eventListeners.menuItem.onpostionsubmenutimer(\""+this.id+showtimeout)"); 
     return; 
    } 
    var rect={ 
     left:posLib.getscreenleft(e1), 
     top:posLib.getscreenTop(e1), 
     width:e1.offsetwidth, 
     height:e1.offsetheight, 
    }; 
    var menurect={ 
     left:sm.getleft(), 
     top:sm.gettop(), 
     width:sm.getpreferredwidth(), 
     height:sm.getpreferredheight(), 
     insetleft:useinset?sm.getinsetleft():0, 
     insetright:useinset?sm.insetrightt():0, 
     insettop:useinset?sm.getinsettop():0, 
     insetbottom:useinset?sm.getinsetbottom():0 

     var scrollBefore=sm._scrollingMode; 
     sm.show(left,top,width,height); 
     if(sm._scrollingMode!=scrollBefore) 
     this.positionSubmenu(); 
    }; 
} 

menubar.prototype.getLeft=function() 
{ 
    return poslib.getscreenleft(this._htmlelement); 
} 

menubar.prototype.gettop=function() 
{ 
    return poslib.getscreenleft(this._htmlelement); 
} 

menubar.prototype.getinsetLeft=function() 
{ 
    return parseint(this._htmlelement.currentstyle.borderleftwidth); 
} 

menubar.prototype.getinsettop=function() 
{ 
    return parseint(this._htmlelement.currentstyle.bordertopwidth); 
} 

menubar.prototype.getinsetbottom=function() 
{ 
    return parseint(this._htmlelement.currentstyle.borderbottomwidth); 
} 

menubar.prototype.getinsetright=function() 
{ 
    return parseint(this._htmlelement.currentstyle.borderrightwidth); 
} 

如果有誰知道它或任何建議請回復?

+0

HTML應該遵循這種問題。 – hina10531

+0

'menuitem.prototype.tohtml.funcyion()'可能沒有幫助 – DBS

+0

你並沒有正確連接你的字符串。看看語法突出顯示,看看在哪裏。 –

回答

0

是的,你是正確的tohtml函數有一些問題。我改變了邏輯和它的工作正常。感謝您的建議