12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967196819691970197119721973197419751976197719781979198019811982198319841985198619871988198919901991199219931994199519961997199819992000200120022003200420052006200720082009201020112012201320142015201620172018201920202021202220232024202520262027202820292030203120322033203420352036203720382039204020412042204320442045204620472048204920502051205220532054205520562057205820592060206120622063206420652066206720682069207020712072207320742075207620772078207920802081208220832084208520862087208820892090209120922093209420952096209720982099210021012102210321042105210621072108210921102111211221132114211521162117211821192120212121222123212421252126212721282129213021312132213321342135213621372138213921402141214221432144214521462147214821492150215121522153215421552156215721582159216021612162216321642165216621672168216921702171217221732174217521762177217821792180218121822183218421852186218721882189219021912192219321942195219621972198219922002201220222032204220522062207220822092210221122122213221422152216221722182219222022212222222322242225222622272228222922302231223222332234223522362237223822392240224122422243224422452246224722482249225022512252225322542255225622572258225922602261226222632264226522662267226822692270227122722273227422752276227722782279228022812282228322842285228622872288228922902291229222932294229522962297229822992300230123022303230423052306230723082309231023112312231323142315231623172318231923202321232223232324232523262327232823292330233123322333233423352336233723382339234023412342234323442345234623472348234923502351235223532354235523562357235823592360236123622363236423652366236723682369237023712372237323742375237623772378237923802381238223832384238523862387238823892390239123922393239423952396239723982399240024012402240324042405240624072408240924102411241224132414241524162417241824192420242124222423242424252426242724282429243024312432243324342435243624372438243924402441244224432444244524462447244824492450245124522453245424552456245724582459246024612462246324642465246624672468246924702471247224732474247524762477247824792480248124822483248424852486248724882489249024912492249324942495249624972498249925002501250225032504250525062507250825092510251125122513251425152516251725182519252025212522252325242525252625272528252925302531253225332534253525362537253825392540254125422543254425452546254725482549255025512552255325542555255625572558255925602561256225632564256525662567256825692570257125722573257425752576257725782579258025812582258325842585258625872588258925902591259225932594259525962597259825992600260126022603260426052606260726082609261026112612261326142615261626172618261926202621262226232624262526262627262826292630263126322633263426352636263726382639264026412642264326442645264626472648264926502651265226532654265526562657265826592660266126622663266426652666266726682669267026712672267326742675267626772678267926802681268226832684268526862687268826892690269126922693269426952696269726982699270027012702270327042705270627072708270927102711271227132714271527162717271827192720272127222723272427252726272727282729273027312732273327342735273627372738273927402741274227432744274527462747274827492750275127522753275427552756275727582759276027612762276327642765276627672768276927702771277227732774277527762777277827792780278127822783278427852786278727882789279027912792279327942795279627972798279928002801280228032804280528062807280828092810281128122813281428152816281728182819282028212822282328242825282628272828282928302831283228332834283528362837283828392840284128422843284428452846284728482849285028512852285328542855285628572858285928602861286228632864286528662867286828692870287128722873287428752876287728782879288028812882288328842885288628872888288928902891289228932894289528962897289828992900290129022903290429052906290729082909291029112912291329142915291629172918291929202921292229232924292529262927292829292930293129322933293429352936293729382939294029412942294329442945294629472948294929502951295229532954295529562957295829592960296129622963296429652966296729682969297029712972297329742975297629772978297929802981298229832984298529862987298829892990299129922993299429952996299729982999300030013002300330043005300630073008300930103011301230133014301530163017301830193020302130223023302430253026302730283029303030313032303330343035303630373038303930403041304230433044304530463047304830493050305130523053305430553056305730583059306030613062306330643065306630673068306930703071307230733074307530763077307830793080308130823083308430853086308730883089309030913092309330943095309630973098309931003101310231033104310531063107310831093110311131123113311431153116311731183119312031213122312331243125312631273128312931303131313231333134313531363137313831393140314131423143314431453146314731483149315031513152315331543155315631573158315931603161316231633164316531663167316831693170317131723173 |
- /*
- *+------------------------------------------------------------------------+
- *| Licensed Materials - Property of IBM
- *|
- *| IBM Cognos Products: PS
- *|
- *| (C) Copyright IBM Corp. 2011
- *|
- *| US Government Users Restricted Rights - Use, duplication or
- *| disclosure restricted by GSA ADP Schedule Contract with IBM Corp.
- *|
- *+------------------------------------------------------------------------+
- */
- var G_HAL={};
- G_HAL.M_oLibraries={hal:{name:"hal",path:"",appImagePath:"images/",imagePath:"",isApplication:true,iframeUnderlay:false,enableRoundButtons:false,enableDialogChrome:false,enableDialogShowAnimation:false,enableDialogMoveAnimation:false,enableDialogResizeAnimation:false,menuAnimation:false,enableComboBoxAnimation:false,enableComboBoxFrameBorder:false,enableWigetFrameBorder:false,enableMenuPopupFrameBorder:false,transferDialogFrameborderClass:"",transferPopupDialogFrameborderClass:"",dialogFrameBorderWidthBuffer:0,dialogFrameBorderHeightBuffer:0,menuPopupFrameBorderWidthBuffer:0,menuPopupFrameBorderHeightBuffer:0,transferMenuFrameborderClass:"",comboBoxFrameBorderWidthBuffer:0,comboBoxFrameBorderHeightBuffer:0,useExponentialEasing:false,animationDurationMultiplier:1,enablePaneAnimation:false,disableMSThemesOverride:false,enableHighContrastMode:false,enableAccessibility:false,defaultGuiDirection:"",fireDOMContentLoaded:false,enableFastClick:false,enablePointerSupport:false}};
- if(window["G_HALOptions"]){
- var v_oOptions=G_HAL.M_oLibraries["hal"];
- for(var s in G_HALOptions){
- v_oOptions[s]=G_HALOptions[s];
- }
- }
- G_HAL.F_AddLibrary=function(_1,_2){
- this.M_oLibraries[_1]=_2;
- };
- G_HAL.M_oBuiltInDialogs={D_MsgBox:true,D_InputBox:true,D_XmlError:true,D_Progress:true,D_PropertySheetListView:true};
- G_HAL.m_oLoaded={};
- G_HAL.M_sPath=G_HAL.M_oLibraries["hal"]["path"];
- G_HAL.M_sAppImagePath=G_HAL.M_oLibraries["hal"]["appImagePath"];
- G_HAL.M_sImagePath=G_HAL.M_oLibraries["hal"]["imagePath"]||(G_HAL.M_sPath+"hal/images/");
- G_HAL.F_GetImageURL=function(_3){
- if(this.f_isNonResolvableFilePath(_3)){
- return _3;
- }
- var _4=this.f_getLibraryNameFromSrc(_3);
- if(_4&&this.M_oLibraries[_4]["imagePath"]){
- _3=_3.replace(_4+"/images/",this.M_oLibraries[_4]["imagePath"]);
- }
- _3=U_HighContrast.F_GetHighContrastImgIfNecessary(_3);
- return (_4?(this.M_oLibraries[_4]["path"]+_3):(this.M_sAppImagePath+_3));
- };
- G_HAL.F_GetFileURL=function(_5){
- if(this.f_isNonResolvableFilePath(_5)){
- return _5;
- }
- var _6=this.f_getLibraryNameFromSrc(_5);
- return (_6?(this.M_oLibraries[_6]["path"]+_5):_5);
- };
- G_HAL.f_isNonResolvableFilePath=function(_7){
- switch(_7.charAt(0)){
- case "h":
- case "H":
- var s=_7.toLowerCase();
- if((s.substr(0,7)=="http://")||(s.substr(0,8)=="https://")){
- return true;
- }
- break;
- case "u":
- case "U":
- var s=_7.toLowerCase();
- if(s.substr(0,8)=="unmht://"){
- return true;
- }
- break;
- case "/":
- case ".":
- return true;
- }
- return false;
- };
- G_HAL.f_getLibraryNameFromSrc=function(_8){
- var i=_8.indexOf("/");
- if(i!=-1){
- var _9=_8.substr(0,i);
- if(_9&&this.M_oLibraries[_9]){
- return _9;
- }
- }
- return "";
- };
- G_HAL.f_getFileSrc=function(_a){
- var _b=this.f_getLibraryNameFromSrc(_a);
- return (_b?(this.M_oLibraries[_b]["path"]+_a):_a);
- };
- G_HAL.F_FileHasBeenLoaded=function(_c){
- _c=this.f_getFileSrc(_c);
- return Boolean(this.m_oLoaded[_c]);
- };
- G_HAL.F_AddFileToLoadedList=function(_d){
- _d=this.f_getFileSrc(_d);
- this.m_oLoaded[_d]=true;
- };
- G_HAL.F_RemoveFileFromLoadedList=function(_e){
- _e=this.f_getFileSrc(_e);
- delete this.m_oLoaded[_e];
- };
- G_HAL.F_RemoveFilesFromLoadedList=function(_f){
- if(_f){
- var _10=_f.length;
- for(var i=0;i<_10;i++){
- this.F_RemoveFileFromLoadedList(_f[i]);
- }
- }
- };
- G_HAL.F_GetFilesNotLoaded=function(_11){
- var _12=[];
- for(var i=0;i<_11.length;i++){
- if(!this.F_FileHasBeenLoaded(_11[i])){
- _12.F_PushUnique(_11[i]);
- }
- }
- return _12;
- };
- G_HAL.F_AlertError=function(s){
- alert("HAL ERROR:\r\n\r\n"+s);
- };
- G_HAL.F_OnDomContentLoaded=function(e){
- e=e||window.event;
- if(G_BrowserInfo.M_bIsIE6){
- document.body.className+=" clsHalNoPngAlpha";
- }
- if(window["G_DragDrop"]||window["C_Dialog"]||window["C_PropertySheet"]||window["C_ModelessDialog"]){
- var d=document;
- d.body.appendChild(d.createElement("DIV")).innerHTML=G_HAL.F_GetHtmlToWrite();
- }
- if(window["U_CoolButton"]){
- U_CoolButton.F_InitCoolButtons(document);
- }
- if(window["F_HAL_OnDomContentLoaded"]){
- F_HAL_OnDomContentLoaded(e);
- }else{
- var _13=window["G_App"];
- if(_13&&_13["F_HAL_OnDomContentLoaded"]){
- _13.F_HAL_OnDomContentLoaded(e);
- }
- }
- };
- G_HAL.F_OnLoad=function(e){
- e=e||window.event;
- if(!G_HAL.M_oLibraries["hal"]["fireDOMContentLoaded"]){
- G_HAL.F_OnDomContentLoaded(e);
- }
- if(window["F_HAL_OnLoad"]){
- F_HAL_OnLoad(e);
- }else{
- var _14=window["G_App"];
- if(_14&&_14["F_HAL_OnLoad"]){
- _14.F_HAL_OnLoad(e);
- }
- }
- if(window.onresize){
- G_HAL.f_originalWindowOnResize=window.onresize;
- }
- window.onresize=G_HAL.F_OnResize;
- if(G_BrowserInfo.M_bIsTouchDevice){
- if(window.onorientationchange){
- G_HAL.f_originalOrientationChange=window.onorientationchange;
- }
- window.onorientationchange=G_HAL.F_OnOrientationChange;
- }
- if(G_HAL.f_originalWindowOnLoad){
- G_HAL.f_originalWindowOnLoad(e);
- }
- };
- G_HAL.F_OnUnLoad=function(e){
- e=e||window.event;
- U_DOM.F_DisplayTDs(document);
- var _15=window["G_App"];
- if(window["F_HAL_OnUnLoad"]){
- F_HAL_OnUnLoad(e);
- }else{
- var _15=window["G_App"];
- if(_15&&_15["F_HAL_OnUnLoad"]){
- _15.F_HAL_OnUnLoad(e);
- }
- }
- if(window["C_WebRequest"]){
- C_WebRequest.F_AbortActiveRequests();
- }
- G_Debug.F_CloseConsole();
- G_HAL.f_detach();
- if(G_HAL.f_originalWindowOnUnLoad){
- G_HAL.f_originalWindowOnUnLoad(e);
- }
- G_HAL.f_originalWindowOnResize=null;
- G_HAL.f_originalWindowOnLoad=null;
- G_HAL.f_originalWindowOnUnLoad=null;
- };
- G_HAL.f_detach=function(){
- if(window["C_Dialog"]){
- C_Dialog.F_Detach();
- }
- if(window["C_ModelessDialog"]){
- C_ModelessDialog.F_Detach();
- }
- if(window["C_ComboBox"]){
- C_ComboBox.F_Detach();
- }
- };
- G_HAL.F_OnResize=function(e){
- e=e||window.event;
- var _16=document.body.clientWidth;
- var _17=document.body.clientHeight;
- if((_16==G_HAL.m_iClientWidth)&&(_17==G_HAL.m_iClientHeight)){
- return;
- }
- G_HAL.m_iClientWidth=_16;
- G_HAL.m_iClientHeight=_17;
- if(window["U_Dialog"]){
- U_Dialog.F_KeepDialogsVisible();
- }
- var _18=window["G_App"];
- if(window["F_HAL_OnResize"]){
- F_HAL_OnResize(e);
- }else{
- var _18=window["G_App"];
- if(_18&&_18["F_HAL_OnResize"]){
- _18.F_HAL_OnResize(e);
- }
- }
- if(G_HAL.f_originalWindowOnResize){
- G_HAL.f_originalWindowOnResize(e);
- }
- };
- G_HAL.F_OnOrientationChange=function(e){
- e=e||window.event;
- var _19=window["G_App"];
- if(window["F_HAL_OnOrientationChange"]){
- F_HAL_OnOrientationChange(e);
- }else{
- var _19=window["G_App"];
- if(_19&&_19["F_HAL_OnOrientationChange"]){
- _19.F_HAL_OnOrientationChange(e);
- }
- }
- if(G_HAL.f_originalOrientationChange){
- G_HAL.f_originalOrientationChange(e);
- }
- };
- if(!G_HAL.M_oLibraries["hal"]["fireDOMContentLoaded"]){
- }else{
- if((navigator.product=="Gecko")||(navigator.userAgent.toLowerCase().indexOf("webkit")!=-1)){
- document.addEventListener("DOMContentLoaded",function(){
- document.removeEventListener("DOMContentLoaded",arguments.callee,false);
- G_HAL.F_OnDomContentLoaded();
- },false);
- }else{
- document.attachEvent("onreadystatechange",function(){
- if(document.readyState==="complete"){
- document.detachEvent("onreadystatechange",arguments.callee);
- G_HAL.F_OnDomContentLoaded();
- }
- });
- }
- }
- if(window.onload){
- G_HAL.f_originalWindowOnLoad=window.onload;
- }
- window.onload=G_HAL.F_OnLoad;
- if(window.onunload){
- G_HAL.f_originalWindowOnUnLoad=window.onunload;
- }
- window.onunload=G_HAL.F_OnUnLoad;
- G_HAL.F_VerifyDependencies=function(){
- return;
- };
- G_HAL.F_GetHtmlToWrite=function(){
- var a=[];
- if(window["G_DragDrop"]){
- a.push(G_DragDrop.F_GetCursorsHtml());
- if(window["C_TreeView"]){
- a.push(C_TreeView.F_GetCaretsHtml());
- }
- if(window["C_OrgTreeView"]){
- a.push(C_OrgTreeView.F_GetCaretsHtml());
- }
- if(window["C_ListView"]){
- a.push(C_ListView.F_GetCaretsHtml());
- }
- }
- if(window["C_ModelessDialog"]){
- a.push(C_ModelessDialog.F_GetModelessDialogTemplateHtml());
- }
- if(window["C_Dialog"]){
- a.push(C_Dialog.F_GetModalDialogTemplateHtml());
- for(var s in this.M_oBuiltInDialogs){
- if((s=="D_PropertySheetListView")&&!window["C_PropertySheet"]){
- continue;
- }
- var _1a=window[s];
- if(_1a){
- a.push(_1a.F_GetDialogHtml());
- }
- }
- }
- return a.join("");
- };
- G_HAL.F_GetWidgetFrameBorderHtml=function(_1b){
- if(!this.m_oWidgetFrameBorderHtmlStream){
- var os=new C_StringStream();
- os.F_Write("<div class=\"");
- os.F_CreatePlaceHolder();
- os.F_Write("\" style=\"width:100%; height:100%\">");
- os.F_Write("<table role=\"presentation\" class=\"");
- os.F_CreatePlaceHolder();
- os.F_Write("\" cellpadding=\"0\" cellspacing=\"0\" style=\"height:100%; width:100%; border-collapse:collapse;\">");
- os.F_Write("<tr class=\"clsScale25_t\">");
- os.F_Write("<td class=\"clsScale25_t_l\"><img class=\"clsScale25_t_l_spacer\" alt=\"\" src=\"");
- os.F_Write(G_HAL.M_sImagePath);
- os.F_Write("blank.gif\"/></td>");
- os.F_Write("<td class=\"clsScale25_t_li\"></td>");
- os.F_Write("<td class=\"clsScale25_t_m\"></td>");
- os.F_Write("<td class=\"clsScale25_t_ri\"></td>");
- os.F_Write("<td class=\"clsScale25_t_r\"></td>");
- os.F_Write("</tr>");
- os.F_Write("<tr class=\"clsScale25_ti\">");
- os.F_Write("<td class=\"clsScale25_ti_l\"></td>");
- os.F_Write("<td class=\"clsScale25_ti_li\"><img class=\"clsScale25_ti_li_spacer\" alt=\"\" src=\"");
- os.F_Write(G_HAL.M_sImagePath);
- os.F_Write("blank.gif\"/></td>");
- os.F_Write("<td class=\"clsScale25_ti_m\"></td>");
- os.F_Write("<td class=\"clsScale25_ti_ri\"></td>");
- os.F_Write("<td class=\"clsScale25_ti_r\"></td>");
- os.F_Write("</tr>");
- os.F_Write("<tr class=\"clsScale25_m\">");
- os.F_Write("<td class=\"clsScale25_m_l\"></td>");
- os.F_Write("<td class=\"clsScale25_m_li\">");
- os.F_Write("<div class=\"clsScale25_m_li_inner\"></div>");
- os.F_Write("</td>");
- os.F_Write("<td class=\"clsScale25_m_m\">");
- os.F_Write("<div class=\"clsScale25_m_m_inner\"></div>");
- os.F_Write("</td>");
- os.F_Write("<td class=\"clsScale25_m_ri\">");
- os.F_Write("<div class=\"clsScale25_m_ri_inner\"></div>");
- os.F_Write("</td>");
- os.F_Write("<td class=\"clsScale25_m_r\"></td>");
- os.F_Write("</tr>");
- os.F_Write("<tr class=\"clsScale25_bi\">");
- os.F_Write("<td class=\"clsScale25_bi_l\"></td>");
- os.F_Write("<td class=\"clsScale25_bi_li\"></td>");
- os.F_Write("<td class=\"clsScale25_bi_m\"></td>");
- os.F_Write("<td class=\"clsScale25_bi_ri\"><img class=\"clsScale25_bi_ri_spacer\" alt=\"\" src=\"");
- os.F_Write(G_HAL.M_sImagePath);
- os.F_Write("blank.gif\"/></td>");
- os.F_Write("<td class=\"clsScale25_bi_r\"></td>");
- os.F_Write("</tr>");
- os.F_Write("<tr class=\"clsScale25_b\">");
- os.F_Write("<td class=\"clsScale25_b_l\"></td>");
- os.F_Write("<td class=\"clsScale25_b_li\"></td>");
- os.F_Write("<td class=\"clsScale25_b_m\"></td>");
- os.F_Write("<td class=\"clsScale25_b_ri\"></td>");
- os.F_Write("<td class=\"clsScale25_b_r\"><img class=\"clsScale25_b_r_spacer\" alt=\"\" src=\"");
- os.F_Write(G_HAL.M_sImagePath);
- os.F_Write("blank.gif\"/></td>");
- os.F_Write("</tr>");
- os.F_Write("</table>");
- os.F_Write("</div>");
- this.m_oWidgetFrameBorderHtmlStream=os;
- }
- this.m_oWidgetFrameBorderHtmlStream.F_WriteToPlaceHolder(1,_1b);
- this.m_oWidgetFrameBorderHtmlStream.F_WriteToPlaceHolder(2,_1b);
- return this.m_oWidgetFrameBorderHtmlStream.F_ToString();
- };
- G_HAL.F_UpdateWidgetFrameBorderClass=function(_1c,_1d){
- if(_1c.className!=_1d){
- _1c.className=_1d;
- }
- var tbl=_1c.firstChild;
- if(tbl.className!=_1d){
- tbl.className=_1d;
- }
- };
- G_HAL.F_EnableHighContrastMode=function(){
- this.M_oLibraries["hal"]["enableHighContrastMode"]=true;
- (new C_ClassList(document.body)).F_Add("clsHighContrast");
- var _1e=document.getElementsByTagName("IMG");
- for(var i=0;i<_1e.length;i++){
- _1e[i].src=U_HighContrast.F_GetHighContrastImgIfNecessary(_1e[i].getAttribute("src"));
- }
- };
- G_HAL.F_EnableAccessibility=function(_1f,_20){
- this.M_oLibraries["hal"]["enableAccessibility"]=_1f;
- if(!_1f&&!G_BrowserInfo.M_bIsIE&&!_20){
- var _21=U_DOM.F_GetStyleSheet("idHalBrowserStyles");
- if(_21){
- _21.addRule("*:focus","outline:none");
- }
- }
- };
- G_HAL.F_EnableAllAnimation=function(_22){
- G_HAL.M_oLibraries["hal"]["enableDialogShowAnimation"]=_22;
- G_HAL.M_oLibraries["hal"]["enableDialogMoveAnimation"]=_22;
- G_HAL.M_oLibraries["hal"]["enableDialogResizeAnimation"]=_22;
- G_HAL.M_oLibraries["hal"]["menuAnimation"]=_22;
- G_HAL.M_oLibraries["hal"]["enableComboBoxAnimation"]=_22;
- G_HAL.M_oLibraries["hal"]["enablePaneAnimation"]=_22;
- };
- G_HAL.F_SetTestListener=function(_23){
- G_HAL.M_oTestListener=_23;
- };
- G_HAL.F_RemoveTestListener=function(){
- delete G_HAL.M_oTestListener;
- };
- var G_BrowserInfo={};
- G_BrowserInfo.M_bIsGecko=false;
- G_BrowserInfo.M_bIsFirefox=false;
- G_BrowserInfo.M_bIsIE=false;
- G_BrowserInfo.M_bIsWebKit=false;
- G_BrowserInfo.M_bIsSupported=false;
- G_BrowserInfo.M_bIsSupportedIE=false;
- G_BrowserInfo.M_bIsSupportedFirefox=false;
- G_BrowserInfo.f_init=function(){
- var _24=navigator.userAgent.toLowerCase();
- this.M_bIsIPhone=_24.indexOf("iphone")!=-1;
- this.M_bIsIPod=_24.indexOf("ipod")!=-1;
- this.M_bIsIPad=_24.indexOf("ipad")!=-1;
- this.M_bIsIOS=this.M_bIsIPhone||this.M_bIsIPod||this.M_bIsIPad;
- this.M_bIsAndroid=_24.indexOf("android")!=-1;
- this.M_bIsWebKit=_24.indexOf("webkit")!=-1;
- this.M_bIsChrome=_24.indexOf("chrome")!=-1;
- this.M_bIsAndroidBrowser=this.M_bIsAndroid&&!this.M_bIsChrome;
- this.M_bIsGecko=!this.M_bIsWebKit&&(navigator.product=="Gecko");
- this.M_bIsPointerEnabled=G_HAL.M_oLibraries["hal"]["enablePointerSupport"]&&navigator.msPointerEnabled;
- this.M_bIsTouchDevice=this.M_bIsIOS||this.M_bIsAndroid||(navigator.msMaxTouchPoints>1);
- this.M_bIsFirefox=(_24.match(/firefox|minefield|shiretoko|namoroka/)!=null);
- var _25=0;
- if(_24.search(/(?:firefox|minefield|shiretoko|namoroka)\/([0-9]+\.[0-9]+)/)!=-1){
- _25=parseFloat(RegExp.$1);
- }
- this.M_bIsSupportedFirefox=(this.M_bIsFirefox&&(_25>=1.5));
- this.M_bFirefox3OrLater=(this.M_bIsFirefox&&(_25>=3));
- this.M_bFirefox4OrLater=(this.M_bIsFirefox&&(_25>=4));
- this.M_bFirefox13OrLater=(this.M_bIsFirefox&&(_25>=13));
- this.M_bFirefox35OrLater=(this.M_bIsFirefox&&(_25>=3.5));
- this.M_bIsIE=((_24.indexOf("msie")!=-1)&&(_24.indexOf("opera")==-1));
- var _26=0;
- if(_24.search(/msie\s+([0-9]+\.[0-9]+)/)!=-1){
- _26=RegExp.$1;
- }
- var _27=parseInt(navigator.appVersion);
- var _28=(_24.search(/trident\/([0-9]+\.[0-9]+)/)!=-1)?parseFloat(RegExp.$1):NaN;
- this.M_bIsIE6=(this.M_bIsIE&&(_26>=6)&&(_26<7));
- this.M_bIE8OrLater=(this.M_bIsIE&&((_26>=8)||(!isNaN(_28)&&(_28>=4))));
- this.M_bIE9OrLater=(this.M_bIE8OrLater&&(!isNaN(_28)&&(_28>=5)));
- this.M_bIE10OrLater=(this.M_bIE9OrLater&&(!isNaN(_28)&&(_28>=6)));
- this.M_bIsSupportedIE=(this.M_bIsIE&&_26>=6);
- this.M_bIsHtml5QuirksMode=(this.M_bIE10OrLater&&(document.documentMode==10)&&(document.compatMode=="BackCompat"));
- this.M_bIsIE5QuirksMode=(this.M_bIsIE&&!this.M_bIsHtml5QuirksMode);
- var _29=0;
- if(_24.match(/chrome/)!=null&&_24.search(/chrome\/([0-9]+\.[0-9]+)/)!=-1){
- _29=RegExp.$1;
- }
- var _2a=0;
- if(_24.match(/safari/)!=null&&_24.search(/version\/([0-9]+\.[0-9]+)/)!=-1){
- _2a=RegExp.$1;
- }
- this.M_bIsChrome21OrLater=(_29>=21);
- this.M_bIsSafari5OrLater=(_2a>=5);
- this.M_bIsSupported=(this.M_bIsSupportedIE||this.M_bIsSupportedFirefox||this.M_bIsChrome21OrLater||this.M_bIsSafari5OrLater);
- };
- G_BrowserInfo.f_init();
- var U_DOM={};
- U_DOM.K_iKeyBackSpace=8;
- U_DOM.K_iKeyTab=9;
- U_DOM.K_iKeyEnter=13;
- U_DOM.K_iKeyEscape=27;
- U_DOM.K_iKeySpace=32;
- U_DOM.K_iKeyPgUp=33;
- U_DOM.K_iKeyPgDn=34;
- U_DOM.K_iKeyEnd=35;
- U_DOM.K_iKeyHome=36;
- U_DOM.K_iKeyArrowLeft=37;
- U_DOM.K_iKeyArrowUp=38;
- U_DOM.K_iKeyArrowRight=39;
- U_DOM.K_iKeyArrowDown=40;
- U_DOM.K_iKeyInsert=45;
- U_DOM.K_iKeyDelete=46;
- U_DOM.K_iKeyA=65;
- U_DOM.K_iKeyF5=116;
- U_DOM.K_iKeyF1=112;
- U_DOM.K_iKeyF10=121;
- U_DOM.K_iKeyPlus=107;
- U_DOM.K_iKeyMinus=109;
- U_DOM.K_iLeftMouseButton=G_BrowserInfo.M_bIsIE5QuirksMode?1:0;
- U_DOM.K_iRightMouseButton=2;
- U_DOM.F_CancelEvent=function(e){
- e=e||window.event;
- e.returnValue=false;
- e.cancelBubble=true;
- };
- U_DOM.F_CancelBubble=function(e){
- (e||window.event).cancelBubble=true;
- };
- U_DOM.F_CancelKeyboardEvent=function(e){
- e.returnValue=false;
- try{
- e.keyCode=0;
- }
- catch(e){
- }
- e.cancelBubble=true;
- };
- U_DOM.F_DeleteTableRows=function(tbl){
- if(tbl.rows){
- for(var i=tbl.rows.length-1;i>=0;i--){
- tbl.deleteRow(i);
- }
- }
- };
- U_DOM.F_SetActiveOrFocus=function(el){
- try{
- if(G_BrowserInfo.M_bIsIE){
- el.setActive();
- }else{
- if(el.focus){
- el.focus();
- }else{
- G_Debug.F_Print("focus not supported on "+el.tagName);
- G_Debug.F_Assert(false);
- }
- }
- }
- catch(e){
- }
- };
- U_DOM.F_RemoveAllChildren=function(_2b){
- if(!_2b){
- return;
- }
- var _2c=null;
- for(var i=_2b.childNodes.length-1;i>=0;i--){
- _2c=_2b.childNodes[i];
- _2b.removeChild(_2c);
- _2c=null;
- }
- };
- U_DOM.F_GetNextSiblingElement=function(el){
- for(var _2d=el.nextSibling;_2d;_2d=_2d.nextSibling){
- if(_2d.nodeType==U_XML.K_iNODE_ELEMENT){
- return _2d;
- }
- }
- return null;
- };
- U_DOM.F_HandleContextMenu=function(e){
- e=e||window.event;
- if(!U_DOM.F_IsSelectable(e.srcElement)){
- U_DOM.F_CancelEvent(e);
- return false;
- }
- return true;
- };
- U_DOM.F_HandleSelectStart=function(e){
- e=e||window.event;
- if(!U_DOM.F_IsSelectable(e.srcElement)){
- U_DOM.F_CancelEvent(e);
- return false;
- }
- return true;
- };
- U_DOM.F_IsSelectable=function(el){
- if(el.getAttribute){
- switch(el.getAttribute("HAL_isSelectable")){
- case "true":
- return true;
- case "false":
- return false;
- }
- }
- switch(el.nodeName){
- case "TEXTAREA":
- return true;
- case "INPUT":
- return (el.type=="text");
- }
- return false;
- };
- U_DOM.F_HasCaret=function(el){
- if(G_BrowserInfo.M_bIsIE){
- return (document.selection.createRange().parentElement()==el);
- }
- return (((window.s_IdCurrentTextBox!="")&&(window.s_IdCurrentTextBox==el.id))||(window.h_elActiveElement&&(window.h_elActiveElement==el)&&U_DOM.F_IsTextBoxOrTextArea(el)));
- };
- U_DOM.F_GetSelectedTextPosition=function(_2e){
- var _2f;
- var _30;
- if(G_BrowserInfo.M_bIsIE){
- var _31=document.selection.createRange();
- if(_31.parentElement()!=_2e){
- return null;
- }
- var _32=_31.duplicate();
- _32.moveToElementText(_2e);
- _32.setEndPoint("EndToStart",_31);
- _2f=_32.text.length-this.f_getNewLinesCount(_32.text);
- _30=_2f+_31.text.length-this.f_getNewLinesCount(_31.text);
- }else{
- _2f=_2e.selectionStart;
- _30=_2e.selectionEnd;
- }
- return {M_iStart:_2f,M_iEnd:_30};
- };
- U_DOM.f_getNewLinesCount=function(_33){
- var i=0;
- var _34=-1;
- do{
- i=_33.indexOf("\r\n",i);
- _34++;
- }while(i++>=0);
- return _34;
- };
- U_DOM.F_IsTextSelected=function(){
- if(G_BrowserInfo.M_bIsIE){
- return (document.selection.type=="Text")&&(document.selection.createRange().text.length>0);
- }
- if(window.getSelection()!=""){
- return true;
- }
- if(window.s_IdCurrentTextBox){
- var _35=document.getElementById(window.s_IdCurrentTextBox);
- return Boolean(_35&&(_35.selectionStart!=_35.selectionEnd));
- }
- return false;
- };
- U_DOM.F_GetSelectedText=function(){
- if(G_BrowserInfo.M_bIsIE){
- return document.selection.createRange().text;
- }
- if(window.getSelection()!=""){
- return window.getSelection().toString();
- }
- if(window.s_IdCurrentTextBox){
- var _36=document.getElementById(window.s_IdCurrentTextBox);
- if(_36){
- return _36.value.substring(_36.selectionStart,_36.selectionEnd);
- }
- }
- };
- U_DOM.F_ClearSelection=function(){
- if(window.getSelection){
- window.getSelection().removeAllRanges();
- }else{
- if(document.selection){
- document.selection.empty();
- }
- }
- };
- U_DOM.F_SetSelectionRange=function(_37,_38,_39){
- if(G_BrowserInfo.M_bIsIE){
- var rng=_37.createTextRange();
- rng.collapse(true);
- rng.moveEnd("character",_39);
- rng.moveStart("character",_38);
- rng.select();
- }else{
- _37.focus();
- if(_37.setSelectionRange){
- _37.setSelectionRange(_38,_39);
- }else{
- G_Debug.F_Print("U_DOM.F_SetSelectionRange (non-ie): This should only be called for textareas and text boxes, not for "+_37.tagName);
- }
- }
- };
- U_DOM.F_MoveCaretToMousePos=function(_3a,e){
- if(G_BrowserInfo.M_bIsIE){
- var rng=_3a.createTextRange();
- rng.moveToPoint(e.x,e.y);
- rng.select();
- }else{
- if(G_BrowserInfo.M_bFirefox3OrLater){
- _3a.focus();
- G_Debug.F_Print("Unable to determine cursor position with Firefox 3");
- }else{
- if(e.rangeParent&&e.rangeParent!=null){
- _3a.focus();
- var _3b=0;
- try{
- _3b=e.rangeOffset;
- _3b=this.f_findLocation(e.rangeParent,e.rangeOffset);
- }
- catch(ex){
- G_Debug.F_Print("U_DOM.F_MoveCaretToMousePos: selection failed: "+ex);
- _3b=e.srcElement.selectionStart;
- }
- _3a.setSelectionRange(_3b,_3b);
- }else{
- G_Debug.F_Print("U_DOM.F_MoveCaretToMousePos: selection failed");
- }
- }
- }
- };
- U_DOM.f_findLocation=function(_3c,_3d){
- while(_3c.previousSibling){
- _3c=_3c.previousSibling;
- if(_3c.length){
- _3d+=_3c.length;
- }else{
- _3d+=1;
- }
- }
- return _3d;
- };
- U_DOM.F_ReplaceTextSelection=function(_3e,_3f){
- if(G_BrowserInfo.M_bIsIE){
- var rng=document.selection.createRange();
- var _40=(rng.text=="");
- rng.text=_3e;
- if(!_40&&_3f){
- rng.moveStart("character",-_3e.length);
- rng.select();
- }
- return;
- }
- var _41=null;
- if(window.s_IdCurrentTextBox!=""){
- _41=document.getElementById(window.s_IdCurrentTextBox);
- }else{
- if(window.h_elActiveElement&&window.h_elActiveElement.tagName=="TEXTAREA"||(window.h_elActiveElement.tagName=="INPUT"&&window.h_elActiveElement.type=="text")){
- _41=window.h_elActiveElement;
- }
- }
- if(_41){
- var _42=_41.selectionStart;
- var _43=_41.selectionEnd;
- _41.value=_41.value.substring(0,_42)+_3e+_41.value.substring(_43);
- var _44=_42+_3e.length;
- if(_3f){
- U_DOM.F_SetSelectionRange(_41,_42,_44);
- }else{
- U_DOM.F_SetSelectionRange(_41,_44,_44);
- }
- }else{
- if(window.getSelection()!=""){
- var _45=window.getSelection().getRangeAt(0);
- if(_45.startContainer!=_45.endContainer){
- G_Debug.F_Print("U_DOM.F_ReplaceTextSelection does not support selection across elements");
- return;
- }
- var _46=_45.startContainer.nodeValue;
- var _47=_45.endOffset;
- var _48=_46.substring(_45.startOffset,_47);
- var _49=_46.substring(0,_45.startOffset);
- var _4a=_46.substring(_47);
- _45.startContainer.nodeValue=_49+_3e+_4a;
- if(_3f){
- _45.selectNode(_45.startContainer.parentNode);
- }
- }
- }
- };
- U_DOM.F_IsTextBoxOrTextArea=function(el){
- if(!el){
- return false;
- }
- if(el.tagName=="INPUT"&&el.type=="text"){
- return true;
- }
- return (el.tagName=="TEXTAREA");
- };
- U_DOM.F_HandleTab=function(e){
- e=e||window.event;
- this.F_CancelEvent(e);
- if(G_BrowserInfo.M_bIsIE){
- if(document.selection.type=="Text"){
- document.selection.clear();
- }
- document.selection.createRange().text=String.fromCharCode(e.keyCode);
- }else{
- if(this.F_IsTextBoxOrTextArea(e.srcElement)){
- var _4b=e.srcElement;
- var _4c=_4b.selectionStart;
- var _4d=_4b.selectionEnd;
- _4b.value=_4b.value.substring(0,_4c)+String.fromCharCode(e.keyCode)+_4b.value.substring(_4d);
- var _4e=String.fromCharCode(e.keyCode).length;
- this.F_SetSelectionRange(_4b,_4d+_4e,_4d+_4e);
- }else{
- G_Debug.F_Print("U_DOM.F_HandleTab (non IE) only works for text areas and text inputs, not "+e.srcElement.tagName);
- }
- }
- };
- U_DOM.F_IsVisible=function(el){
- if(el.currentStyle.visibility=="visible"){
- return true;
- }
- if(el.currentStyle.visibility=="hidden"){
- return false;
- }
- return (!el.parentNode||!el.parentNode.currentStyle||this.F_IsVisible(el.parentNode));
- };
- U_DOM.F_IsDisplayNone=function(el){
- for(;el&&el.currentStyle;el=el.parentNode){
- if(el.currentStyle.display=="none"){
- return true;
- }
- }
- return false;
- };
- U_DOM.F_SetRadioButtonEnabled=function(_4f,_50){
- _4f.disabled=!_50;
- var _51=_4f.parentElement;
- if(_51.tagName=="LABEL"){
- _51.disabled=!_50;
- if(!G_BrowserInfo.M_bIsIE){
- _51.setAttribute("HAL_disabled",_50?"false":"true");
- }
- }
- U_Accessibility.F_SetAriaStateAndProperty(_4f,"aria-disabled",!_50);
- };
- U_DOM.F_SetCheckboxEnabled=function(_52,_53){
- _52.disabled=!_53;
- var _54=_52.parentElement;
- if(_54.tagName=="LABEL"){
- _54.disabled=!_53;
- if(!G_BrowserInfo.M_bIsIE){
- _54.setAttribute("HAL_disabled",_53?"false":"true");
- }
- }
- U_Accessibility.F_SetAriaStateAndProperty(_52,"aria-disabled",!_53);
- };
- U_DOM.F_SetTextEnabled=function(_55,_56){
- _55.disabled=!_56;
- if(!G_BrowserInfo.M_bIsIE){
- _55.setAttribute("HAL_disabled",_56?"false":"true");
- }
- U_Accessibility.F_SetAriaStateAndProperty(_55,"aria-disabled",!_56);
- if(G_HAL.M_oLibraries["hal"]["enableAccessibility"]){
- var _57=_55.getAttribute("tabIndex");
- if(_57=="0"&&!_56){
- U_Accessibility.F_SetTabIndex(_55,"-1");
- }else{
- if(_57=="-1"&&_56){
- U_Accessibility.F_RestoreIndex(_55);
- }
- }
- }
- };
- U_DOM.F_SetTextInputEnabled=function(_58,_59){
- _58.disabled=!_59;
- if(!G_BrowserInfo.M_bIsIE){
- _58.setAttribute("HAL_disabled",_59?"false":"true");
- }
- U_Accessibility.F_SetAriaStateAndProperty(_58,"aria-disabled",!_59);
- };
- U_DOM.F_SetButtonEnabled=function(_5a,_5b,_5c){
- var btn=document.getElementById(_5a);
- var _5d=!btn.disabled;
- this.F_SetButtonEnabledFromButton(btn,_5b,_5c);
- if(G_HAL.M_oTestListener&&G_HAL.M_oTestListener.F_DOM_OnButtonEnabled&&(_5d!=Boolean(_5b))){
- G_HAL.M_oTestListener.F_DOM_OnButtonEnabled(_5a,_5b);
- }
- };
- U_DOM.F_SetButtonEnabledFromButton=function(btn,_5e,_5f){
- if(!btn){
- return;
- }
- var _60=!_5e;
- if((_60!=btn.disabled)||(btn.getAttribute("v_sImage")!=_5f)){
- if(_5f){
- btn.setAttribute("v_sImage",_5f);
- var nl=btn.getElementsByTagName("IMG");
- if(nl.length>0){
- var _61=btn.disabled;
- if(_61){
- btn.disabled=false;
- if(!G_BrowserInfo.M_bIsIE){
- btn.setAttribute("HAL_disabled","false");
- }
- }
- var _62=(_60?"_disabled.gif":".gif");
- var _63=nl.item(0);
- var _64=nl.item(nl.length-1);
- _63.src=G_HAL.F_GetImageURL(_5f+_62);
- if(_64.src.indexOf("dropdown_arrow")!=-1){
- _64.src=U_HighContrast.F_GetHighContrastImgIfNecessary(G_HAL.M_sImagePath+"dropdown_arrow"+_62);
- }
- if(btn.getAttribute("v_sButtonType")=="tblDropdown"){
- btn.nextSibling.disabled=_60;
- btn.nextSibling.firstChild.src=U_HighContrast.F_GetHighContrastImgIfNecessary(G_HAL.M_sImagePath+"dropdown_arrow"+_62);
- }
- if(_61){
- btn.disabled=true;
- if(!G_BrowserInfo.M_bIsIE){
- btn.setAttribute("HAL_disabled","true");
- }
- }
- if(_60&&(btn.getAttribute("HAL_isCoolButton")=="true")){
- btn.className=btn.v_sClassPrefix;
- }
- }
- }
- btn.disabled=_60;
- if(!G_BrowserInfo.M_bIsIE){
- btn.setAttribute("HAL_disabled",_60?"true":"false");
- }
- if(btn.v_bIsDlgButton){
- var _65=btn.v_sClassPrefix;
- if(btn.v_bIsDotDotDotButton||btn.v_bIsDlgButtonDropDownArrow){
- btn.className=_65+(_60?"_disabled":"");
- }else{
- btn.className=(_60?_65+" "+_65+"_disabled":_65);
- }
- }
- }
- U_Accessibility.F_SetAriaStateAndProperty(btn,"aria-disabled",!_5e);
- };
- U_DOM.F_SetFirstClassName=function(el,_66){
- var i=el.className.indexOf(" ");
- el.className=_66+((i==-1)?"":el.className.substring(i));
- };
- U_DOM.F_GetFirstClassName=function(el){
- if(!el.className){
- return "";
- }
- var i=el.className.indexOf(" ");
- return (i==-1)?el.className:el.className.substr(0,i);
- };
- U_DOM.F_ShowChildWindow=function(_67,_68,_69,_6a,_6b,_6c,_6d,_6e){
- var _6f=_6a?_6a.width:700;
- var _70=_6a?_6a.height:250;
- var _71=_6b?_6b.top:Math.F_NonNeg(screen.availHeight-_70);
- var _72=_6b?_6b.left:Math.F_NonNeg(screen.availWidth-_6f);
- if(_6c){
- _72=(document.body.clientWidth/2)-(_6f/2);
- _71=(document.body.clientHeight/2)-(_70/2);
- }
- if(_6e){
- var _73="";
- for(var i=0;i<document.styleSheets.length;i++){
- if(document.styleSheets[i]&&document.styleSheets[i].href!=""&&document.styleSheets[i].href.indexOf("css")!=-1){
- _73+="<link rel=\"stylesheet\" type=\"text/css\" href=\""+document.styleSheets[i].href+"\"/>";
- }
- }
- }
- var _74=_6d?"yes":"no";
- var _75=false;
- if(G_BrowserInfo.M_bIsIE){
- try{
- _75=true;
- var _76=window.showModelessDialog(G_HAL.F_GetFileURL("hal/blank.htm"),document,"edge:sunken; dialogWidth:"+_6f+"px; dialogHeight:"+_70+"px; resizable:"+_74+"; status:no; dialogTop:"+_71+"; dialogLeft:"+_72);
- }
- catch(e){
- _75=false;
- }
- }
- if(!_75){
- var _76=window.open("","","directories=no,location=no,status=no,toolbar=no,resizable="+_74+",scrollbars=yes,dependent=yes,height="+_70+",width="+_6f+",top="+_71+",left="+_72);
- if(this.F_WindowOpenWasBlocked(_76)){
- return null;
- }
- }
- var _77=[];
- _77.push("<html><head><title>"+_68+" </title>");
- _77.push(_73);
- _77.push("</head><body style=\""+(_69?_69:"")+"\">");
- _77.push(_67);
- _77.push("</body></html>");
- _76.document.open();
- _76.document.write(_77.join(""));
- _76.document.close();
- _76.document.title=_68+" ";
- _76.focus();
- return _76;
- };
- U_DOM.F_IsInElement=function(e,el){
- var _78=this.F_GetRelativeOffset(el,el.ownerDocument.body);
- return Math.F_PointInRect(e.clientY+el.ownerDocument.body.scrollTop,e.clientX+el.ownerDocument.body.scrollLeft,_78.top,_78.left,el.offsetWidth,el.offsetHeight);
- };
- U_DOM.F_GetOffsetTop=function(el){
- if(G_BrowserInfo.M_bIsIE){
- return el.offsetTop;
- }
- if(el.offsetParent&&el.offsetParent.currentStyle.overflow!="hidden"){
- return (el.offsetTop-this.F_GetBorderTopWidth(el.offsetParent));
- }
- return el.offsetTop;
- };
- U_DOM.F_GetOffsetLeft=function(el){
- if(G_BrowserInfo.M_bIsIE){
- return el.offsetLeft;
- }
- if(el.offsetParent&&el.offsetParent.currentStyle.overflow!="hidden"){
- return (el.offsetLeft-this.F_GetBorderLeftWidth(el.offsetParent));
- }
- return el.offsetLeft;
- };
- U_DOM.F_GetHorizontalBorderWidth=function(el){
- return this.F_GetBorderLeftWidth(el)+this.F_GetBorderRightWidth(el);
- };
- U_DOM.F_GetVerticalBorderWidth=function(el){
- return this.F_GetBorderTopWidth(el)+this.F_GetBorderBottomWidth(el);
- };
- U_DOM.F_GetBorderTopWidth=function(el){
- return this.f_getBorderValue(el,"Top");
- };
- U_DOM.F_GetBorderRightWidth=function(el){
- return this.f_getBorderValue(el,"Right");
- };
- U_DOM.F_GetBorderBottomWidth=function(el){
- return this.f_getBorderValue(el,"Bottom");
- };
- U_DOM.F_GetBorderLeftWidth=function(el){
- return this.f_getBorderValue(el,"Left");
- };
- U_DOM.f_getBorderValue=function(el,_79){
- var _7a=el.currentStyle["border"+_79+"Width"];
- var _7b=parseInt(_7a,10);
- if(isNaN(_7b)){
- return ((_7a=="medium")&&(el.currentStyle["border"+_79+"Style"]!="none"))?4:0;
- }
- return _7b;
- };
- U_DOM.F_GetVerticalPadding=function(el){
- return parseInt(el.currentStyle.paddingTop,10)+parseInt(el.currentStyle.paddingBottom,10);
- };
- U_DOM.F_GetHorizontalPadding=function(el){
- return parseInt(el.currentStyle.paddingLeft,10)+parseInt(el.currentStyle.paddingRight,10);
- };
- U_DOM.F_GetContentDimensions=function(el){
- return (new C_Dimension(el.offsetHeight,el.offsetWidth)).F_Subtract(this.F_GetNonContentDimensions(el));
- };
- U_DOM.F_GetNonContentDimensions=function(el){
- return new C_Dimension(this.F_GetVerticalPadding(el)+this.F_GetVerticalBorderWidth(el),this.F_GetHorizontalPadding(el)+this.F_GetHorizontalBorderWidth(el));
- };
- U_DOM.F_SetOpacity=function(el,_7c){
- el.style[G_BrowserInfo.M_bIsIE5QuirksMode?"filter":"opacity"]=G_BrowserInfo.M_bIsIE5QuirksMode?("progid:DXImageTransform.Microsoft.Alpha(opacity="+_7c+");"):(_7c/100);
- };
- U_DOM.F_RemoveOpacity=function(el){
- if(G_BrowserInfo.M_bIsIE5QuirksMode){
- el.style.removeAttribute("filter");
- }else{
- el.style.opacity="";
- }
- };
- U_DOM.F_GetBasePath=function(d){
- var re=/^(\/.*?)\//;
- re.test((d||document).location.pathname);
- return RegExp.$1;
- };
- U_DOM.F_NumbersOnlyOnChange=function(e,_7d,_7e,_7f,_80){
- e=e||window.event;
- var txt=e.srcElement;
- if(G_HAL.M_oLibraries["hal"]["enableAccessibility"]){
- this.F_ValidateNumberInput(txt,_7e,_7d,_7f,_80);
- return;
- }
- switch(_7e){
- case "integer":
- txt.value=txt.value.replace(_7d?/[^0-9-]/g:/[^0-9]/g,"");
- break;
- case "float":
- txt.value=txt.value.replace(_7d?/[^0-9.,-eE]/g:/[^0-9.,eE]/g,"");
- break;
- case "decimal":
- default:
- txt.value=txt.value.replace(_7d?/[^0-9.,-]/g:/[^0-9.,]/g,"");
- break;
- }
- };
- U_DOM.F_NumbersOnlyOnKeyPress=function(e,_81,_82){
- e=e||window.event;
- if(e.ctrlKey){
- return;
- }
- var _83=e.keyCode;
- if(!G_BrowserInfo.M_bIsIE){
- _83=e.charCode;
- if(_83==0){
- return;
- }
- }
- switch(_83){
- case this.K_iKeyEnter:
- case this.K_iKeyEscape:
- case 190:
- return;
- case 44:
- case 46:
- if(_82=="integer"){
- break;
- }
- return;
- case 69:
- case 101:
- if(_82=="float"){
- return;
- }
- break;
- case 45:
- if(_82=="float"){
- return;
- }
- if(_81){
- return;
- }
- }
- if(!G_HAL.M_oLibraries["hal"]["enableAccessibility"]){
- if((_83<"0".charCodeAt(0))||(_83>"9".charCodeAt(0))){
- e.returnValue=false;
- if(G_BrowserInfo.M_bIsIE){
- e.keyCode=0;
- }
- e.cancelBubble=true;
- }
- }
- };
- U_DOM.F_PercentOnlyOnChange=function(e,_84,_85,_86){
- e=e||window.event;
- var txt=e.srcElement;
- _86=_86||100;
- if(G_HAL.M_oLibraries["hal"]["enableAccessibility"]){
- this.F_ValidateNumberInput(txt,_85,_84,_86);
- return;
- }
- switch(_85){
- case "integer":
- txt.value=txt.value.replace(_84?/[^0-9-]/g:/[^0-9]/g,"");
- var _87=parseInt(txt.value,10);
- if(_87>_86){
- txt.value=_86.toString(10);
- }
- break;
- case "decimal":
- default:
- txt.value=txt.value.replace(_84?/[^0-9.,-]/g:/[^0-9.,]/g,"");
- var _88=parseFloat(txt.value,10);
- if(_88>_86){
- txt.value=_86.toString(10);
- }
- break;
- }
- };
- U_DOM.F_NumbersOnlyOnChangeHandler=function(e){
- U_DOM.F_NumbersOnlyOnChange(e);
- };
- U_DOM.F_NumbersOnlyOnKeyPressHandler=function(e){
- U_DOM.F_NumbersOnlyOnKeyPress(e);
- };
- function C_Position(_89,_8a){
- this.left=_89;
- this.top=_8a;
- };
- C_Position.prototype.F_Add=function(_8b){
- return new C_Position(this.left+_8b.left,this.top+_8b.top);
- };
- C_Position.prototype.F_Subtract=function(_8c){
- return new C_Position(this.left-_8c.left,this.top-_8c.top);
- };
- function C_Dimension(_8d,_8e){
- this.height=_8d?_8d:0;
- this.width=_8e?_8e:0;
- };
- C_Dimension.prototype.F_Add=function(_8f){
- return new C_Dimension(this.height+_8f.height,this.width+_8f.width);
- };
- C_Dimension.prototype.F_Subtract=function(_90){
- return new C_Dimension(Math.F_NonNeg(this.height-_90.height),Math.F_NonNeg(this.width-_90.width));
- };
- function C_Rectangle(_91,_92,_93,_94){
- this.left=_91;
- this.top=_92;
- this.right=_93;
- this.bottom=_94;
- this.width=_93-_91;
- this.height=_94-_92;
- };
- C_Rectangle.prototype.F_Subtract=function(_95){
- return new C_Rectangle(this.left-_95.left,this.top-_95.top,this.right-_95.right,this.bottom-_95.bottom);
- };
- C_Rectangle.prototype.F_Add=function(_96){
- return new C_Rectangle(this.left+_96.left,this.top+_96.top,this.right+_96.right,this.bottom+_96.bottom);
- };
- C_Rectangle.prototype.F_GetWidth=function(){
- return (this.right-this.left);
- };
- C_Rectangle.prototype.F_GetHeight=function(){
- return (this.bottom-this.top);
- };
- C_Rectangle.prototype.F_Intersects=function(_97){
- return (Math.F_PointInRect(this.top,this.left,_97.top,_97.left,_97.width,_97.height)||Math.F_PointInRect(this.top,this.right,_97.top,_97.left,_97.width,_97.height)||Math.F_PointInRect(this.bottom,this.left,_97.top,_97.left,_97.width,_97.height)||Math.F_PointInRect(this.bottom,this.right,_97.top,_97.left,_97.width,_97.height)||Math.F_PointInRect(_97.top,_97.left,this.top,this.left,this.width,this.height)||Math.F_PointInRect(_97.top,_97.right,this.top,this.left,this.width,this.height)||Math.F_PointInRect(_97.bottom,_97.left,this.top,this.left,this.width,this.height)||Math.F_PointInRect(_97.bottom,_97.right,this.top,this.left,this.width,this.height));
- };
- function C_Polygon(_98){
- this.m_aCoords=_98;
- };
- C_Polygon.prototype.F_GetLeft=function(){
- var _99=Infinity;
- for(var i=0;i<this.m_aCoords.length;i++){
- if(this.m_aCoords[i].left<_99){
- _99=this.m_aCoords[i].left;
- }
- }
- return _99;
- };
- C_Polygon.prototype.F_GetTop=function(){
- var _9a=Infinity;
- for(var i=0;i<this.m_aCoords.length;i++){
- if(this.m_aCoords[i].top<_9a){
- _9a=this.m_aCoords[i].top;
- }
- }
- return _9a;
- };
- C_Polygon.prototype.F_GetWidth=function(){
- var _9b=Infinity;
- var _9c=-Infinity;
- for(var i=0;i<this.m_aCoords.length;i++){
- if(this.m_aCoords[i].left>_9c){
- _9c=this.m_aCoords[i].left;
- }
- if(this.m_aCoords[i].left<_9b){
- _9b=this.m_aCoords[i].left;
- }
- }
- return (_9c-_9b);
- };
- C_Polygon.prototype.F_GetHeight=function(){
- var _9d=Infinity;
- var _9e=-Infinity;
- for(var i=0;i<this.m_aCoords.length;i++){
- if(this.m_aCoords[i].top>_9e){
- _9e=this.m_aCoords[i].top;
- }
- if(this.m_aCoords[i].top<_9d){
- _9d=this.m_aCoords[i].top;
- }
- }
- return (_9e-_9d);
- };
- C_Polygon.prototype.F_IsInRect=function(_9f){
- var _a0=this.F_GetLeft();
- if(_9f.left>=_a0&&_9f.left<=(_a0+this.F_GetWidth())){
- var _a1=this.F_GetTop();
- if(_9f.top>=_a1&&_9f.top<=(_a1+this.F_GetHeight())){
- return true;
- }
- }
- return false;
- };
- C_Polygon.prototype.F_IsInPolygon=function(_a2){
- if(!this.F_IsInRect(_a2)){
- return false;
- }
- var _a3=0;
- var j=this.m_aCoords.length-1;
- for(var i=0;i<this.m_aCoords.length;i++){
- var _a4=(this.m_aCoords[j].top-this.m_aCoords[i].top)/(this.m_aCoords[j].left-this.m_aCoords[i].left);
- if(isNaN(_a4)){
- j=i;
- continue;
- }
- if(_a4!=0&&Math.abs(_a4)!=Infinity){
- var b=this.m_aCoords[i].top-_a4*this.m_aCoords[i].left;
- var _a5=(_a2.top-b)/_a4;
- if((_a5>=this.m_aCoords[i].left&&_a5<=this.m_aCoords[j].left)||(_a5>=this.m_aCoords[j].left&&_a5<=this.m_aCoords[i].left)){
- if(_a5<_a2.left){
- if(_a2.top==this.m_aCoords[i].top){
- if(this.m_aCoords[j].top>_a2.top){
- _a3++;
- }
- }else{
- if(_a2.top==this.m_aCoords[j].top){
- if(this.m_aCoords[i].top>_a2.top){
- _a3++;
- }
- }else{
- _a3++;
- }
- }
- }
- }
- }else{
- if(_a4==0){
- j=i;
- continue;
- }else{
- var _a5=this.m_aCoords[i].left;
- var _a6=_a2.top;
- if((_a6>=this.m_aCoords[i].top&&_a6<=this.m_aCoords[j].top)||(_a6>=this.m_aCoords[j].top&&_a6<=this.m_aCoords[i].top)){
- if(_a5<_a2.left){
- if(_a6==this.m_aCoords[i].top){
- if(this.m_aCoords[j].top>_a2.top){
- _a3++;
- }
- }else{
- if(_a6==this.m_aCoords[j].top){
- if(this.m_aCoords[i].top>_a2.top){
- _a3++;
- }
- }else{
- _a3++;
- }
- }
- }
- }
- }
- }
- j=i;
- }
- return Boolean(_a3%2);
- };
- U_DOM.F_GetBoundingRect=function(el,_a7){
- var _a8=this.F_GetRelativeOffset(el,_a7||el.ownerDocument.body);
- return new C_Rectangle(_a8.left,_a8.top,_a8.left+el.offsetWidth,_a8.top+el.offsetHeight);
- };
- U_DOM.F_GetBoundingRectForElements=function(_a9,_aa){
- var _ab=U_DOM.F_GetRelativeOffset(_a9[0],_aa);
- var _ac=_ab.top;
- var _ad=_ab.left;
- var _ae=_ac+_a9[0].offsetHeight;
- var _af=_ad+_a9[0].offsetWidth;
- var _b0=_a9.length;
- for(var i=1;i<_b0;i++){
- var el=_a9[i];
- var _ab=U_DOM.F_GetRelativeOffset(el,_aa);
- if(_ab.top<_ac){
- _ac=_ab.top;
- }
- if(_ab.left<_ad){
- _ad=_ab.left;
- }
- var _b1=_ab.top+el.offsetHeight;
- if(_b1>_ae){
- _ae=_b1;
- }
- var _b2=_ab.left+el.offsetWidth;
- if(_b2>_af){
- _af=_b2;
- }
- }
- return new C_Rectangle(_ad,_ac,_af,_ae);
- };
- U_DOM.F_GetRelativeOffset=function(el,_b3){
- if(G_BrowserInfo.M_bIsIE||G_BrowserInfo.M_bIsWebKit){
- var _b4=el.getBoundingClientRect();
- var _b5=new C_Position(_b4.left,_b4.top);
- if(_b3){
- var _b6=_b3.getBoundingClientRect();
- _b5.top-=_b6.top;
- _b5.left-=_b6.left;
- if(_b3.tagName!="BODY"){
- _b5.top-=this.F_GetBorderTopWidth(_b3);
- _b5.left-=this.F_GetBorderLeftWidth(_b3);
- }
- if(_b3.scrollLeft){
- _b5.left+=_b3.scrollLeft;
- }
- if(_b3.scrollTop){
- _b5.top+=_b3.scrollTop;
- }
- }
- return _b5;
- }
- var _b7=el.ownerDocument.body;
- if(!_b3){
- _b3=_b7;
- }
- if(!G_BrowserInfo.M_bIsIE){
- return this.f_getRelativeOffsetFirefox(el,_b3);
- }
- };
- U_DOM.f_getOffsetFromHtml=function(el,_b8){
- var _b9=el.ownerDocument.body;
- if((el==_b9)||(el.nodeName=="HTML")||(el.nodeName=="#document")){
- return new C_Position(0,0);
- }
- var _ba=el.getBoundingClientRect();
- var _bb=Math.round(_ba.left);
- var _bc=Math.round(_ba.top);
- var _bd=el.parentNode;
- if(G_BrowserInfo.M_bFirefox3OrLater){
- return new C_Position(_bb,_bc);
- }
- var _be=(el!=_b8);
- while(_bd&&(_bd!=_b9)){
- if(_bd!=_b8&&_bd.currentStyle.overflow!="visible"){
- _bb-=_bd.scrollLeft;
- _bc-=_bd.scrollTop;
- }
- if(_bd.currentStyle.overflow!="visible"){
- _bc+=this.F_GetBorderTopWidth(_bd);
- _bb+=this.F_GetBorderLeftWidth(_bd);
- }
- _bd=_bd.parentNode;
- }
- if(_be){
- _bb-=this.F_GetBorderLeftWidth(el);
- var _bf=this.F_GetBorderTopWidth(el);
- _bc-=_bf;
- }
- return new C_Position(_bb,_bc);
- };
- U_DOM.f_getRelativeOffsetFirefox=function(el,_c0){
- var _c1=U_DOM.f_getOffsetFromHtml(el,_c0);
- if(_c0!=el.ownerDocument.body){
- var _c2=U_DOM.f_getOffsetFromHtml(_c0,_c0);
- var _c3=_c1.left-_c2.left;
- var _c4=_c1.top-_c2.top;
- if(G_BrowserInfo.M_bFirefox3OrLater){
- _c3-=this.F_GetBorderLeftWidth(_c0);
- _c4-=this.F_GetBorderTopWidth(_c0);
- }
- }else{
- var _c3=_c1.left;
- var _c4=_c1.top;
- }
- if(G_BrowserInfo.M_bFirefox3OrLater){
- if(_c0.scrollLeft){
- _c3+=_c0.scrollLeft;
- }
- if(_c0.scrollTop){
- _c4+=_c0.scrollTop;
- }
- }
- return new C_Position(_c3,_c4);
- };
- U_DOM.m_iUniqueIdCounter=1;
- U_DOM.F_GetUniqueId=function(_c5,d){
- if(!_c5){
- return ("hal__dom__uniqueID__"+this.m_iUniqueIdCounter++);
- }
- var _c6=_c5;
- if(!d){
- d=document;
- }
- var i=1;
- while(d.getElementById(_c6)){
- _c6=_c5+i++;
- }
- return _c6;
- };
- U_DOM.F_GetStyleSheet=function(_c7,d){
- if(!d){
- d=document;
- }
- if(G_BrowserInfo.M_bIsIE){
- return d.styleSheets(_c7);
- }
- var _c8=d.getElementById(_c7);
- return _c8?_c8.sheet:null;
- };
- U_DOM.F_AddScript=function(_c9,d){
- if(!d){
- d=document;
- }
- var _ca=d.getElementsByTagName("HEAD").item(0).appendChild(d.createElement("SCRIPT"));
- _ca.text=_c9;
- return _ca;
- };
- U_DOM.F_LoadScript=function(_cb,_cc,d){
- if(!d){
- d=document;
- }
- var _cd=d.createElement("script");
- _cd.type="text/javascript";
- if(_cc){
- if(_cd.readyState){
- _cd.onreadystatechange=function(){
- if(_cd.readyState=="loaded"||_cd.readyState=="complete"){
- _cd.onreadystatechange=null;
- _cc();
- }
- };
- }else{
- _cd.onload=_cc;
- }
- }
- _cd.src=_cb;
- d.getElementsByTagName("head")[0].appendChild(_cd);
- };
- U_DOM.F_ShowEventBlocker=function(_ce){
- if(!this.m_divEventBlocker){
- this.m_divEventBlocker=document.body.appendChild(document.createElement("DIV"));
- this.m_divEventBlocker.onkeydown=this.f_stopTabKey;
- this.m_divEventBlocker.className="clsBlocker";
- }
- this.m_divEventBlocker.style.zIndex=_ce;
- this.m_divEventBlocker.style.visibility="visible";
- return this.m_divEventBlocker;
- };
- U_DOM.F_HideEventBlocker=function(){
- if(this.m_divEventBlocker){
- this.m_divEventBlocker.style.visibility="hidden";
- var _cf=["onmousedown","onmouseup","onmousemove","onclick","ondblclick","onmouseover","onmouseout"];
- for(var i=0;i<_cf.length;i++){
- this.m_divEventBlocker[_cf[i]]=null;
- }
- }
- };
- U_DOM.f_stopTabKey=function(e){
- e=e||window.event;
- if(e.keyCode==U_DOM.K_iKeyTab){
- U_DOM.F_CancelEvent(e);
- }
- };
- U_DOM.F_EmptyFunction=function(){
- };
- U_DOM.F_GetPropertyInTryCatch=function(o,_d0){
- try{
- return o[_d0];
- }
- catch(e){
- G_Debug.F_Print("U_DOM.F_GetPropertyInTryCatch caught exception accessing o["+_d0+"]");
- return null;
- }
- };
- U_DOM.F_SetColorButtonColor=function(btn,_d1,_d2){
- if(btn){
- var div=btn.getElementsByTagName("DIV").item(0);
- div.className=(_d1=="transparent")?"clsColorButtonDIV_transparent":"clsColorButtonDIV_normal";
- div.style.backgroundColor=_d1?_d1:"";
- if(_d2){
- div.innerText=_d2;
- }
- if(G_HAL.M_oLibraries["hal"]["enableAccessibility"]&&_d1){
- U_Accessibility.F_AddAriaHiddenSpan(btn,"aria-describedby",this.F_GetColorAriaLabel(_d1));
- }
- }
- };
- U_DOM.F_DisplayTDs=function(el){
- if(!G_BrowserInfo.M_bIsIE){
- return;
- }
- var nl=el.getElementsByTagName("TD");
- var _d3=nl.length;
- for(var i=0;i<_d3;i++){
- var td=nl.item(i);
- if(td.style.display=="none"){
- td.style.display="";
- }
- }
- };
- U_DOM.F_IsVmlSupported=function(){
- if(G_BrowserInfo.M_bIsIE5QuirksMode){
- var _d4=document.body.appendChild(document.createElement("<v:polyline points=\"0px,0px\" strokecolor=\"black\" strokeweight=\"1px\" filled=\"false\" style=\"position:absolute\"></v:polyline>"));
- var s=typeof _d4.points;
- _d4.parentNode.removeChild(_d4);
- return (s!="string");
- }
- return false;
- };
- U_DOM.F_WindowOpenWasBlocked=function(win,_d5){
- var b=Boolean(win);
- if(!b&&(_d5!=false)){
- var _d6=window["G_ResManager"]?G_ResManager.F_GetOptionalString("IDS_HAL_POPUP_BLOCKER_ERROR"):null;
- alert(_d6||"A window could not be opened. This is most likely caused by a popup blocker. Please disable your popup blocker.");
- }
- return !b;
- };
- U_DOM.F_HookTextInputOnChangeEvent=function(_d7,_d8){
- _d7.onchange=function(e){
- _d8();
- };
- _d7.oncut=function(){
- setTimeout(_d8,0);
- };
- _d7.onpaste=function(){
- setTimeout(_d8,0);
- };
- _d7.onkeyup=function(){
- setTimeout(_d8,0);
- };
- _d7.ondrop=function(){
- setTimeout(_d8,0);
- };
- _d7.onmouseup=function(){
- setTimeout(_d8,0);
- };
- };
- U_DOM.F_UnHookTextInputOnChangeEvent=function(_d9){
- _d9.onkeypress=null;
- _d9.onchange=null;
- _d9.oncut=null;
- _d9.onpaste=null;
- _d9.onkeyup=null;
- _d9.ondrop=null;
- _d9.onmouseup=null;
- };
- U_DOM.F_HookNumericInputOnChangeEvent=function(_da,_db,_dc,_dd){
- _da.onkeypress=function(e){
- U_DOM.F_NumbersOnlyOnKeyPress(e,_dc,_dd);
- };
- _da.onchange=function(e){
- U_DOM.F_NumbersOnlyOnChange(e,_dc,_dd);
- _db();
- };
- _da.oncut=function(){
- setTimeout(_db,0);
- };
- _da.onpaste=function(){
- setTimeout(_db,0);
- };
- _da.onkeyup=function(){
- setTimeout(_db,0);
- };
- _da.ondrop=function(){
- setTimeout(_db,0);
- };
- _da.onmouseup=function(){
- setTimeout(_db,0);
- };
- };
- U_DOM.F_UnHookNumericInputOnChangeEvent=function(_de){
- _de.onkeypress=null;
- _de.onchange=null;
- _de.oncut=null;
- _de.onpaste=null;
- _de.onkeyup=null;
- _de.ondrop=null;
- _de.onmouseup=null;
- };
- U_DOM.F_CreateArgumentsArray=function(_df,_e0){
- var a=[];
- for(var i=_e0||0;i<_df.length;i++){
- a.push(_df[i]);
- }
- return a;
- };
- U_DOM.F_GetColorAriaLabel=function(_e1){
- var _e2=G_ResManager.F_GetOptionalString("IDS_HAL_COLOR_"+_e1.toUpperCase());
- return _e2?_e2:_e1;
- };
- U_DOM.F_ValidateNumber=function(_e3,_e4,_e5,_e6,_e7){
- if(!G_HAL.M_oLibraries["hal"]["enableAccessibility"]||(_e3=="")){
- return true;
- }
- var _e8;
- var _e9;
- switch(_e4){
- case "integer":
- _e8=_e5?/[^0-9-]/g:/[^0-9]/g;
- _e9=parseInt(_e3,10);
- break;
- case "float":
- _e8=_e5?/[^0-9.,-eE]/g:/[^0-9.,eE]/g;
- _e9=parseFloat(_e3,10);
- break;
- case "decimal":
- default:
- _e8=_e5?/[^0-9.,-]/g:/[^0-9.,]/g;
- _e9=parseFloat(_e3,10);
- break;
- }
- if(_e3.match(_e8)||isNaN(_e9)){
- F_MsgBox(G_ResManager.F_GetString("IDS_HAL_ERR_INVALID_NUMBER"));
- return false;
- }else{
- if(_e6!==undefined&&_e6!==null&&_e9>_e6){
- F_MsgBox(G_ResManager.F_GetString("IDS_HAL_ERR_INVALID_MAX",Number.F_ToLocalizedString(_e6)));
- return false;
- }else{
- if(_e7!==undefined&&_e7!==null&&_e9<_e7){
- F_MsgBox(G_ResManager.F_GetString("IDS_HAL_ERR_INVALID_MIN",Number.F_ToLocalizedString(_e7)));
- return false;
- }
- }
- }
- return true;
- };
- U_DOM.F_ValidateNumberInput=function(_ea,_eb,_ec,_ed,_ee){
- if(!G_HAL.M_oLibraries["hal"]["enableAccessibility"]){
- return true;
- }
- var _ef=this.F_ValidateNumber(_ea.value,_eb,_ec,_ed,_ee);
- if(!_ef){
- _ea.value="";
- }
- return _ef;
- };
- if(G_BrowserInfo.M_bIsIE){
- U_DOM.m_oActiveTimeouts={};
- U_DOM.m_iNextTimeoutIDX=1;
- U_DOM.F_CreateClearableTimeout=function(_f0,_f1){
- var _f2=this.m_iNextTimeoutIDX++;
- this.m_oActiveTimeouts[_f2]=setTimeout(this.f_timeoutHandler.F_CreateMethodCallback(this,_f0,_f2),_f1);
- return _f2;
- };
- U_DOM.F_ClearTimeout=function(_f3){
- var _f4=this.m_oActiveTimeouts[_f3];
- if(_f4){
- delete this.m_oActiveTimeouts[_f3];
- clearTimeout(_f4);
- }
- };
- U_DOM.f_timeoutHandler=function(_f5,_f6){
- if(this.m_oActiveTimeouts[_f6]){
- delete this.m_oActiveTimeouts[_f6];
- _f5(_f6);
- }
- };
- }else{
- U_DOM.F_CreateClearableTimeout=function(_f7,_f8){
- return setTimeout(_f7,_f8);
- };
- U_DOM.F_ClearTimeout=function(_f9){
- clearTimeout(_f9);
- };
- }
- U_DOM.f_splitRules=function(_fa){
- var _fb=[];
- var _fc=[];
- _fc=_fa.selectorText.split(", ");
- for(var i=0;i<_fc.length;i++){
- var _fd={};
- _fd.selectorText=_fc[i];
- for(var s in _fa){
- if(s!="selectorText"){
- _fd[s]=_fa[s];
- }
- }
- _fb.push(_fd);
- }
- return _fb;
- };
- U_DOM.F_GetCssRules=function(_fe){
- if(G_BrowserInfo.M_bIsIE&&_fe.rules){
- return _fe.rules;
- }
- var _ff=[];
- for(var i=0;i<_fe.cssRules.length;i++){
- var _100=_fe.cssRules.item(i);
- if(_100.type==1){
- _ff=_ff.concat(this.f_splitRules(_100));
- }else{
- if(_100.type==4){
- var _101=_100.cssRules.length;
- for(var j=0;j<_101;j++){
- var _102=_100.cssRules.item(j);
- if(_102.type==1){
- _ff=_ff.concat(this.f_splitRules(_102));
- }
- }
- }
- }
- }
- _ff.item=this.F_Item;
- return _ff;
- };
- U_DOM.F_Item=function(i){
- return this[i];
- };
- if("".trimLeft){
- String.prototype.F_LTrim=function(){
- return this.trimLeft();
- };
- }else{
- String.prototype.F_LTrim=function(){
- return this.replace(/(^\s*)/g,"");
- };
- }
- if("".trimRight){
- String.prototype.F_RTrim=function(){
- return this.trimRight();
- };
- }else{
- String.prototype.F_RTrim=function(){
- return this.replace(/(\s*$)/g,"");
- };
- }
- if("".trim){
- String.prototype.F_Trim=function(){
- return this.trim();
- };
- }else{
- String.prototype.F_Trim=function(){
- return this.replace(/(^\s*)|(\s*$)/g,"");
- };
- }
- String.prototype.F_RemoveNewLines=function(){
- return this.replace(/[\r\n]/g,"");
- };
- String.prototype.F_Truncate=function(_103,_104){
- if(this.length<=_103){
- return this.valueOf();
- }
- var b=(_104!=false);
- if(this.F_ContainsSurrogatePairs()){
- var _105=this.F_CharLength();
- if(_105>_103){
- return this.F_CharSubStr(0,b?_105-3:_105)+(b?"...":"");
- }
- return this.valueOf();
- }
- return this.substr(0,b?_103-3:_103)+(b?"...":"");
- };
- String.prototype.F_JScriptEscape=function(){
- return this.replace(/\\/g,"\\\\").replace(/\'/g,"\\'").replace(/\"/g,"\\\"").replace(/\r?\n/g,"\\r\\n");
- };
- String.prototype.F_ToXPathString=function(){
- if(this.indexOf("'")==-1){
- return ("'"+this+"'");
- }
- if(this.indexOf("\"")==-1){
- return ("\""+this+"\"");
- }
- var a=[];
- a.push("concat(");
- var _106=this.split("'");
- for(var i=0;i<_106.length;i++){
- if(a.length>1){
- a.push(",");
- }
- if(i>0){
- a.push("\"'\"");
- }
- var _107=_106[i];
- if(_107){
- if(this.indexOf("\"")==-1){
- if(a.length>1){
- a.push(",");
- }
- a.push("\""+_107+"\"");
- }else{
- var _108=_107.split("'");
- for(var j=0;j<_108.length;j++){
- if(a.length>1){
- a.push(",");
- }
- if(_108[j]){
- a.push("'"+_108[j]+"'");
- }
- }
- }
- }
- }
- a.push(")");
- return a.join("");
- };
- String.prototype.F_XMLEncode=function(){
- return this.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/'/g,"'").replace(/"/g,""");
- };
- String.prototype.F_XMLDecode=function(){
- return this.replace(/"/g,"\"").replace(/'/g,"'").replace(/>/g,">").replace(/</g,"<").replace(/&/g,"&");
- };
- String.prototype.F_HTMLEncode=function(){
- return this.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">");
- };
- String.prototype.F_HTMLAttributeEncode=function(){
- return this.F_HTMLEncode().replace(/'/g,"'").replace(/"/g,""");
- };
- String.prototype.F_RegExpEscape=function(){
- return this.replace(/([\[\]\^\$\*\+\?\(\)\{\}\|.])/g,function($0){
- return "\\"+$0;
- });
- };
- String.prototype.F_PadLeft=function(_109,_10a){
- var _10b="";
- for(var _10c=_10a-this.F_CharLength();_10c>0;_10c--){
- _10b+=_109;
- }
- return _10b+this;
- };
- String.prototype.F_PadRight=function(_10d,_10e){
- var _10f="";
- for(var _110=_10e-this.F_CharLength();_110>0;_110--){
- _10f+=_10d;
- }
- return this+_10f;
- };
- String.F_ParseFloat=function(s){
- if(typeof s=="string"){
- return parseFloat(s.replace(",","."));
- }
- return NaN;
- };
- String.prototype.F_ParseFloat=function(){
- return String.F_ParseFloat(this.valueOf());
- };
- String.F_ParseDecimal=function(s){
- return new C_Decimal(s);
- };
- String.prototype.F_ParseDecimal=function(){
- return String.F_ParseDecimal(this.valueOf());
- };
- String.prototype.F_GetChars=function(){
- if(!this.F_ContainsSurrogatePairs()){
- return this.split("");
- }
- var a=[];
- for(var i=0;i<this.length;i++){
- if(this.F_IsHS(i)){
- a.push(this.charAt(i)+this.charAt(++i));
- }else{
- if(this.F_IsLS(i)){
- }else{
- a.push(this.charAt(i));
- }
- }
- }
- return a;
- };
- String.prototype.F_ContainsSurrogatePairs=function(){
- return Boolean(this.match(/[\uD800-\uDBFF]/));
- };
- String.prototype.F_CharLength=function(){
- if(this.length<2){
- return this.length;
- }
- var a=this.match(/[\uD800-\uDBFF]/g);
- return a?(this.length-a.length):this.length;
- };
- String.F_FromCharCode=function(_111){
- if(_111>65535){
- _111-=65536;
- return this.fromCharCode(55296+(_111>>10),56320+(_111&1023));
- }
- return this.fromCharCode(_111);
- };
- String.prototype.F_CharAt=function(_112){
- return this.F_GetChars()[_112];
- };
- String.prototype.F_CharIndexOf=function(s){
- var i=this.indexOf(s);
- return (i==-1)?-1:this.substring(0,i).F_CharLength();
- };
- String.prototype.F_LastCharIndexOf=function(s){
- var i=this.lastIndexOf(s);
- return (i==-1)?-1:this.substring(0,i).F_CharLength();
- };
- String.prototype.F_CharSubStr=function(_113,_114){
- if(this.F_ContainsSurrogatePairs()){
- return this.F_GetChars().slice(_113||0,_114).join("");
- }
- return this.substr(_113,_114);
- };
- String.prototype.F_CharSubString=function(_115,_116){
- if(this.F_ContainsSurrogatePairs()){
- var a=this.F_GetChars();
- _115=_115||0;
- return a.slice(_115,a.length-(_116||0)).join("");
- }
- return this.substring(_115,_116);
- };
- String.prototype.F_IsHS=function(i){
- var _117=this.charCodeAt(i);
- return ((_117>=55296)&&(_117<=56319));
- };
- String.prototype.F_IsLS=function(i){
- var _118=this.charCodeAt(i);
- return ((_118>=56320)&&(_118<=57343));
- };
- Number.m_sDecimalSymbol=".";
- Number.F_SetDecimalSymbol=function(s){
- this.m_sDecimalSymbol=s;
- };
- Number.F_ToLocalizedString=function(v){
- var f=NaN;
- switch(typeof v){
- case "number":
- f=v;
- break;
- case "string":
- f=parseFloat(v);
- break;
- }
- if(isNaN(f)){
- return "";
- }
- return f.toString().replace(".",Number.m_sDecimalSymbol);
- };
- Number.prototype.F_ToLocalizedString=function(){
- return Number.F_ToLocalizedString(this.valueOf());
- };
- Math.F_NonNeg=function(i){
- return (i<0)?0:i;
- };
- Math.F_NonNaN=function(i){
- return (isNaN(i))?0:i;
- };
- Math.F_PointInRect=function(_119,_11a,_11b,_11c,_11d,_11e){
- return ((_119>=_11b)&&(_119<=(_11b+_11e))&&(_11a>=_11c)&&(_11a<=(_11c+_11d)));
- };
- Math.F_SortNumeric=function(a,b){
- return a-b;
- };
- Array.prototype.F_Top=function(){
- return (this.length>0)?this[this.length-1]:null;
- };
- Array.prototype.F_Clear=function(){
- this.length=0;
- };
- if(!Array.prototype.indexOf){
- Array.prototype.indexOf=function(_11f){
- var _120=this.length;
- for(var i=0;i<_120;++i){
- if(this[i]==_11f){
- return i;
- }
- }
- return -1;
- };
- }
- Array.prototype.F_IndicesOf=function(_121){
- var a=[];
- var _122=this.length;
- for(var i=0;i<_122;i++){
- if(this[i]==_121){
- a.push(i);
- }
- }
- return a;
- };
- Array.prototype.F_PushUnique=function(_123){
- if(this.indexOf(_123)==-1){
- this.push(_123);
- return true;
- }
- return false;
- };
- Array.prototype.F_RemoveItem=function(_124){
- var i=this.indexOf(_124);
- if(i!=-1){
- this.splice(i,1);
- }
- return i!=-1;
- };
- Array.prototype.F_IndexOfProperty=function(_125,_126){
- var _127=this.length;
- for(var i=0;i<_127;i++){
- if(this[i][_125]==_126){
- return i;
- }
- }
- return -1;
- };
- Array.prototype.F_Compare=function(a){
- var _128=this.length;
- if(_128!=a.length){
- return false;
- }
- for(var i=0;i<_128;i++){
- if(this[i]!=a[i]){
- return false;
- }
- }
- return true;
- };
- Array.prototype.F_CompareIgnoreOrder=function(a){
- if(this.length!=a.length){
- return false;
- }
- for(var i=0;i<this.length;i++){
- if(a.indexOf(this[i])==-1){
- return false;
- }
- }
- return true;
- };
- Array.prototype.F_CreateDictionary=function(){
- var o={};
- var _129=this.length;
- for(var i=0;i<_129;i++){
- o[this[i]]=true;
- }
- return o;
- };
- Array.prototype.F_CreateCompareDictionary=function(){
- var o={};
- var _12a=this.length;
- for(var i=0;i<_12a;i++){
- o[this[i]]=this[i];
- }
- return o;
- };
- Array.prototype.F_AppendArray=function(a){
- var _12b=a.length;
- for(var i=0;i<_12b;i++){
- this.push(a[i]);
- }
- };
- Array.prototype.F_CallEach=function(_12c){
- var args=[];
- var _12d=arguments.length;
- for(var i=1;i<_12d;++i){
- args.push(arguments[i]);
- }
- var _12d=this.length;
- for(var i=0;i<_12d;i++){
- var o=this[i];
- var _12e=o?o[_12c]:null;
- if(_12e){
- _12e.apply(o,args);
- }
- }
- };
- Array.prototype.F_ForEach=function(_12f){
- var _130=arguments[1]||this;
- var _131=this.length;
- for(var i=0;i<_131;i++){
- _12f.call(_130,this[i],i,this);
- }
- };
- function f_halConstructBaseClass(){
- f_halConstructBaseClass.caller.toString().match(/^function\s([^\(]+)/);
- window[RegExp.$1].baseConstructor.apply(this,arguments);
- };
- Function.prototype.F_Extends=function(_132){
- function c(){
- };
- c.prototype=_132.prototype;
- this.prototype=new c();
- this.prototype.constructor=this;
- this.baseConstructor=_132;
- this.superClass=_132.prototype;
- this.prototype.F_ConstructBaseClass=f_halConstructBaseClass;
- };
- Function.prototype.F_CreateCallback=function(){
- var _133=U_DOM.F_CreateArgumentsArray(arguments);
- var _134=this;
- return (function(){
- return _134.apply(window,_133.concat(U_DOM.F_CreateArgumentsArray(arguments)));
- });
- };
- Function.prototype.F_CreateMethodCallback=function(_135){
- var _136=U_DOM.F_CreateArgumentsArray(arguments,1);
- var _137=this;
- return (function(){
- return _137.apply(_135,_136.concat(U_DOM.F_CreateArgumentsArray(arguments)));
- });
- };
- Function.prototype.F_CreateEventMethodCallback=function(_138){
- var _139=U_DOM.F_CreateArgumentsArray(arguments,1);
- var _13a=this;
- return (function(e){
- _139.unshift(e||window.event,this);
- return _13a.apply(_138,_139);
- });
- };
- Function.prototype.F_GetFunctionName=function(){
- return this.toString().match(/^\s*function\s*(\w+)/)[1];
- };
- var U_Object={};
- U_Object.F_IsEmpty=function(o){
- for(var s in o){
- return false;
- }
- return true;
- };
- U_Object.F_ToArray=function(o){
- var a=[];
- for(var s in o){
- a.push(s);
- }
- return a;
- };
- U_Object.F_ToValueArray=function(o){
- var a=[];
- for(var s in o){
- a.push(o[s]);
- }
- return a;
- };
- U_Object.F_GetLength=function(o){
- var i=0;
- for(var s in o){
- i++;
- }
- return i;
- };
- U_Object.F_Copy=function(o){
- var _13b={};
- for(var s in o){
- _13b[s]=o[s];
- }
- return _13b;
- };
- U_Object.F_Clone=function(o){
- switch(typeof o){
- case "number":
- case "string":
- case "boolean":
- case "undefined":
- return o;
- case "object":
- if(o instanceof Array){
- var _13c=[];
- var _13d=o.length;
- for(var i=0;i<_13d;i++){
- _13c[i]=this.F_Clone(o[i]);
- }
- return _13c;
- }
- if(o instanceof Object){
- var _13e={};
- for(var s in o){
- if(o.hasOwnProperty(s)){
- _13e[s]=this.F_Clone(o[s]);
- }
- }
- return _13e;
- }
- break;
- case "function":
- }
- };
- U_Object.F_Subtract=function(o1,o2){
- var _13f=this.F_Copy(o1);
- for(var s in o2){
- delete _13f[s];
- }
- return _13f;
- };
- U_Object.F_GetClassName=function(o){
- return o.constructor.F_GetFunctionName();
- };
- function C_StringStream(){
- this.m_a=[];
- };
- C_StringStream.prototype.F_Write=function(s){
- this.m_a.push(s);
- };
- C_StringStream.prototype.F_WriteStringStream=function(_140){
- this.F_Write(_140.F_ToString());
- };
- C_StringStream.prototype.F_ToString=function(){
- return this.m_a.join("");
- };
- C_StringStream.prototype.f_getPlaceHolders=function(){
- if(!this.m_oPlaceHolders){
- this.m_oPlaceHolders={};
- this.m_iPlaceHolderCounter=0;
- }
- return this.m_oPlaceHolders;
- };
- C_StringStream.prototype.F_CreatePlaceHolder=function(s){
- this.f_getPlaceHolders()[++this.m_iPlaceHolderCounter]=this.m_a.length;
- this.m_a.push(s?s:"");
- return this.m_iPlaceHolderCounter;
- };
- C_StringStream.prototype.F_WriteToPlaceHolder=function(_141,s){
- this.m_a[this.m_oPlaceHolders[_141]]=s;
- };
- function C_Decimal(s){
- s=s.replace(/\s*/g,"").replace(",",".");
- if(s&&(s.match(/^([\+\-]?)0*(\d*?)\.(\d*?)0*$/)||s.match(/^([\+\-]?)0*(\d*?)$/))){
- var _142=RegExp.$1;
- var _143=RegExp.$2;
- var _144=RegExp.$3;
- if(_143||_144){
- var _145=_143?_143:"0";
- if(_144){
- _145+="."+_144;
- }
- _142=(_145=="0")?"":_142;
- this.m_sDecimal=_142+_145;
- }else{
- this.m_sDecimal="0";
- }
- }
- };
- C_Decimal.prototype.F_IsNaN=function(){
- return !this.m_sDecimal;
- };
- C_Decimal.prototype.F_ToLocalizedString=function(){
- return this.m_sDecimal?this.m_sDecimal.replace(".",Number.m_sDecimalSymbol):"NaN";
- };
- C_Decimal.prototype.F_ToString=function(){
- return this.m_sDecimal?this.m_sDecimal:"";
- };
- C_Decimal.prototype.F_ToFloat=function(){
- return this.m_sDecimal?String.F_ParseFloat(this.m_sDecimal):NaN;
- };
- C_Decimal.F_Add=function(_146,_147){
- return this.f_addOrSubtract(_146,_147,true);
- };
- C_Decimal.F_Subtract=function(_148,_149){
- return this.f_addOrSubtract(_148,_149,false);
- };
- C_Decimal.f_addOrSubtract=function(_14a,_14b,_14c){
- var s1=_14a.F_ToString()||"0.0";
- var s2=_14b.F_ToString()||"0.0";
- var _14d=s1.lastIndexOf(".");
- if(_14d==-1){
- s1+=".0";
- _14d=1;
- }else{
- _14d=s1.length-1-_14d;
- }
- var _14e=s2.lastIndexOf(".");
- if(_14e==-1){
- s2+=".0";
- _14e=1;
- }else{
- _14e=s2.length-1-_14e;
- }
- var _14f=Math.max(_14d,_14e);
- s1=s1.replace(".","");
- s2=s2.replace(".","");
- if(_14d>_14e){
- s2=s2.F_PadRight("0",s2.length+(_14d-_14e));
- }else{
- if(_14e>_14d){
- s1=s1.F_PadRight("0",s1.length+(_14e-_14d));
- }
- }
- if(s2.length>s1.length){
- s1=s1.F_PadLeft("0",s1.length+(s2.length-s1.length));
- }
- var a1=s1.split("").reverse();
- var a2=s2.split("").reverse();
- var _150=new Array(a1.length+1);
- for(var i=0;i<_150.length;i++){
- _150[i]=0;
- }
- for(var i=0;i<a1.length;i++){
- var _151=_150.length-1-i;
- var n1=parseInt(a1[i]);
- var n2=parseInt(a2[i]);
- n2=n2?n2:0;
- if(_14c){
- var _152=n1+n2;
- if((_152+_150[_151])>9){
- _150[_151-1]++;
- _152-=10;
- }
- _150[_151]+=_152;
- }else{
- var _152=n1-n2;
- if(_152<0){
- _150[_151-1]--;
- _152+=10;
- }
- _150[_151]+=_152;
- if(_150[_151]<0){
- _150[_151-1]--;
- _150[_151]+=10;
- }
- }
- }
- _150.splice(_150.length-_14f,0,".");
- return new C_Decimal(_150.join(""));
- };
- var G_JSON;
- if(typeof JSON=="undefined"){
- G_JSON={};
- G_JSON.parse=function(_153){
- return eval("("+_153+")");
- };
- G_JSON.stringify=function(o){
- var as=[];
- if(o==null){
- as.push("null");
- }else{
- if(o instanceof Array){
- as.push("[");
- for(var i=0;i<o.length;++i){
- if(i>0){
- as.push(",");
- }
- as.push(this.stringify(o[i]));
- }
- as.push("]");
- }else{
- switch(typeof o){
- case "object":
- as.push("{");
- var _154=0;
- for(var s in o){
- if(_154++>0){
- as.push(",");
- }
- as.push("\""+s.replace(/\\/g,"\\\\").replace(/\"/g,"\\\"").replace(/\r?\n/g,"\\r\\n")+"\":");
- as.push(this.stringify(o[s]));
- }
- as.push("}");
- break;
- case "string":
- as.push("\""+o.replace(/\\/g,"\\\\").replace(/\"/g,"\\\"").replace(/\r?\n/g,"\\r\\n")+"\"");
- break;
- default:
- as.push(o);
- break;
- }
- }
- }
- return as.join("");
- };
- }else{
- G_JSON=JSON;
- }
- function C_WebRequest(_155,_156,_157,_158,_159,_15a){
- this.m_oListener=_155;
- this.m_sMethod=_156;
- this.m_sUrl=_157;
- this.m_bAsync=(_158!==false);
- this.m_sUser=_159;
- this.m_sPassword=_15a;
- this.m_bUseCache=true;
- this.m_oError=null;
- this.m_aRequestHeaders=[];
- };
- C_WebRequest.prototype.F_GetListener=function(){
- return this.m_oListener;
- };
- C_WebRequest.prototype.F_SetListener=function(_15b){
- this.m_oListener=_15b;
- };
- C_WebRequest.prototype.F_SetNewError=function(_15c,_15d,_15e){
- this.m_oError=new C_Error(_15c?_15c:"Web request failed.",_15d,_15e);
- };
- C_WebRequest.prototype.F_SetNewErrorRes=function(_15f,_160,_161){
- this.F_SetNewError(window["G_ResManager"]?G_ResManager.F_GetString(_15f):null,_160,_161);
- };
- C_WebRequest.prototype.F_SetError=function(_162){
- this.m_oError=_162;
- };
- C_WebRequest.prototype.F_GetError=function(){
- return this.m_oError;
- };
- C_WebRequest.prototype.F_SetRequestHeader=function(_163,_164){
- this.m_aRequestHeaders.push(_163,_164);
- };
- C_WebRequest.prototype.F_GetResponseHeader=function(_165){
- return this.m_oXmlHttp.getResponseHeader(_165);
- };
- C_WebRequest.prototype.F_SetRequestBody=function(_166){
- this.m_sRequestBody=_166;
- };
- C_WebRequest.prototype.F_GetRequestBody=function(){
- return this.m_sRequestBody;
- };
- C_WebRequest.prototype.F_Send=function(){
- if(G_HAL.M_oTestListener&&G_HAL.M_oTestListener.F_WebRequest_OnSend){
- G_HAL.M_oTestListener.F_WebRequest_OnSend(this);
- }
- if(this.m_oXmlHttp){
- this.m_oXmlHttp=null;
- }
- this.m_bCompleted=false;
- C_WebRequest.F_AddActiveRequest(this);
- this.m_oXmlHttp=((U_XML.M_bUseNativeXMLHttpRequest||G_BrowserInfo.M_bIsFirefox)&&window.XMLHttpRequest)?new XMLHttpRequest():new ActiveXObject(U_XML.K_sProgID_XMLHTTP);
- try{
- if(this.m_sUser||this.m_sPassword){
- this.m_oXmlHttp.open(this.m_sMethod,this.m_sUrl,this.m_bAsync,this.m_sUser,this.m_sPassword);
- }else{
- this.m_oXmlHttp.open(this.m_sMethod,this.m_sUrl,this.m_bAsync);
- }
- }
- catch(e){
- G_Debug.F_Print("Error opening C_WebRequest request");
- this.F_SetNewErrorRes("IDS_HAL_WEBREQUEST_SEND_ERROR","URL: "+this.m_sUrl);
- if(this.m_oListener&&this.m_oListener.F_Request_OnComplete){
- this.m_oListener.F_Request_OnComplete(this);
- }
- return;
- }
- if(G_BrowserInfo.M_bIsFirefox){
- var _167=this.m_sUrl.substr(this.m_sUrl.length-".dtd".length);
- if(_167==".dtd"){
- this.m_oXmlHttp.overrideMimeType("text/plain");
- }
- }
- for(var i=0;i<this.m_aRequestHeaders.length;i+=2){
- this.m_oXmlHttp.setRequestHeader(this.m_aRequestHeaders[i],this.m_aRequestHeaders[i+1]);
- }
- if(!this.m_bUseCache){
- this.m_oXmlHttp.setRequestHeader("If-Modified-Since","Thu, 01 Jan 1970 00:00:00 GMT");
- }
- this.m_oXmlHttp.onreadystatechange=this.f_onReadyStateChange.F_CreateMethodCallback(this);
- try{
- this.m_oXmlHttp.send(this.m_sRequestBody?this.m_sRequestBody:"");
- }
- catch(e){
- G_Debug.F_Print("Error sending C_WebRequest request");
- this.F_SetNewErrorRes("IDS_HAL_WEBREQUEST_SEND_ERROR");
- if(this.m_oListener&&this.m_oListener.F_Request_OnComplete){
- this.m_oListener.F_Request_OnComplete(this);
- }
- }
- };
- C_WebRequest.prototype.f_onReadyStateChange=function(){
- if(!this.m_bAborted&&(this.m_oXmlHttp.readyState==4)){
- C_WebRequest.F_RemoveActiveRequest(this);
- this.m_bCompleted=true;
- this.m_oXmlHttp.onreadystatechange=U_DOM.F_EmptyFunction;
- if(!this.F_IsSuccessStatus()){
- var _168=window["G_ResManager"]?G_ResManager.F_GetOptionalString("IDS_HAL_WEBREQUEST_ERROR"):null;
- var _169=this.F_GetStatus()+" - "+this.F_GetStatusText()+"\n"+"URL: "+this.F_GetUrl();
- var _16a=this.F_GetResponseText();
- if(_16a){
- _169+="\n\nResponse Text:\n"+_16a;
- }
- G_HAL.F_VerifyDependencies("C_Error");
- this.F_SetNewError(_168,_169,"");
- }
- if(!this.F_IsReadyToProcess()){
- return;
- }
- this.F_ProcessResponse();
- if(this.m_oListener&&this.m_oListener.F_Request_OnComplete){
- this.m_oListener.F_Request_OnComplete(this);
- }
- }
- };
- C_WebRequest.prototype.F_ProcessResponse=function(){
- if(G_HAL.M_oTestListener&&G_HAL.M_oTestListener.F_WebRequest_OnProcessResponse){
- G_HAL.M_oTestListener.F_WebRequest_OnProcessResponse(this);
- }
- if(this.m_oError){
- G_Debug.F_Print(this.m_oError.F_GetErrorSummary()+"\n"+this.m_oError.F_GetErrorDetails());
- }
- };
- C_WebRequest.prototype.F_IsReadyToProcess=function(){
- return true;
- };
- C_WebRequest.prototype.F_Abort=function(){
- this.m_bAborted=true;
- C_WebRequest.F_RemoveActiveRequest(this);
- if(this.m_oXmlHttp){
- this.m_oXmlHttp.abort();
- delete this.m_oXmlHttp;
- }
- if(!this.m_bCompleted&&this.m_oListener&&this.m_oListener.F_Request_OnAborted){
- this.m_bCompleted=true;
- this.m_oListener.F_Request_OnAborted(this);
- }
- };
- C_WebRequest.prototype.F_IsSuccessStatus=function(){
- var _16b=this.F_GetStatus();
- return ((_16b>=200)&&(_16b<300));
- };
- C_WebRequest.prototype.F_GetStatus=function(){
- return U_DOM.F_GetPropertyInTryCatch(this.m_oXmlHttp,"status");
- };
- C_WebRequest.prototype.F_GetStatusText=function(){
- return U_DOM.F_GetPropertyInTryCatch(this.m_oXmlHttp,"statusText");
- };
- C_WebRequest.prototype.F_GetUrl=function(){
- return this.m_sUrl;
- };
- C_WebRequest.prototype.F_GetResponseText=function(){
- return this.m_oXmlHttp.responseText;
- };
- C_WebRequest.prototype.F_SetCaching=function(_16c){
- this.m_bUseCache=_16c;
- };
- C_WebRequest.prototype.F_SetContext=function(_16d){
- this.m_vContext=_16d;
- };
- C_WebRequest.prototype.F_GetContext=function(){
- return this.m_vContext;
- };
- C_WebRequest.m_aActiveRequests=[];
- C_WebRequest.F_AbortActiveRequests=function(){
- for(var i=0;i<this.m_aActiveRequests.length;i++){
- this.m_aActiveRequests[i].F_Abort();
- }
- this.m_aActiveRequests.F_Clear();
- };
- C_WebRequest.F_AddActiveRequest=function(_16e){
- this.m_aActiveRequests.push(_16e);
- };
- C_WebRequest.F_RemoveActiveRequest=function(_16f){
- this.m_aActiveRequests.F_RemoveItem(_16f);
- };
- function C_SoapRequest(_170,_171,_172,_173){
- this.F_ConstructBaseClass(_170,"POST",_171);
- this.F_SetRequestHeader("Content-Type","text/xml; charset=utf-8");
- if(_172){
- this.F_SetSoapAction(_172);
- }
- if(_173){
- this.F_SetRequestBody(_173);
- }
- };
- C_SoapRequest.F_Extends(C_WebRequest);
- C_SoapRequest.prototype.F_IsSuccessStatus=function(){
- return ((this.F_GetStatus()==500)||C_SoapRequest.superClass.F_IsSuccessStatus.call(this));
- };
- C_SoapRequest.prototype.F_SetSoapAction=function(_174){
- var i=this.m_aRequestHeaders.indexOf("SOAPAction");
- if(i!=-1){
- this.m_aRequestHeaders.splice(i,2);
- }
- this.F_SetRequestHeader("SOAPAction",_174);
- };
- var U_XML={};
- U_XML.K_iNODE_ELEMENT=1;
- U_XML.K_iNODE_ATTRIBUTE=2;
- U_XML.K_iNODE_TEXT=3;
- U_XML.K_iNODE_CDATA_SECTION=4;
- U_XML.K_iNODE_ENTITY_REFERENCE=5;
- U_XML.K_iNODE_ENTITY=6;
- U_XML.K_iNODE_PROCESSING_INSTRUCTION=7;
- U_XML.K_iNODE_COMMENT=8;
- U_XML.K_iNODE_DOCUMENT=9;
- U_XML.K_iNODE_DOCUMENT_TYPE=10;
- U_XML.K_iNODE_DOCUMENT_FRAGMENT=11;
- U_XML.K_iNODE_NOTATION=12;
- U_XML.K_sProgID_DOMDocument="MSXML2.DOMDocument.3.0";
- U_XML.K_sProgID_XMLHTTP="MSXML2.XMLHTTP.3.0";
- U_XML.F_SetXml60=function(){
- this.K_sProgID_DOMDocument="Msxml2.DOMDocument.6.0";
- this.K_sProgID_XMLHTTP="Msxml2.XMLHTTP.6.0";
- };
- U_XML.M_bUseNativeXMLHttpRequest=true;
- U_XML.F_RemoveXmlProcessingInstruction=function(_175){
- return _175.replace(/^<\?xml.*?\?>/i,"");
- };
- U_XML.F_CreateDocument=function(){
- var d=G_BrowserInfo.M_bIsIE?new ActiveXObject(this.K_sProgID_DOMDocument):document.implementation.createDocument("","",null);
- d.async=false;
- d.validateOnParse=false;
- d.setProperty("SelectionLanguage","XPath");
- return d;
- };
- U_XML.F_XML_OnParseError=function(d){
- var _176=d.parseError;
- G_Debug.F_Print("XML Parse Error");
- G_Debug.F_Print("---------------------------");
- G_Debug.F_Print(" reason: "+_176.reason);
- G_Debug.F_Print(" url: "+_176.url);
- G_Debug.F_Print(" line: "+_176.line);
- G_Debug.F_Print(" linepos: "+_176.linepos);
- G_Debug.F_Print(" srcText: "+_176.srcText);
- };
- U_XML.F_LoadDocument=function(_177,_178,_179,_17a){
- var d=this.F_CreateDocument();
- d.validateOnParse=(_179!=false);
- d.preserveWhiteSpace=(_17a==true);
- try{
- if(!d.load(_178)){
- _177=_177?_177:this;
- _177.F_XML_OnParseError(d);
- return null;
- }
- }
- catch(e){
- _177=_177?_177:this;
- _177.F_XML_OnParseError(d);
- return null;
- }
- return d;
- };
- U_XML.F_LoadString=function(_17b,_17c,_17d,_17e){
- var d=null;
- var _17f=false;
- try{
- if(G_BrowserInfo.M_bIsIE){
- d=this.F_CreateDocument();
- d.validateOnParse=(_17d!=false);
- d.preserveWhiteSpace=(_17e==true);
- _17f=d.loadXML(_17c);
- }else{
- d=(new DOMParser()).parseFromString(_17c,"text/xml");
- _17f=(d.parseError.errorCode==0);
- }
- if(!_17f){
- _17b=_17b?_17b:this;
- _17b.F_XML_OnParseError(d);
- this.F_AlertInvalidUtf8Bom(_17c);
- return null;
- }
- }
- catch(e){
- _17b=_17b?_17b:this;
- _17b.F_XML_OnParseError(d);
- this.F_AlertInvalidUtf8Bom(_17c);
- return null;
- }
- return d;
- };
- U_XML.F_LoadStringWithDTD=function(_180,_181,_182,_183,_184){
- var d=U_XML.F_LoadString(_180,(_182?_182+_181:_181),_183,_184);
- if(d&&!G_BrowserInfo.M_bIsIE){
- d.rawDTD=_182;
- }
- return d;
- };
- U_XML.F_CreateElementNS=function(d,_185,_186){
- return G_BrowserInfo.M_bIsIE?d.createNode(this.K_iNODE_ELEMENT,_186,_185):d.createElementNS(_185,_186);
- };
- U_XML.F_CreateAttributeNS=function(d,_187,_188){
- return G_BrowserInfo.M_bIsIE?d.createNode(this.K_iNODE_ATTRIBUTE,_188,_187):d.createAttributeNS(_187,_188);
- };
- U_XML.F_ImportNode=function(d,n,_189){
- if(G_BrowserInfo.M_bIsIE||(n.ownerDocument==d)){
- return n.cloneNode(_189!==false);
- }
- var _18a=d.documentElement?d.documentElement:d;
- if(!d.doctype){
- var _18b=d.importNode(n,_189!==false);
- _18b=_18a.appendChild(_18b);
- _18b=_18a.removeChild(_18b);
- return _18b;
- }
- if(n.ownerDocument.doctype&&(n.ownerDocument.doctype.xml==d.doctype.xml)){
- var _18b=d.importNode(n,_189!==false);
- _18b=_18a.appendChild(_18b);
- _18b=_18a.removeChild(_18b);
- return _18b;
- }
- var _18c=this.F_LoadString(null,d.doctype.xml+n.xml);
- var _18b=d.importNode(_18c.documentElement,_189!==false);
- _18b=_18a.appendChild(_18b);
- _18b=_18a.removeChild(_18b);
- return _18b;
- };
- U_XML.F_GetUniqueId=function(d,_18d){
- var i=1;
- var _18e=_18d;
- while(d.nodeFromID(_18e)){
- _18e=_18d+i++;
- }
- return _18e;
- };
- U_XML.F_GiveNodeUniqueId=function(d,n,_18f){
- if(!_18f){
- _18f=n.nodeName;
- }
- n.setAttribute("id",this.F_GetUniqueId(d,_18f));
- return n;
- };
- U_XML.F_IndexOf=function(nl,n){
- var _190=nl.length;
- for(var i=0;i<_190;++i){
- if(nl.item(i)==n){
- return i;
- }
- }
- return -1;
- };
- U_XML.F_GetIndex=function(n){
- return this.F_IndexOf(n.parentNode.selectNodes("*"),n);
- };
- U_XML.F_RemoveNode=function(_191,_192){
- var n=_191.selectSingleNode(_192);
- if(n){
- n.parentNode.removeChild(n);
- }
- return n;
- };
- U_XML.F_RemoveNodeAndEmptyParent=function(_193,_194){
- var n=_193.selectSingleNode(_194);
- if(n){
- var _195=n.parentNode;
- _195.removeChild(n);
- if(!_195.selectSingleNode("*")){
- _195.parentNode.removeChild(_195);
- }
- }
- return n;
- };
- U_XML.F_RemoveNodes=function(_196,_197){
- var nl=_196.selectNodes(_197);
- var _198=nl.length;
- for(var i=0;i<_198;++i){
- var n=nl.item(i);
- n.parentNode.removeChild(n);
- }
- return nl;
- };
- U_XML.F_RemoveNodesInArray=function(_199){
- var _19a=_199.length;
- for(var i=0;i<_19a;i++){
- var n=_199[i];
- var _19b=n.parentNode;
- if(_19b){
- _19b.removeChild(n);
- }
- }
- };
- U_XML.F_AppendArray=function(n,_19c){
- var _19d=_19c.length;
- for(var i=0;i<_19d;++i){
- n.appendChild(_19c[i]);
- }
- };
- U_XML.F_AppendNodeList=function(n,nl){
- var _19e=nl.length;
- for(var i=0;i<_19e;++i){
- n.appendChild(nl.item(i));
- }
- };
- U_XML.F_AppendNodeListToArray=function(a,nl){
- if(!a){
- a=[];
- }
- var _19f=nl.length;
- for(var i=0;i<_19f;++i){
- a.push(nl.item(i));
- }
- return a;
- };
- U_XML.F_AppendValues=function(a,nl){
- if(!a){
- a=[];
- }
- var _1a0=nl.length;
- for(var i=0;i<_1a0;++i){
- var n=nl.item(i);
- a.push((n.nodeType==this.K_iNODE_ATTRIBUTE)?n.value:n.nodeValue);
- }
- return a;
- };
- U_XML.F_AppendValuesToObject=function(o,nl){
- if(!o){
- o={};
- }
- var _1a1=nl.length;
- for(var i=0;i<_1a1;++i){
- var n=nl.item(i);
- o[(n.nodeType==this.K_iNODE_ATTRIBUTE)?n.value:n.nodeValue]=true;
- }
- return o;
- };
- U_XML.F_AppendUniqueValues=function(a,nl){
- if(!a){
- a=[];
- }
- var _1a2=nl.length;
- for(var i=0;i<_1a2;++i){
- var n=nl.item(i);
- a.F_PushUnique((n.nodeType==this.K_iNODE_ATTRIBUTE)?n.value:n.nodeValue);
- }
- return a;
- };
- U_XML.F_GetXPath=function(_1a3,_1a4){
- var _1a5="";
- for(;_1a4&&(_1a4!=_1a3);_1a4=_1a4.parentNode){
- _1a5="/"+_1a4.nodeName+"["+(this.F_IndexOf(_1a4.parentNode.selectNodes(_1a4.nodeName),_1a4)+1)+"]"+_1a5;
- }
- return (_1a4?("."+_1a5):"");
- };
- U_XML.F_GetNextSiblingElement=function(n){
- return n.selectSingleNode("following-sibling::*");
- };
- U_XML.F_GetPreviousSiblingElement=function(n){
- return n.selectSingleNode("preceding-sibling::*[1]");
- };
- U_XML.F_GetNextElementOfSequence=function(n,_1a6){
- if(_1a6){
- return this.F_SelectSingleNode(n,"following-sibling::",_1a6);
- }
- return n.selectSingleNode("following-sibling::"+n.nodeName);
- };
- U_XML.F_GetPreviousElementOfSequence=function(n,_1a7){
- if(_1a7){
- return this.F_SelectSingleNode(n,"preceding-sibling::",_1a7);
- }
- return n.selectSingleNode("preceding-sibling::"+n.nodeName+"[1]");
- };
- U_XML.F_GetUniqueValue=function(_1a8,_1a9,_1aa,_1ab,_1ac){
- var _1ad={};
- var _1ae=_1a8.length;
- for(var i=0;i<_1ae;++i){
- _1ad[_1a8.item(i).value]=true;
- }
- return this.f_getUniqueValue(_1ad,_1a9,_1aa,_1ab,_1ac);
- };
- U_XML.F_GetUniqueValueFromArray=function(_1af,_1b0,_1b1,_1b2,_1b3){
- var _1b4=_1af.F_CreateDictionary();
- return this.f_getUniqueValue(_1b4,_1b0,_1b1,_1b2,_1b3);
- };
- U_XML.f_getUniqueValue=function(_1b5,_1b6,_1b7,_1b8,_1b9){
- if((_1b9!=false)&&_1b6.match(/^(.*\D0*)(\d+)$/)){
- _1b6=RegExp.$1;
- _1b8=RegExp.$2;
- _1b7=true;
- }
- var i=_1b8?parseInt(_1b8):1;
- i=i<10000?i:1;
- var s=_1b6;
- if(_1b7){
- s+=i++;
- }
- for(;_1b5[s];i++){
- s=_1b6+i;
- }
- return s;
- };
- U_XML.F_GiveUniqueValue=function(n,_1ba,_1bb,_1bc,_1bd,_1be){
- n.setAttribute(_1ba,this.F_GetUniqueValue(_1bc,_1bb,_1bd,null,_1be));
- };
- U_XML.F_GiveUniqueName=function(n,_1bf,_1c0,_1c1,_1c2){
- this.F_GiveUniqueValue(n,"name",_1bf,_1c0,_1c1,_1c2);
- };
- U_XML.F_ReplaceNodeWithNodeList=function(n,nl){
- var _1c3=n.parentNode;
- var _1c4=nl.length;
- for(var i=0;i<_1c4;i++){
- _1c3.insertBefore(nl.item(i),n);
- }
- _1c3.removeChild(n);
- };
- U_XML.F_ReplaceNodeWithArray=function(n,a){
- var _1c5=n.parentNode;
- var _1c6=a.length;
- for(var i=0;i<_1c6;i++){
- _1c5.insertBefore(a[i],n);
- }
- _1c5.removeChild(n);
- };
- U_XML.F_SetNodeName=function(n,_1c7){
- if(n.nodeName==_1c7){
- return n;
- }
- var _1c8=n.ownerDocument.createElement(_1c7);
- U_XML.F_CopyAttributes(_1c8,n,null,true);
- U_XML.F_AppendNodeList(_1c8,U_XML.F_RemoveNodes(n,"*"));
- if(n.parentNode){
- n.parentNode.replaceChild(_1c8,n);
- }
- return _1c8;
- };
- U_XML.F_CopyAttributes=function(_1c9,_1ca,_1cb,_1cc,_1cd){
- var o=_1cb?_1cb.F_CreateDictionary():null;
- var nl=_1ca.selectNodes("@*");
- if(G_BrowserInfo.M_bIsFirefox){
- _1cc=false;
- }
- var _1ce=nl.length;
- for(var i=0;i<_1ce;++i){
- var _1cf=nl.item(i);
- var _1d0=_1cf.name;
- if(o&&!o[_1d0]){
- continue;
- }
- if(_1d0==_1cd){
- continue;
- }
- if(_1cc&&!U_XML.F_IsAttributeSpecified(_1ca,_1ca.attributes.getNamedItem(_1d0))){
- continue;
- }
- _1c9.setAttribute(_1d0,_1cf.value);
- }
- };
- U_XML.F_CopyAttribute=function(_1d1,_1d2,_1d3){
- var _1d4=_1d2.getAttribute(_1d3);
- if(_1d4!=null){
- _1d1.setAttribute(_1d3,_1d4);
- return true;
- }
- return false;
- };
- U_XML.F_ConstructFilter=function(_1d5,_1d6,_1d7,_1d8,_1d9,_1da){
- if(_1d7.length==0){
- return "";
- }
- var _1db=[];
- for(var i=0;i<_1d7.length;i++){
- var _1dc=_1d7[i];
- if(_1d9){
- _1db.push("translate("+_1d5+", 'ABCDEFGHIJKLMNOPQRSTUVWXYZ', 'abcdefghijklmnopqrstuvwxyz')"+_1d6+_1dc.toLowerCase().F_ToXPathString());
- }else{
- _1db.push(_1d5+_1d6+_1dc.F_ToXPathString());
- }
- }
- return "["+(_1da?"not(":"")+_1db.join(" "+_1d8+" ")+(_1da?")":"")+"]";
- };
- U_XML.F_ConstructInFilter=function(_1dd,_1de,_1df,_1e0){
- return this.F_ConstructFilter(_1dd,"=",_1de,"or",_1df,_1e0);
- };
- U_XML.F_ConstructAttributeFilter=function(_1e1,_1e2,_1e3,_1e4,_1e5,_1e6){
- return this.F_ConstructFilter("@"+_1e1,_1e2,_1e3,_1e4,_1e5,_1e6);
- };
- U_XML.F_ConstructUnion=function(_1e7,_1e8,_1e9){
- var a=[];
- if(_1e7){
- a.push(_1e7);
- }
- a.push("*[self::");
- a.push(_1e8.join(" | self::"));
- a.push("]");
- if(_1e9){
- a.push(_1e9);
- }
- return a.join("");
- };
- U_XML.F_SelectSingleNode=function(n,_1ea,_1eb,_1ec){
- return n.selectSingleNode(this.F_ConstructUnion(_1ea,_1eb,_1ec)+"[1]");
- };
- U_XML.F_SelectNodes=function(n,_1ed,_1ee,_1ef){
- return n.selectNodes(this.F_ConstructUnion(_1ed,_1ee,_1ef));
- };
- U_XML.F_GetAncestor=function(n,_1f0){
- return n.selectSingleNode("ancestor::"+_1f0+"[1]");
- };
- U_XML.F_GetAncestorEx=function(n,_1f1){
- return n.selectSingleNode("("+this.F_ConstructUnion("ancestor::",_1f1)+")[last()]");
- };
- U_XML.F_GetAncestorOrSelf=function(n,_1f2){
- return n?n.selectSingleNode("ancestor-or-self::"+_1f2+"[1]"):null;
- };
- U_XML.F_GetAncestorOrSelfEx=function(n,_1f3){
- return n?n.selectSingleNode("("+this.F_ConstructUnion("ancestor-or-self::",_1f3)+")[last()]"):null;
- };
- U_XML.F_GetAncestorOrSelfAttribute=function(n,_1f4){
- return n.selectSingleNode("ancestor-or-self::*[@"+_1f4+"][1]");
- };
- U_XML.F_IsAncestor=function(n,_1f5){
- for(var _1f6=n.parentNode;_1f6;_1f6=_1f6.parentNode){
- if(_1f6==_1f5){
- return true;
- }
- }
- return false;
- };
- U_XML.F_GetSpecifiedAttributeValue=function(_1f7,_1f8){
- var _1f9=_1f7.attributes.getNamedItem(_1f8);
- return (_1f9&&U_XML.F_IsAttributeSpecified(_1f7,_1f9))?_1f7.getAttribute(_1f8):null;
- };
- U_XML.F_SetAttributeString=function(n,_1fa){
- var a=_1fa.split(/\s+/g);
- var _1fb=a.length;
- for(var i=0;i<_1fb;i++){
- var _1fc=a[i].split("=");
- var _1fd=_1fc[1];
- n.setAttribute(_1fc[0],_1fd.substr(1,_1fd.length-2));
- }
- };
- U_XML.F_SetAttributes=function(a,_1fe,_1ff){
- var _200=a.length;
- for(var i=0;i<_200;i++){
- this.F_SetAttribute(a[i],_1fe,_1ff);
- }
- };
- U_XML.F_SetAttribute=function(n,_201,_202){
- n.removeAttribute(_201);
- if(n.getAttribute(_201)!=_202){
- n.setAttribute(_201,_202);
- }
- };
- U_XML.F_SetAttributeValues=function(nl,_203){
- var _204=nl.length;
- for(var i=0;i<_204;++i){
- nl.item(i).value=_203;
- }
- };
- U_XML.F_SetNodeAttributeValues=function(nl,_205,_206){
- var _207=nl.length;
- for(var i=0;i<_207;++i){
- nl.item(i).setAttribute(_205,_206);
- }
- };
- U_XML.F_RemoveAttribute=function(n,_208,_209){
- this.F_RemoveAttributeFromNodeList(n.selectNodes(_208+"[@"+_209+"]"),_209);
- };
- U_XML.F_RemoveAttributeFromNodeList=function(nl,_20a){
- var _20b=nl.length;
- for(var i=0;i<_20b;i++){
- nl.item(i).removeAttribute(_20a);
- }
- };
- U_XML.F_RemoveAttributes=function(a,_20c){
- var _20d=a.length;
- for(var i=0;i<_20d;i++){
- a[i].removeAttribute(_20c);
- }
- };
- U_XML.F_RemoveAllAttribute=function(n,_20e){
- this.F_RemoveAttributeFromNodeList(n.selectNodes("descendant-or-self::*[@"+_20e+"]"),_20e);
- };
- U_XML.F_GetNodeText=function(n){
- if(n){
- return n.nodeType==this.K_iNODE_ATTRIBUTE?n.value:n.text;
- }
- return "";
- };
- U_XML.F_GetCreateChild=function(n,_20f){
- var _210=n.selectSingleNode(_20f);
- if(_210){
- return _210;
- }
- return n.appendChild(n.ownerDocument.createElement(_20f));
- };
- U_XML.F_AppendChild=function(n,_211){
- return n.appendChild(n.ownerDocument.createElement(_211));
- };
- U_XML.F_InsertNodePath=function(_212,_213,_214,_215){
- var d=_212.ownerDocument;
- var a=_213.split("/");
- var _216=null;
- var _217=null;
- var _218=a.length;
- for(var i=0;i<_218;i++){
- var n=d.createElement(a[i]);
- if(i==0){
- _216=n;
- _212.insertBefore(n,_215?_215:null);
- }else{
- _217.appendChild(n);
- }
- _217=n;
- }
- return _214?_217:_216;
- };
- U_XML.F_GetCreateNodePath=function(_219,_21a,_21b,_21c){
- var d=_219.ownerDocument;
- var a=_21a.split("/");
- var _21d=null;
- var _21e=_219;
- var _21f=a.length;
- for(var i=0;i<_21f;i++){
- var _220=_21e.selectSingleNode(a[i]);
- _21e=_220||_21e.insertBefore(d.createElement(a[i]),(!_21d&&_21c)?_21c:null);
- if(!_21d){
- _21d=_21e;
- }
- }
- return _21b?_21e:_21d;
- };
- U_XML.F_HaveSameNodeName=function(_221){
- var _222=_221[0].nodeName;
- var _223=_221.length;
- for(var i=1;i<_223;i++){
- if(_221[i].nodeName!=_222){
- return false;
- }
- }
- return true;
- };
- U_XML.F_HaveSameParent=function(_224){
- var _225=_224[0].parentNode;
- var _226=_224.length;
- for(var i=1;i<_224.length;i++){
- if(_224[i].parentNode!=_225){
- return false;
- }
- }
- return true;
- };
- U_XML.F_SerializeNode=function(_227){
- if(G_BrowserInfo.M_bIsIE){
- return _227.xml;
- }
- if(_227.nodeType==U_XML.K_iNODE_DOCUMENT&&!_227.doctype){
- return _227.xml;
- }
- if(_227.nodeType==U_XML.K_iNODE_ELEMENT&&!_227.ownerDocument.doctype){
- return _227.xml;
- }
- return (new C_XmlSerializer(_227)).F_ToString();
- };
- U_XML.F_AlertInvalidUtf8Bom=function(_228){
- var i=_228.indexOf("\ufeff");
- if(i!=-1){
- G_HAL.F_AlertError("Found BOM at position "+i);
- }
- return (i!=-1);
- };
- U_XML.F_SerializeToHTML=function(n){
- var re=/<\s*(?!img|input|link|meta|area)([^\/\s]+)([^>]*)\/>/gi;
- return n.xml.replace(re,function($0,$1,$2){
- return "<"+$1+$2+"></"+$1+">";
- });
- };
- U_XML.F_SerializeNodeContentsToHTML=function(n){
- var _229=this.F_SerializeToHTML(n);
- return _229.replace(/^<[^>]*>|<\/[^>]*>$/g,"");
- };
- U_XML.F_CreateLookupByAttributeValue=function(v_nl,_22a){
- var _22b={};
- if(v_nl&&v_nl.length>0&&_22a){
- for(var i=0;i<v_nl.length;++i){
- var n=v_nl.item(i);
- var _22c=n.getAttribute(_22a);
- if(_22c){
- _22b[_22c]=n;
- }
- }
- }
- return _22b;
- };
- U_XML.F_IsAttributeSpecified=function(n,_22d){
- if(G_BrowserInfo.M_bIsIE){
- return _22d.specified;
- }
- var d=n.ownerDocument;
- if(d.doctype){
- var _22e=d.f_getHALDefaultAttributeLookup()[n.nodeName];
- return !(_22e&&_22e[_22d.name]&&(_22e[_22d.name]===_22d.value));
- }
- return true;
- };
|