var PopupWindow={init:function(){if(this.ArrPopupPos==undefined)this.ArrPopupPos=new Array();if(this.MaxzIndex==undefined)this.MaxzIndex=2000;if(this.PanelLock==undefined)this.PanelLock="";this.DragObject=null;this.MouseOffset=null;if(this.IsWrap==undefined)this.IsWrap=false;if(this.PopupPosition==undefined)this.PopupPosition=null;if(document.onmousemove!=undefined)this.OnmousemoveObject=document.onmousemove;if(document.onmouseup!=undefined)this.OnmouseupObject=document.onmouseup;if(document.onkeydown!=undefined)this.OnkeydownObject=document.onkeydown;document.onmousemove=f_PW_MouseMove;document.onmouseup=f_PW_MouseUp;this.ItemSelectID=null;this.Path=null;this.RootPath=null;this.Class=PopupWindowClass;},dispose:function(){this.DragObject=null;this.MouseOffset=null;if(this.OnmousemoveObject!=null)document.onmousemove=this.OnmousemoveObject;if(this.OnmouseupObject!=null)document.onmouseup=this.OnmouseupObject;if(this.OnkeydownObject!=null)document.onkeydown=this.OnkeydownObject;this.OnmousemoveObject=null;this.OnmouseupObject=null;this.OnkeydownObject=null;this.ItemSelectID=null;this.Path=null;this.Class=null;},ReleaseDocumentFunctionCatch:function(){if(this.OnmousemoveObject!=null)document.onmousemove=this.OnmousemoveObject;if(this.OnmouseupObject!=null)document.onmouseup=this.OnmouseupObject;if(this.OnkeydownObject!=null)document.onkeydown=this.OnkeydownObject;},CreateImagePopup:function(AP,Ay,AT,BI,Am,Ah,AK,AR,AB,AO){this.init();this.MaxzIndex=this.MaxzIndex+1;if(f_PW_CheckPanelNameExist(Ay)==true)return;var O=f_PW_CheckPanelExist();var R=AT.split("@");var BC=BI.split("@");var AC=parseInt(BC[Am].substring(0,BC[Am].indexOf("x")))+20;var Ap=parseInt(BC[Am].substring(BC[Am].indexOf("x")+1));var d=document;var r=d.documentElement;var ww=r.clientWidth+r.scrollLeft;var wh=r.clientHeight+r.scrollTop;if(Ap>(r.offsetHeight-75))Ah=false;if(AK==true){if(this.PanelLock.indexOf("|"+O+"|")==-1){this.CreateBlockElement(O);}}var AD=d.createElement("div");AD.id="PWImagePopup"+O+"_div";AD.style.cssText="width:"+AC+"px;top:"+(r.scrollTop+5)+"px;left:"+parseInt((ww/2)-(AC/2))+"px;position:absolute;margin:0px; padding:0px; border:0px;z-index:"+(AK?(this.MaxzIndex+1):this.MaxzIndex)+";opacity: 0;filter:alpha(opacity=0)";AD=d.body.insertBefore(AD,d.body.firstChild);AD.title=Ay;Fg=AR.split("|");var EG="";if(R.length>1){EG="<div class=\"PW_Div9\">"+"<a href=\"javascript:void(0)\" class=\"PW_Link1\" alt=\"First\" onclick=\"PopupWindow.FirstImage('"+AT+"','"+BI+"',"+O+","+Ah+","+AK+",'"+AR+"','"+AB+"',"+AO+");\"></a>"+"<a href=\"javascript:void(0)\" class=\"PW_Link2\" alt=\"Previous\" onclick=\"PopupWindow.PreImage('"+AT+"','"+BI+"',"+O+","+Ah+","+AK+",'"+AR+"','"+AB+"',"+AO+");\"></a>"+"<div id=\"PWImagePos"+O+"_lb\" class=\"PW_Div10\">"+(Am+1)+"/"+R.length+"</div>"+"<a href=\"javascript:void(0)\" class=\"PW_Link3\" alt=\"Next\" onclick=\"PopupWindow.NextImage('"+AT+"','"+BI+"',"+O+","+Ah+","+AK+",'"+AR+"','"+AB+"',"+AO+");\"></a>"+"<a href=\"javascript:void(0)\" class=\"PW_Link4\" alt=\"Last\" onclick=\"PopupWindow.LastImage('"+AT+"','"+BI+"',"+O+","+Ah+","+AK+",'"+AR+"','"+AB+"',"+AO+");\"></a>"+"</div>";}AD.innerHTML="<div class=\"PW_Div1\"></div>"+"<div class=\"PW_Div2\" style=\"width:"+(AC-24)+"px\">"+"<div id=\"PWDrag"+O+"_Div\" class=\"PW_Text1\" style=\"float:left;width:"+(AC-115)+"px;height:28px\" onMouseOver=\"this.style.cursor='move';\" ondblclick=\"PopupWindow.MaximizeWindow(this);\">"+AP+"</div>"+"<div class='PW_Div8' onclick=\"PopupWindow.ClosePopupWindow(this);"+(AB==null?"":AB)+"\">&nbsp;</div>"+(Fg[1]!="1"?"":"<div class='PW_Div11' onclick='PopupWindow.MaximizeWindow(this);'>&nbsp;</div>")+(Fg[2]!="1"?"":"<div class='PW_Div12' onclick='PopupWindow.MinimizeWindow(this,document.documentElement.offsetHeight - 30);'>&nbsp;</div>")+"</div>"+"<div class=\"PW_Div3\"></div>"+"<div style=\"width:"+AC+"px; background:#000; clear:both\">"+"<div class=\"PW_IMG2\" style=\"width:"+(AC-10)+"px;height:"+Ap+"px;margin-left:auto; margin-right:auto;text-align:center;padding-bottom:5px\">"+"<img id=\"PWPopupImage"+O+"_img\" src=\""+R[Am]+"\" alt=\"Image\" width=\""+(AC-20)+"\" height=\""+Ap+"\" />"+"</div>"+"<div id=\"PWBottomDrag"+O+"_Div\" class=\"PW_Div4\" style=\"width:"+(AC-10)+"px\">"+EG+"</div>"+"</div>"+"<div class=\"PW_Div5\"></div>"+"<div class=\"PW_Div6\" style=\"width:"+(AC-24)+"px\"></div>"+"<div class=\"PW_Div7\"></div>";var A9=r.offsetHeight-AD.offsetHeight;if(A9>0){AD.style.top=parseInt(A9/2)+r.scrollTop+"px";}var Bw=new OpacityTween(AD,Tween.strongEaseIn,0,100,0.4);Bw.start();if(Ah==false)f_PW_MakeDraggable(AD.id,AD.id,Ah);else f_PW_MakeDraggable("PWDrag"+O+"_Div",AD.id,Ah);this.ArrPopupPos[this.ArrPopupPos.length]=O;if(AO!=null&&AO==true){AD.childNodes[0].title="1";document.onkeydown=function(event){event=event||window.event;var Q=event.keyCode;if(Q==27){if(PopupWindow.ArrPopupPos.length>0){var A4=f_E("PWImagePopup"+PopupWindow.ArrPopupPos[PopupWindow.ArrPopupPos.length-1]+"_div");if(A4.childNodes[0].title=="1"){A4.childNodes[0].title="0";PopupWindow.ClosePopupWindow(A4);if(AB!=null)setTimeout(AB,1);}}}else if(R.length>1){if(Q==37){f_PW_PreImage(AT,BI,1,Ah,AK,AR,AB,AO);}else if(Q==38){f_PW_FirstImage(AT,BI,1,Ah,AK,AR,AB,AO);}else if(Q==39){f_PW_NextImage(AT,BI,1,Ah,AK,AR,AB,AO);}else if(Q==40){f_PW_LastImage(AT,BI,1,Ah,AK,AR,AB,AO);}}return false;};}},CreateHTMLPopup:function(AP,Ay,C,AC,Ap,Ah,AK,AR,AB,AO){this.init();this.MaxzIndex=this.MaxzIndex+1;if(f_PW_CheckPanelNameExist(Ay)==true)return;var O=f_PW_CheckPanelExist();var d=document;var r=d.documentElement;var ww=r.clientWidth+r.scrollLeft;var wh=r.clientHeight+r.scrollTop;if(Ap>(r.offsetHeight-75))Ah=false;if(AK==true){this.CreateBlockElement(O);}AR=AR.split("|");var AD=d.createElement("div");AD.id="PWImagePopup"+O+"_div";AD.style.cssText="width:"+AC+"px;top:"+(r.scrollTop+5)+"px;left:"+parseInt((ww/2)-(AC/2))+"px;position:absolute;margin:0px; padding:0px; border:0px;z-index:"+(AK?(this.MaxzIndex+1):this.MaxzIndex)+";opacity: 0;filter:alpha(opacity=0)";AD=d.body.insertBefore(AD,d.body.firstChild);AD.innerHTML="<div class=\"PW_Div1\"></div>"+"<div class=\"PW_Div2\" style=\"width:"+(AC-24)+"px\">"+"<div id=\"PWDrag"+O+"_Div\" class=\"PW_Text1\" style=\"float:left;width:"+(AC-115)+"px;height:28px\" onMouseOver=\"this.style.cursor='move';\""+(AR[1]!="1"?"":" ondblclick=\"PopupWindow.MaximizeWindow(this);\"")+">"+AP+"</div>"+"<div class='PW_Div8' onclick=\"PopupWindow.ClosePopupWindow(this);"+(AB==undefined?"":AB)+"\">&nbsp;</div>"+(AR[1]!="1"?"":"<div class='PW_Div11' onclick='PopupWindow.MaximizeWindow(this);'>&nbsp;</div>")+(AR[2]!="1"?"":"<div class='PW_Div12' onclick='PopupWindow.MinimizeWindow(this,document.documentElement.offsetHeight - 30);'>&nbsp;</div>")+"</div>"+"<div class=\"PW_Div3\"></div>"+"<div style=\"width:"+AC+"px; background:#000; clear:both\">"+"<div style=\"width:"+(AC-10)+"px;height:"+Ap+"px;margin-left:auto; margin-right:auto;text-align:left;background:#ffffff; overflow:auto\">"+C+"</div>"+"<div id=\"PWBottomDrag"+O+"_Div\" class=\"PW_Div4\" style=\"width:"+(AC-10)+"px\"></div>"+"</div>"+"<div class=\"PW_Div5\"></div>"+"<div class=\"PW_Div6\" style=\"width:"+(AC-24)+"px\"></div>"+"<div class=\"PW_Div7\"></div>";var A9=r.offsetHeight-AD.offsetHeight;if(A9>0){AD.style.top=parseInt(A9/2)+r.scrollTop+"px";}var Bw=new OpacityTween(AD,Tween.strongEaseIn,0,100,0.4);Bw.start();f_PW_MakeDraggable("PWDrag"+O+"_Div",AD.id,Ah);f_PW_MakeDraggable("PWBottomDrag"+O+"_Div",AD.id,Ah);this.ArrPopupPos[this.ArrPopupPos.length]=O;if(AO!=undefined&&AO==true){AD.childNodes[0].title="1";document.onkeydown=function(event){event=event||window.event;var Q=event.keyCode;if(Q==27){if(PopupWindow.ArrPopupPos.length>0){var A4=f_E("PWImagePopup"+PopupWindow.ArrPopupPos[PopupWindow.ArrPopupPos.length-1]+"_div");if(A4.childNodes[0].title=="1"){A4.childNodes[0].title="0";PopupWindow.ClosePopupWindow(A4);if(AB!=null)setTimeout(AB,1);}}return false;}};}},CreateHTMLPopup2:function(AP,Ay,C,AC,Ap,Ah,AK,AB,AO){this.init();this.MaxzIndex=this.MaxzIndex+1;if(f_PW_CheckPanelNameExist(Ay)==true)return;var O=f_PW_CheckPanelExist();var d=document;var r=d.documentElement;var ww=r.clientWidth+r.scrollLeft;var wh=r.clientHeight+r.scrollTop;if(Ap>(r.offsetHeight-75))Ah=false;if(AK==true){this.CreateBlockElement(O);}var AD=d.createElement("div");AD.id="PWImagePopup"+O+"_div";AD.style.cssText="width:"+AC+"px;height:"+(Ap+10)+"px;top:"+(r.scrollTop+5)+"px;left:"+parseInt((ww/2)-(AC/2))+"px;z-index:"+(AK?(this.MaxzIndex+1):this.MaxzIndex)+";opacity: 1;filter:alpha(opacity=100)";AD.className="PW_Div14";AD=d.body.insertBefore(AD,d.body.firstChild);AD.innerHTML="<div style='float:left;width:100%;position:relative;height:"+Ap+"px'><a href='javascript:void(0)' class='PW_Link6' style='left:"+(AC-10)+"px' onclick='PopupWindow.ClosePopupWindow(this);'></a>"+C+"</div>"+"<div class='PW_Div15 PW_Text2'>"+AP+"</div>";var A9=r.offsetHeight-AD.offsetHeight;if(A9>0){AD.style.top=parseInt(A9/2)+r.scrollTop+"px";}f_PW_MakeDraggable("PWDrag"+O+"_Div",AD.id,Ah);this.ArrPopupPos[this.ArrPopupPos.length]=O;if(AO!=undefined&&AO==true){AD.childNodes[0].title="1";document.onkeydown=function(event){event=event||window.event;var Q=event.keyCode;if(Q==27){if(PopupWindow.ArrPopupPos.length>0){var A4=f_E("PWImagePopup"+PopupWindow.ArrPopupPos[PopupWindow.ArrPopupPos.length-1]+"_div");if(A4.childNodes[0].title=="1"){A4.childNodes[0].title="0";PopupWindow.ClosePopupWindow(A4);if(AB!=null)setTimeout(AB,1);}}return false;}};}},CreateHTMLPopup3:function(AP,Ay,C,AC,Ap,Ah,AK,AB,AO){this.init();this.MaxzIndex=this.MaxzIndex+1;if(f_PW_CheckPanelNameExist(Ay)==true)return;var O=f_PW_CheckPanelExist();var d=document;var r=d.documentElement;var ww=r.clientWidth+r.scrollLeft;var wh=r.clientHeight+r.scrollTop;if(Ap>(r.offsetHeight-75))Ah=false;if(AK==true){this.CreateBlockElement(O);}var AD=d.createElement("div");AD.id="PWImagePopup"+O+"_div";AD.style.cssText="position:absolute;width:"+AC+"px;height:"+(Ap+10)+"px;top:"+(r.scrollTop+5)+"px;left:"+parseInt((ww/2)-(AC/2))+"px;z-index:"+(AK?(this.MaxzIndex+1):this.MaxzIndex);AD=d.body.insertBefore(AD,d.body.firstChild);AD.innerHTML=C;var A9=r.offsetHeight-AD.offsetHeight;if(A9>0){AD.style.top=parseInt(A9/2)+r.scrollTop+"px";}f_PW_MakeDraggable("PWDrag"+O+"_Div",AD.id,Ah);this.ArrPopupPos[this.ArrPopupPos.length]=O;if(AO!=undefined&&AO==true){AD.childNodes[0].title="1";document.onkeydown=function(event){event=event||window.event;var Q=event.keyCode;if(Q==27){if(PopupWindow.ArrPopupPos.length>0){var A4=f_E("PWImagePopup"+PopupWindow.ArrPopupPos[PopupWindow.ArrPopupPos.length-1]+"_div");if(A4.childNodes[0].title=="1"){A4.childNodes[0].title="0";PopupWindow.ClosePopupWindow(A4);if(AB!=null)setTimeout(AB,1);}}return false;}};}},CreateContextMenu:function(event,Af,Ab,HQ,HR,HL,FW){var FV=FW==null?2:FW;if(!event)event=window.event;var Q;if(BrowserDetect.browser=="Opera")Q=event.which;else Q=event.button;if(Q!=FV&&Ab<=1)return;this.init();f_CreateBlockPage("BlockPage_layer","PopupWindow.RemoveContextMenu("+Ab+");");var CH=f_GetHiestZIndexOnPage()+1;document.oncontextmenu=function(){return false;};f_PW_RemoveContextMenu(Ab);var BE="["+Ab+"]";var CI="["+(Ab+1)+"]";var AW=HQ.split(BE);var AF=HR.split(BE);var Ag=HL.split(BE);if(Af==null){Af=f_GetMouseCoords(event);}if(Q==FV||Ab>1){var EE=Af[1];var Aa=AF.length;var C="<table cellspacing='0' cellpadding='3' class='PW_TD1'>";for(i=0;i<Aa;){if(AF[i]==""){C+="<tr><td colspan='2' style='height:10px'></td></tr>";EE+=11;}else{if(AW[i].indexOf(CI)!=-1){var FP=AF[i].substring(0,AF[i].indexOf(CI));var HA=AW[i].substring(0,AW[i].indexOf(CI));C+="<tr onclick=\"var p_Ctrl = f_E('ContextMenu"+Ab+"_div');PopupWindow.CreateContextMenu(event,new Array(p_Ctrl.offsetLeft + p_Ctrl.offsetWidth,"+EE+"),"+(Ab+1)+",'"+AW[i].substring(AW[i].indexOf(CI)+3)+"','"+AF[i].substring(AF[i].indexOf(CI)+3)+"','"+Ag[i].substring(Ag[i].indexOf(CI)+3)+"');\">"+"<td id='ContextMenu_"+FP+"_box' style='width:20px' class='PW_TD2 "+HA+"'></td><td class='PW_TD2'><div style='float:left;height:100%'><a href='javascript:void(0)' class='PW_Link5'>"+FP+"</a></div><div class='QueryAnalyzer_DIV23'>&nbsp;</div></td>"+"</tr>";}else{C+="<tr>"+"<td style='width:20px' class='PW_TD2 "+AW[i]+"'></td><td class='PW_TD2'><a href='javascript:void(0)' class='PW_Link5' onclick=\""+Ag[i]+"PopupWindow.RemoveContextMenu(1);\">"+AF[i]+"</a></td>"+"</tr>";}EE+=28;}i++;}C+="</table>";var AE=document.createElement("div");AE.id="ContextMenu"+Ab+"_div";AE.style.cssText="position:absolute; left:"+Af[0]+"px; top:"+Af[1]+"px; z-index:"+CH;AE=document.body.insertBefore(AE,document.body.firstChild);AE.innerHTML=C;var A9=AE.offsetHeight+Af[1]-document.documentElement.offsetHeight;if(A9>0){AE.style.top=Af[1]-A9+"px";AE.style.left=Af[0]+3+"px";}AE.style.width=AE.childNodes[0].offsetWidth+"px";}},ArrangePopupPosition:function(){if(this.ArrPopupPos.length==2){var CJ=f_E("PWImagePopup"+this.ArrPopupPos[0]+"_div");var B3=f_E("PWImagePopup"+this.ArrPopupPos[1]+"_div");if(CJ.offsetWidth+B3.offsetWidth>document.documentElement.offsetWidth){CJ.style.left="5px";CJ.style.top="5px";B3.style.left=parseInt(document.documentElement.offsetWidth-B3.offsetWidth-5)+"px";B3.style.top=parseInt(document.documentElement.offsetHeight-B3.offsetHeight-5)+"px";}else{var FO=parseInt((document.documentElement.offsetWidth-CJ.offsetWidth-B3.offsetWidth)/3);CJ.style.left=FO+"px";B3.style.left=parseInt(2*FO+CJ.offsetWidth)+"px";}}},CreateFileBrowserDialogPopup:function(Aq,G9,B1){var C="";switch(Aq){case"Folder":{C="<div style=\"height:10px; clear:both\"></div>"+"<div class=\"FBD_TEXT1\" style=\"float:left;width:100px; height:37px; line-height:1.7;text-align:right\">Look in : &nbsp; </div>"+"<div id=\"RootDirectory_box\" style=\"float:left;width:300px; height:37px\"></div>"+"<div class=\"FBD_DIV5\" onclick=\"PopupWindow.UpFolder();\"></div>"+"<div id=\"DialogContent_box\" style=\"margin-left:auto; margin-right:auto; overflow:auto;width:480px; height:280px; border:1px solid #3C86EE; clear:both; background:#fff\"></div>"+"<div style=\"height:10px; clear:both\"></div>"+"<div style=\"height:30px\">"+"<div class=\"FBD_TEXT1\" style=\"float:left; width:100px; height:100%; text-align:right;line-height:1.5\">Folder name : &nbsp; </div>"+"<div style=\"float:left; width:300px; height:100%; line-height:1.5\">"+"<input id=\"BrowserValue_txt\" type=\"text\" style=\"border:1px solid #3C86EE; height:22px; width:100%\" />"+"</div>"+"<div style=\"float:right; width:74px; height:100%; text-align:left;line-height:1.5\">"+"<input id=\"Open_bt\" type=\"button\" value=\"Open\" style=\"width:60px\" onclick=\"f_E('"+G9+"').value = PopupWindow.Path + '/' + f_E('BrowserValue_txt').value; PopupWindow.RemovePopup(PopupWindow.ArrPopupPos[PopupWindow.ArrPopupPos.length - 1]);Combobox.dispose();\" />"+"</div>"+"</div>"+"<div style=\"height:30px\">"+"<div class=\"FBD_TEXT1\" style=\"float:left; width:100px; height:100%; text-align:right;line-height:1.5\">"+"Files of type : &nbsp; "+"</div>"+"<div id=\"FileType_box\" style=\"float:left; width:300px; height:100%; line-height:1.5\">"+"</div>"+"<div style=\"float:right; width:74px; height:100%; text-align:left;line-height:1.5\">"+"<input id=\"Cancel_bt\" type=\"button\" value=\"Cancel\" style=\"width:60px\" onclick=\"PopupWindow.RemovePopup(PopupWindow.ArrPopupPos[PopupWindow.ArrPopupPos.length - 1]); Combobox.dispose();\" />"+"</div>"+"</div>";this.CreateHTMLPopup("Folder Choose","FolderPopup",C,520,400,true,true,"1|0|1","Combobox.dispose();",false);this.init();Combobox.CreateComboboxStyle1("RootDirectory_box","RootDir_cb",300,0,"","Root...","Root...","");Combobox.CreateComboboxStyle1("FileType_box","FileType_cb",300,0,"","All files","All files","");this.Path=B1;this.RootPath=B1;f_PW_ShowContentDialog("Folder");break;}}},ClosePopupWindow:function(G){if(G!=null){while(G.id.indexOf("PWImagePopup")!=0){G=G.parentNode;}var O=G.id.substring(12,G.id.lastIndexOf("_div"));f_PW_RemovePopup(O);}},CloseContextMenu:function(G){if(G!=undefined){while(G.id.indexOf("ContextMenu")!=0){G=G.parentNode;}G.parentNode.removeChild(G);}},DoubleClickFolder:function(DJ){f_PW_DoubleClickFolder(DJ);},ClickFolder:function(G){f_PW_ClickFolder(G);},RootComboClick:function(AA,Cg){f_PW_RootComboClick(AA,Cg);},UpFolder:function(){f_PW_UpFolder();},FirstImage:function(AT,An,O,At,AK,AR,AB,AO){f_PW_FirstImage(AT,An,O,At,AK,AR,AB,AO);},PreImage:function(AT,An,O,At,AK,AR,AB,AO){f_PW_PreImage(AT,An,O,At,AK,AR,AB,AO);},NextImage:function(AT,An,O,At,AK,AR,AB,AO){f_PW_NextImage(AT,An,O,At,AK,AR,AB,AO);},LastImage:function(AT,An,O,At,AK,AR,AB,AO){f_PW_LastImage(AT,An,O,At,AK,AR,AB,AO);},RemovePopup:function(O){f_PW_RemovePopup(O);},RemoveContextMenu:function(Ab){f_PW_RemoveContextMenu(Ab);},MinimizeWindow:function(G,Ac){f_PW_MinimizeWindow(G,Ac);},MaximizeWindow:function(G){f_PW_MaximizeWindow(G);},CreateBlockElement:function(O){f_PW_CreateBlockElement(O);}};function f_PW_GetLocalFolderList(){var C="";var Be=new Array();var J=0;var I;var i;I=PopupWindow.Class.GetLocalFolderList(PopupWindow.Path).value;if(I){Be=I.split("|");J=Be.length;for(i=0;i<J;){C+="<div id=\"Content"+i+"_box\" class=\"FBD_DIV2\" onclick=\"PopupWindow.ClickFolder(this);\"  ondblclick=\"PopupWindow.DoubleClickFolder('"+Be[i]+"');\">"+"<div class=\"FBD_DIV3\"></div>"+"<div>"+Be[i]+"</div>"+"</div>";i++;}}return C;}function f_PW_ShowContentDialog(Aq){switch(Aq){case"Folder":{var AP=PopupWindow.Class.GetTreeRoot(PopupWindow.RootPath,PopupWindow.Path).value;var AI=AP;var As="";var AF=AP.split("|");var i;var J=AF.length;for(i=0;i<J;){As+="PopupWindow.RootComboClick('"+AF[i].substring(0,AF[i].lastIndexOf("/")+1)+"','../');|";i++;}AP=AP.replace(new RegExp("../","g"),"&nbsp;&nbsp;");Combobox.RenewDetailCombo("RootDir_cb","0","",AP,AI,As);var C=f_PW_GetLocalFolderList(PopupWindow.Path);if(C!=""){f_E("DialogContent_box").innerHTML=C;f_E("BrowserValue_txt").value="";return true;}else{var AU=PopupWindow.Path.lastIndexOf("/");if(AU!=PopupWindow.Path.length-1)PopupWindow.Path=PopupWindow.Path.substring(0,AU==2?(AU+1):AU);return false;}}}}function f_PW_DoubleClickFolder(DJ){if(PopupWindow.Path[PopupWindow.Path.length-1]!="/"){PopupWindow.Path=PopupWindow.Path+"/"+DJ;}else{PopupWindow.Path=PopupWindow.Path+DJ;}if(f_PW_ShowContentDialog("Folder")==true)PopupWindow.ItemSelectID=null;}function f_PW_ClickFolder(G){if(PopupWindow.ItemSelectID!=null){f_E(PopupWindow.ItemSelectID).childNodes[1].className="";}G.childNodes[1].className="FBD_DIV4";f_E("BrowserValue_txt").value=G.childNodes[1].innerHTML;PopupWindow.ItemSelectID=G.id;}function f_PW_RootComboClick(AA,Cg){var J=f_CountOccurrenceCharacter(AA,Cg);if(J>0){while(J>0){f_PW_CreatePreviousFolderPath();J--;}f_PW_ShowContentDialog("Folder");}}function f_PW_CreatePreviousFolderPath(){var AU=PopupWindow.Path.lastIndexOf("/");if(AU!=PopupWindow.Path.length-1)PopupWindow.Path=PopupWindow.Path.substring(0,AU==2?(AU+1):AU);}function f_PW_UpFolder(){var AU=PopupWindow.Path.lastIndexOf("/");if(AU!=PopupWindow.Path.length-1){if(PopupWindow.Path!=PopupWindow.RootPath){PopupWindow.Path=PopupWindow.Path.substring(0,AU==2?(AU+1):AU);f_PW_ShowContentDialog("Folder");}}}function f_PW_CheckPanelExist(){var J=PopupWindow.ArrPopupPos.length;var AJ=0;if(J==0)AJ=1;else{var V;var i=1;var j;while(AJ==0){V=false;for(j=0;j<J;){if(i==PopupWindow.ArrPopupPos[j]){V=true;break;}j++;}if(V==false){AJ=i;}i++;}}return AJ;}function f_PW_CheckPanelNameExist(AG){var V=false;if(AG!=null){var i;var Dk=PopupWindow.ArrPopupPos.length;for(i=0;i<Dk;){if(f_E("PWImagePopup"+PopupWindow.ArrPopupPos[i]+"_div").title==AG){V=true;break;}i++;}}return V;}function f_PW_CompareResolution(BI,Cj,Cl){Cj-=1;Cl-=1;var BC=BI.split("@");var He=parseInt(BC[Cj].substring(0,BC[Cj].indexOf("x")));var Ha=parseInt(BC[Cj].substring(BC[Cj].indexOf("x")+1));var Hd=parseInt(BC[Cl].substring(0,BC[Cl].indexOf("x")));var Hb=parseInt(BC[Cl].substring(BC[Cl].indexOf("x")+1));if(He==Hd&&Ha==Hb){return true;}return false;}function f_PW_FirstImage(AT,An,O,At,AK,AR,AB,AO){var G=f_E("PWImagePos"+O+"_lb");var AH=G.innerHTML.split("/");if(AH[0]=="1")return;AH[0]=parseInt(AH[0]);AH[1]=parseInt(AH[1]);if(f_PW_CompareResolution(An,AH[0],1)){var R=AT.split("@");var A2=f_E("PWPopupImage"+O+"_img");A2.src="";A2.src=R[0];}else{f_PW_DeleteArrItem(O);var AP=f_E("PWDrag"+O+"_Div").innerHTML;var Ay=f_E("PWImagePopup"+O+"_div").title;document.body.removeChild(f_E("PWImagePopup"+O+"_div"));PopupWindow.ReleaseDocumentFunctionCatch();PopupWindow.CreateImagePopup(AP,Ay,AT,An,0,At,AK,AR,AB,AO);PopupWindow.ArrangePopupPosition();}G.innerHTML=1+"/"+AH[1];}function f_PW_PreImage(AT,An,O,At,AK,AR,AB,AO){var G=f_E("PWImagePos"+O+"_lb");var AH=G.innerHTML.split("/");var Am=parseInt(AH[0]);if(Am>1){if(f_PW_CompareResolution(An,Am,Am-1)){var R=AT.split("@");var A2=f_E("PWPopupImage"+O+"_img");A2.src="";A2.src=R[Am-2];}else{f_PW_DeleteArrItem(O);var AP=f_E("PWDrag"+O+"_Div").innerHTML;var Ay=f_E("PWImagePopup"+O+"_div").title;document.body.removeChild(f_E("PWImagePopup"+O+"_div"));PopupWindow.ReleaseDocumentFunctionCatch();PopupWindow.CreateImagePopup(AP,Ay,AT,An,Am-2,At,AK,AR,AB,AO);PopupWindow.ArrangePopupPosition();}G.innerHTML=(Am-1)+"/"+AH[1];}}function f_PW_NextImage(AT,An,O,At,AK,AR,AB,AO){var G=f_E("PWImagePos"+O+"_lb");var AH=G.innerHTML.split("/");var Am=parseInt(AH[0]);if(Am<parseInt(AH[1])){if(f_PW_CompareResolution(An,Am,Am+1)){var R=AT.split("@");var A2=f_E("PWPopupImage"+O+"_img");A2.src="";A2.src=R[Am];}else{f_PW_DeleteArrItem(O);var AP=f_E("PWDrag"+O+"_Div").innerHTML;var Ay=f_E("PWImagePopup"+O+"_div").title;document.body.removeChild(f_E("PWImagePopup"+O+"_div"));PopupWindow.ReleaseDocumentFunctionCatch();PopupWindow.CreateImagePopup(AP,Ay,AT,An,Am,At,AK,AR,AB,AO);PopupWindow.ArrangePopupPosition();}G.innerHTML=(Am+1)+"/"+AH[1];}}function f_PW_LastImage(AT,An,O,At,AK,AR,AB,AO){var G=f_E("PWImagePos"+O+"_lb");var AH=G.innerHTML.split("/");if(AH[0]==AH[1])return;AH[0]=parseInt(AH[0]);AH[1]=parseInt(AH[1]);if(f_PW_CompareResolution(An,AH[0],AH[1])){var R=AT.split("@");var A2=f_E("PWPopupImage"+O+"_img");A2.src="";A2.src=R[AH[1]-1];}else{f_PW_DeleteArrItem(O);var AP=f_E("PWDrag"+O+"_Div").innerHTML;var Ay=f_E("PWImagePopup"+O+"_div").title;document.body.removeChild(f_E("PWImagePopup"+O+"_div"));PopupWindow.ReleaseDocumentFunctionCatch();PopupWindow.CreateImagePopup(AP,Ay,AT,An,AH[1]-1,At,AK,AR,AB,AO);PopupWindow.ArrangePopupPosition();}G.innerHTML=AH[1]+"/"+AH[1];}function f_PW_RemovePopup(O){PopupWindow.PanelLock=PopupWindow.PanelLock.replace("|"+O+"|","");var HZ="PWImagePopup"+O+"_div";var DG="PWOverLayer_div";var Dx=f_E(HZ);try{var Bw=new OpacityTween(Dx,Tween.strongEaseIn,100,0,0.6);Bw.start();Bw.onMotionFinished=function(){document.body.removeChild(Dx);f_PW_DeleteArrItem(O);if(f_E(DG)!=undefined&&PopupWindow.PanelLock==""){document.body.removeChild(f_E(DG));PopupWindow.dispose();}}}catch(e){document.body.removeChild(Dx);f_PW_DeleteArrItem(O);if(f_E(DG)!=undefined&&PopupWindow.PanelLock==""){document.body.removeChild(f_E(DG));PopupWindow.dispose();}}}function f_PW_DeleteArrItem(I){var i;var J=PopupWindow.ArrPopupPos.length;for(i=0;i<J;){if(I==PopupWindow.ArrPopupPos[i]){PopupWindow.ArrPopupPos.splice(i,1);return;}i++;}}function f_PW_MapPath(BH){return window.location.protocol+"//"+window.location.host+"/"+window.location.pathname.split("/")[1]+"/"+BH;}function f_PW_CheckMousePointInContextMenu(event){var i;var Aj="";for(i=1;i<4;){Aj="ContextMenu"+i+"_div";if(f_E(Aj)){if(f_PW_CheckMousePointInObject(event,f_E(Aj))==true)return true;}i++;}return false;}function f_PW_CheckMousePointInObject(event,G){var Al,B$,Ac,CA;Al=G.offsetLeft;B$=G.offsetLeft+G.offsetWidth;Ac=G.offsetTop;CA=G.offsetTop+G.offsetHeight;if(event.clientX>=Al&&event.clientX<=B$&&event.clientY>=Ac&&event.clientY<=CA)return true;return false;}function f_PW_RemoveContextMenu(Ab){var i=Ab;for(i;;){if(f_RemoveNode("ContextMenu"+i+"_div")==false){return;}else{f_RemoveNode("BlockPage_layer");f_RemoveNode("BlockPage_layerBottomBorder");}i++;}}function f_PW_GetMouseOffset(Ad,event){event=event||window.event;var Cd=f_GetPosition(Ad);var Af=f_GetMouseCoords(event);return new Array(Af[0]-Cd[0],Af[1]-Cd[1]);}function f_PW_MouseMove(event){if(PopupWindow.DragObject){event=event||window.event;var Af=f_GetMouseCoords(event);var B4=Af[0]-PopupWindow.MouseOffset[0];var CP=Af[1]-PopupWindow.MouseOffset[1];PopupWindow.DragObject.style.top=CP+"px";PopupWindow.DragObject.style.left=B4+"px";var Fm=document.documentElement.offsetWidth+document.documentElement.scrollLeft-PopupWindow.DragObject.offsetWidth;var FY=document.documentElement.offsetHeight+document.documentElement.scrollTop-PopupWindow.DragObject.offsetHeight;if(PopupWindow.IsWrap==true){if(B4<0)PopupWindow.DragObject.style.left="0px";else if(B4>Fm)PopupWindow.DragObject.style.left=Fm+"px";if(CP<0)PopupWindow.DragObject.style.top="0px";else if(CP>FY){PopupWindow.DragObject.style.top=FY+"px";}}}return false;}function f_PW_MouseUp(){PopupWindow.DragObject=null;return false;}function f_PW_MakeDraggable(Ak,DE,At){var G=f_E(Ak);if(!G)return;G.onmousedown=function(event){PopupWindow.IsWrap=At;PopupWindow.DragObject=f_E(DE);PopupWindow.MouseOffset=f_PW_GetMouseOffset(PopupWindow.DragObject,event);if(Ak==DE){if(this.style.zIndex!=PopupWindow.MaxzIndex){PopupWindow.MaxzIndex=PopupWindow.MaxzIndex+1;}this.style.zIndex=PopupWindow.MaxzIndex;}return false;};if(Ak!=DE){f_E(DE).onmousedown=function(){if(PopupWindow.ArrPopupPos.length>1){if(this.style.zIndex!=PopupWindow.MaxzIndex){PopupWindow.MaxzIndex=PopupWindow.MaxzIndex+1;}this.style.zIndex=PopupWindow.MaxzIndex;}};}}function f_PW_MinimizeWindow(G,Ac){while(G.id.indexOf("PWImagePopup")!=0){G=G.parentNode;}if(G.offsetWidth!=220&&(G.offsetWidth!=document.documentElement.offsetWidth||G.offsetHeight!=(document.documentElement.offsetHeight+5))){PopupWindow.PopupPosition=G.offsetLeft+"|"+G.offsetTop+"|"+G.offsetWidth+"|"+G.offsetHeight;}G.childNodes[3].style.display="none";G.style.width="220px";G.childNodes[1].style.width="196px";G.childNodes[1].childNodes[0].style.width="105px";G.childNodes[5].style.width="196px";G.childNodes[1].childNodes[0].onclick=function(){f_PW_MaximizeWindow(G);return false;};var Du=new Tween(G.style,"top",Tween.strongEaseOut,G.offsetTop,Ac,0.3,"px");Du.start();var Dt=new Tween(G.style,"left",Tween.strongEaseOut,G.offsetLeft,0,0.3,"px");Dt.start();}function f_PW_MaximizeWindow(G){while(G.id.indexOf("PWImagePopup")!=0){G=G.parentNode;}var Fa=document.body.offsetWidth;var Hh=document.body.offsetHeight;if(Fa==G.offsetWidth||G.offsetWidth==220){if(G.offsetWidth==220){f_AddEvent(G.childNodes[1].childNodes[0],"click",function(){},true);}var DF=PopupWindow.PopupPosition.split("|");f_PW_ResizeWindow(G,parseInt(DF[0]),parseInt(DF[1]),parseInt(DF[2]),parseInt(DF[3]));}else{if(G.offsetWidth!=220)PopupWindow.PopupPosition=G.offsetLeft+"|"+G.offsetTop+"|"+G.offsetWidth+"|"+G.offsetHeight;f_PW_ResizeWindow(G,0,0,Fa,Hh);}}function f_PW_ResizeWindow(G,Al,Ac,AC,Ap){var Du=new Tween(G.style,"top",Tween.strongEaseOut,G.offsetTop,Ac,0.3,"px");Du.start();var Dt=new Tween(G.style,"left",Tween.strongEaseOut,G.offsetLeft,Al,0.3,"px");Dt.start();var FX=new Tween(G.style,"width",Tween.strongEaseOut,G.offsetWidth,AC,0.3,"px");FX.start();FX.onMotionFinished=function(){G.childNodes[1].style.width=(AC-24)+"px";G.childNodes[1].childNodes[0].style.width=(AC-115)+"px";G.childNodes[5].style.width=(AC-24)+"px";G.childNodes[3].style.width=AC+"px";G.childNodes[3].childNodes[0].style.height=(Ap-79)+"px";G.childNodes[3].childNodes[0].style.width=(AC-10)+"px";G.childNodes[3].childNodes[1].style.width=(AC-10)+"px";G.childNodes[3].style.display="";};}function f_PW_CreateBlockElement(O){PopupWindow.PanelLock+="|"+O+"|";if(f_E("PWOverLayer_div")==undefined){var d=document;var AS=f_E("PWBottomBorder_div");if(AS==undefined){AS=d.createElement("div");AS.id="PWBottomBorder_div";AS.className="PW_Div16";AS=d.body.appendChild(AS);}var b=d.createElement("div");b.id="PWOverLayer_div";b.className="PW_Div13";b.style.cssText="z-index:"+this.MaxzIndex;b=d.body.appendChild(b);b.style.height=AS.offsetTop+"px";}}
