U_Dialog.js 1.6 KB

123456
  1. // Licensed Materials - Property of IBM
  2. // IBM Cognos Products: hal
  3. // (C) Copyright IBM Corp. 2003, 2017.
  4. // US Government Users Restricted Rights - Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
  5. var U_Dialog={};U_Dialog.F_KeepDialogsVisible=function(){if(window["C_Dialog"]){C_Dialog.F_KeepDialogsVisible();}if(window["C_ModelessDialog"]){C_ModelessDialog.F_KeepDialogsVisible();}};U_Dialog.F_KeepDialogVisible=function(tbl){var div=tbl.parentNode;var body=tbl.ownerDocument.body;if((div.offsetLeft+div.offsetWidth)>(body.clientWidth+body.scrollLeft)){div.style.left=Math.F_NonNeg((body.clientWidth+body.scrollLeft)-div.offsetWidth)+ "px";}if((div.offsetTop+div.offsetHeight)>(body.clientHeight+body.scrollTop)){div.style.top=Math.F_NonNeg((body.clientHeight+body.scrollTop)-div.offsetHeight)+ "px";}if(!G_BrowserInfo.M_bIsIE&&(tbl._h841!="sizable")){var _h061=div.scrollWidth;if(div.offsetWidth<_h061){div.style.width=_h061+"px";this.F_KeepDialogVisible(body, tbl);}var _hYZ=div.scrollHeight;if(div.offsetHeight<_hYZ){div.style.height=_hYZ+"px";this.F_KeepDialogVisible(body, tbl);}}};U_Dialog.F_TemporaryFixForDblClickInStandardsMode=function(_h0P1){var nl=_h0P1.getElementsByTagName("BUTTON");for(var i=0;i<nl.length;i++){var btn=nl.item(i);if(btn.getAttribute( "onclick" )==btn.getAttribute( "ondblclick" ) ){btn.removeAttribute("ondblclick");}}};U_Dialog.F_GetHighestZIndex=function(){var _h691=window["C_Dialog"]?C_Dialog.F_GetHighestZIndex():0;var _h1R=window["C_ModelessDialog"]?C_ModelessDialog.F_GetHighestZIndex():0;return(_h691>_h1R)?_h691:_h1R;};