c.require("yui.container");if((YAHOO.widget.Panel||0).prototype.init){YAHOO.widget.Panel.prototype.init=function(C,B){YAHOO.widget.Panel.superclass.init.call(this,C);this.beforeInitEvent.fire(YAHOO.widget.Panel);YAHOO.util.Dom.addClass(this.element,YAHOO.widget.Panel.CSS_PANEL);this.buildWrapper();if(B){this.cfg.applyConfig(B,true)}this.beforeRenderEvent.subscribe(function(){var E=this.cfg.getProperty("draggable");if(E){if(!this.header){this.setHeader("&#160;")}}},this,true);this.renderEvent.subscribe(function(){var E=this.cfg.getProperty("width");if(!E){this.cfg.setProperty("width",(this.element.offsetWidth+"px"))}});var D=this;var A=function(){this.blur()};this.beforeShowEvent.subscribe(function(){this.cfg.refireEvent("underlay")},this,true);this.initEvent.fire(YAHOO.widget.Panel)}}if((uic.factory.Calendar||0).init){uic.factory.Calendar._create=function(C){var R=C[0];var O=C[1];var E=C[2];var F=C[3];var L=new util.simpleDateFormat();for(var P=0;P<O.length;P++){var N=O[P].id;var H=$(N);var G=O[P].conf;if(O[P].datepicker){var I=O[P].datepicker}if(F){var J=document.createElement("iframe");J.src="javascript:false;";YAHOO.util.Dom.setStyle(J,"opacity","0");YAHOO.util.Dom.setStyle(J,"position","absolute");YAHOO.util.Dom.setStyle(J,"width",0);YAHOO.util.Dom.setStyle(J,"height",0);J.tabIndex=-1;H.insertBefore(J,H.firstChild);H.iFrame=J}G.WEEKDAYS_LONG=L.weekslong;G.MONTHS_LONG=L.monthlong;G.MONTHS_SHORT=L.monthshort;G.WEEKDAYS_1CHAR=L.weeksshort;G.WEEKDAYS_MEDIUM=L.weeksshort;G.WEEKDAYS_SHORT=L.weeksshort;var K=$(N);c.extend(K,new uic.uicObject());c.extend(K,new uic.Calendar());K.tag="Calendar";K.rendering=false;var B=K.getElementsByTagName("DIV")[0];B.id=N+"_container";var D=N+"_container_table";var A=new YAHOO.widget.CalendarGroup(D,B.id,G);var Q=null;var M=null;if(G._default==""){Q=new Date();M=uic.factory.Calendar.JD2YD(Q)}else{M=G._default;Q=uic.factory.Calendar.YD2JD(M)}A.select(M);if(uic.p.FRAMEWORK_SKIN_ROOT.indexOf("Default")==-1){A.cfg.setProperty("NAV_ARROW_LEFT",uic.p.FRAMEWORK_DOCUMENT_ROOT+uic.p.FRAMEWORK_SKIN_ROOT+"img/calendar/callt.gif");A.cfg.setProperty("NAV_ARROW_RIGHT",uic.p.FRAMEWORK_DOCUMENT_ROOT+uic.p.FRAMEWORK_SKIN_ROOT+"img/calendar/calrt.gif")}K.style.display="block";if(E==null||typeof E=="undefined"||E==true){K.rendering=true;A.render()}K.currentDate=Q;K.currentPage=A.cfg.getProperty("pagedate");K.pageNb=A.cfg.getProperty("pages");K.highlightDate=uic.factory.Calendar._highlightDate;K._yuiObject=A;K.positionAt=uic.factory.Calendar._positionAt}c.loadMng.initialized("Calendar",R)}}YAHOO.namespace("util");YAHOO.util.Cookie={_createCookieString:function(B,D,C,A){var F=YAHOO.lang;var E=encodeURIComponent(B)+"="+(C?encodeURIComponent(D):D);if(F.isObject(A)){if(A.expires instanceof Date){E+="; expires="+A.expires.toGMTString()}if(F.isString(A.path)&&A.path!=""){E+="; path="+A.path}if(F.isString(A.domain)&&A.domain!=""){E+="; domain="+A.domain}if(A.secure===true){E+="; secure"}}return E},_createCookieHashString:function(B){var D=YAHOO.lang;if(!D.isObject(B)){throw new TypeError("Cookie._createCookieHashString(): Argument must be an object.")}var C=new Array();for(var A in B){if(D.hasOwnProperty(B,A)&&!D.isFunction(B[A])&&!D.isUndefined(B[A])){C.push(encodeURIComponent(A)+"="+encodeURIComponent(String(B[A])))}}return C.join("&")},_parseCookieHash:function(E){var D=E.split("&");var F=null;var C=new Object();for(var B=0,A=D.length;B<A;B++){F=D[B].split("=");C[F[0]]=F[1]}return C},_parseCookieString:function(E){var C=new Object();if(YAHOO.lang.isString(E)&&E.length>0){if(/[^=]+=[^=;]?(?:; [^=]+=[^=]?)?/.test(E)){var G=E.split(/;\s/g);var F=null;var D=null;for(var B=0,A=G.length;B<A;B++){F=decodeURIComponent(G[B].match(/(.*)=/i)[1]);D=decodeURIComponent(G[B].substring(F.length+1));C[F]=D}}}return C},get:function(A,B){var D=YAHOO.lang;var C=this._parseCookieString(document.cookie);if(!D.isString(A)||A===""){throw new TypeError("Cookie.get(): Cookie name must be a non-empty string.")}if(D.isUndefined(C[A])){return null}if(!D.isFunction(B)){return C[A]}else{return B(C[A])}},getSub:function(A,C,B){var E=YAHOO.lang;var D=this.getSubs(A);if(D!==null){if(!E.isString(C)||C===""){throw new TypeError("Cookie.getSub(): Subcookie name must be a non-empty string.")}if(E.isUndefined(D[C])){return null}if(!E.isFunction(B)){return D[C]}else{return B(D[C])}}else{return null}},getSubs:function(A){return this.get(A,this._parseCookieHash)},remove:function(B,A){if(!YAHOO.lang.isString(B)||B===""){throw new TypeError("Cookie.remove(): Cookie name must be a non-empty string.")}A=A||{};A.expires=new Date(0);return this.set(B,"",A)},set:function(B,C,A){var E=YAHOO.lang;if(!E.isString(B)){throw new TypeError("Cookie.set(): Cookie name must be a string.")}if(E.isUndefined(C)){throw new TypeError("Cookie.set(): Value cannot be undefined.")}var D=this._createCookieString(B,C,false,A);document.cookie=D;return D},setSub:function(B,D,C,A){var F=YAHOO.lang;if(!F.isString(B)||B===""){throw new TypeError("Cookie.setSub(): Cookie name must be a non-empty string.")}if(!F.isString(D)||D===""){throw new TypeError("Cookie.setSub(): Subcookie name must be a non-empty string.")}if(F.isUndefined(C)){throw new TypeError("Cookie.setSub(): Subcookie value cannot be undefined.")}var E=this.getSubs(B);if(!F.isObject(E)){E=new Object()}E[D]=C;return this.setSubs(B,E,A)},setSubs:function(B,C,A){var E=YAHOO.lang;if(!E.isString(B)){throw new TypeError("Cookie.setSubs(): Cookie name must be a string.")}if(!E.isObject(C)){throw new TypeError("Cookie.setSubs(): Cookie value must be an object.")}var D=this._createCookieString(B,this._createCookieHashString(C),false,A);document.cookie=D;return D}};YAHOO.register("cookie",YAHOO.util.Cookie,{version:"2.5.0",build:"895"});MEB.eventBus=new YAHOO.util.CustomEvent("eventBus");a.namespace("MEB.errors");c.require("uic.Errors");MEB.errors.Manager=function(){};MEB.errors.Manager.prototype._checkIsNotEmptyDate=function(A){try{if(A.getValue()==""){return false}return true}catch(B){}};MEB.errors.Manager.prototype._checkValueOfDate=function(A,C){try{if(A.getDate().getTime()==C){return 0}else{if(A.getDate().getTime()<C){return -1}else{return 1}}}catch(B){}};MEB.errors.Manager.prototype._displayErrors=function(B){try{var A=uic.Check.getFormInputStatus($(B));var K=[];var G=MEB.utilities.i18n.translate("error","INVALID_FIELD");for(var F=0;F<A.length;F++){if(!A[F].status){var E={};var I=A[F].input.parentNode.getLabel();var D=typeof I.innerHTML!="undefined"?I.innerHTML:I;E.message=G+D;E.type="E";E.bind=A[F].input.id;K.push(E)}}$(MEB.errors.content).innerHTML="";var H=B.split("_");var J=H[0]+"_"+H[1];uic.factory.Errors.create(J,"clientError",$(MEB.errors.content),false,"","",K);jQuery("#"+MEB.errors.container).show()}catch(C){}};MEB.errors.Manager.prototype.checkDate=function(){try{if(arguments.length==1){return this._checkIsNotEmptyDate(arguments[0])}else{if(arguments.length==2){return this._checkValueOfDate(arguments[0],arguments[1])}}}catch(A){}};MEB.errors.Manager.prototype.checkForm=function(E){try{var D=true;var A=jQuery("#"+E+" input,#"+E+" select,#"+E+" textarea");for(var C=0;C<A.length;C++){if(!uic.Check.validate(A[C],true)){D=false}}if(!D){this._displayErrors(E)}return D}catch(B){}};MEB.errors.Manager.prototype.formIsOk=function(E){try{var D=uic.Check.getFormInputStatus($(E));var C=true;for(var B=0;B<D.length;B++){if(D[B].status==false){C=false}}return C}catch(A){}};MEB.errors.Manager.prototype.checkSelect=function(A,C){try{if(A.getValue()==C){return 0}else{if(A.getValue()<C){return -1}else{return 1}}}catch(B){}};MEB.errors.Manager.prototype.checkTextField=function(B){try{if(B.getValue()==""){return false}return true}catch(A){}};MEB.errors.Manager.prototype.isPositiveInteger=function(C){try{C=C.replace(/(^\s*)|(\s*$)/g,"");if((C==null)||(C.length==0)){return false}var F=C.charAt(0);var A=C.length;var G=null;var E=null;var B=true;for(E=0;E<A;E++){if(C.charAt(0)!="0"){B=false;break}}if(B==true){return false}for(E=0;E<A;E++){G=C.charAt(E);if(!((G>="0")&&(G<="9"))){return false}}return true}catch(D){}};MEB.errors.manager=new MEB.errors.Manager();c.require("aria");a.namespace("MEB.utilities");MEB.utilities.GoogleAnalytics=function(){this._loader=null;MEB.ga.conf={host:(("https:"==document.location.protocol)?"https://ssl.":"http://www."),scriptName:"ga"};MEB.ga.tracker=null};MEB.utilities.GoogleAnalytics.prototype.init=function(){try{this._loader=new YAHOO.util.YUILoader();this._loader.addModule({name:"g-analytics",type:"js",fullpath:MEB.ga.conf.host+"google-analytics.com/"+MEB.ga.conf.scriptName+".js",verifier:MEB.utilities.GoogleAnalytics.checkGA});this._loader.require("g-analytics");this._loader.insert(this._onGALoad.createDelegate(this))}catch(A){}};MEB.utilities.GoogleAnalytics.checkGA=function(A,C){try{if(typeof _gat!="undefined"){C()}else{setTimeout(function(){MEB.utilities.GoogleAnalytics.checkGA(A,C)},2000)}}catch(B){}};MEB.utilities.GoogleAnalytics.prototype._onGALoad=function(){try{MEB.ga.tracker=_gat._getTracker(MEB.ga.account);MEB.ga.tracker._initData();MEB.ga.tracker._setDomainName(".amadeus.net");if(typeof MEB.objects.air!="undefined"&&typeof MEB.objects.air.search!="undefined"&&typeof MEB.objects.air.search.availabities!="undefined"){MEB.objects.air.search.availabities._webTracking()}else{MEB.ga.tracker._trackPageview()}MEB.eventBus.fire({eventName:"onGALoaded",data:{}})}catch(A){}};MEB.utilities.GoogleAnalytics.prototype.webTracking=function(C){try{var D=window.location.href;for(var B in C){if(D.indexOf("?")<0){D+="?"}else{D+="&"}D+=B+"="+C[B]}MEB.ga.tracker._trackPageview(D)}catch(A){}};var googleAnalytics=new MEB.utilities.GoogleAnalytics();c.onLoad("init",googleAnalytics,googleAnalytics._section);(function(A){A.facebox=function(B){A.facebox.init();A.facebox.loading();A.isFunction(B)?B.call():A.facebox.reveal(B)};A.facebox.settings={loading_image:"/facebox/loading.gif",close_image:"/facebox/closelabel.gif",image_types:["png","jpg","jpeg","gif"],facebox_html:'  <div id="facebox" style="display:none;">     <div class="popup">       <table>         <tbody>             <td class="body">               <div class="content">               </div>               <div class="footer">                 <a href="#" class="close">                   Close                 </a>               </div>             </td>             <td class="b"/>           </tr>           <tr>             <td class="b" colspan="2" />           </tr>         </tbody>       </table>     </div>   </div>'};A.facebox.loading=function(){if(A("#facebox .loading").length==1){return true}A("#facebox .content").empty();A("#facebox .body").children().hide().end().append('<div class="loading"><img src="'+A.facebox.settings.loading_image+'"/></div>');var B=A.facebox.getPageScroll();A("#facebox").css({top:B[1]+(A.facebox.getPageHeight()/10),left:B[0]}).show();A(document).bind("keydown.facebox",function(C){if(C.keyCode==27){A.facebox.close()}})};A.facebox.reveal=function(C,B){if(B){A("#facebox .content").addClass(B)}A("#facebox .content").append(C);A("#facebox .loading").remove();A("#facebox .body").children().fadeIn("normal")};A.facebox.close=function(){A(document).unbind("keydown.facebox");A("#facebox").fadeOut(function(){A("#facebox .content").removeClass().addClass("content")});return false};A.fn.facebox=function(){A.facebox.init();var B=A.facebox.settings.image_types.join("|");B=new RegExp("."+B+"jQuery","i");function C(){A.facebox.loading(true);var D=this.rel.match(/facebox\[\.(\w+)\]/);if(D){D=D[1]}if(this.href.match(/#/)){var E=window.location.href.split("#")[0];var G=this.href.replace(E,"");A.facebox.reveal(A(G).clone().show(),D)}else{if(this.href.match(B)){var F=new Image();F.onload=function(){A.facebox.reveal('<div class="image"><img src="'+F.src+'" /></div>',D)};F.src=this.href}else{A.get(this.href,function(H){A.facebox.reveal(H,D)})}}return false}this.click(C);return this};A.facebox.init=function(){if(A.facebox.settings.inited){return true}else{A.facebox.settings.inited=true}A("body").append(A.facebox.settings.facebox_html);var B=[new Image(),new Image()];B[0].src=A.facebox.settings.close_image;B[1].src=A.facebox.settings.loading_image;A("#facebox").find(".b:first, .bl, .br, .tl, .tr").each(function(){B.push(new Image());B.slice(-1).src=A(this).css("background-image").replace(/url\((.+)\)/,"jQuery1")});A("#facebox .close").click(A.facebox.close);A("#facebox .close_image").attr("src",A.facebox.settings.close_image)};A.facebox.getPageScroll=function(){var C,B;if(self.pageYOffset){B=self.pageYOffset;C=self.pageXOffset}else{if(document.documentElement&&document.documentElement.scrollTop){B=document.documentElement.scrollTop;C=document.documentElement.scrollLeft}else{if(document.body){B=document.body.scrollTop;C=document.body.scrollLeft}}}return new Array(C,B)};A.facebox.getPageHeight=function(){var B;if(self.innerHeight){B=self.innerHeight}else{if(document.documentElement&&document.documentElement.clientHeight){B=document.documentElement.clientHeight}else{if(document.body){B=document.body.clientHeight}}}return B}})(jQuery);jQuery.fn.corner=function(F){function K(N){var N=parseInt(N).toString(16);return(N.length<2)?"0"+N:N}function D(O){for(;O&&O.nodeName.toLowerCase()!="html";O=O.parentNode){var N=jQuery.css(O,"backgroundColor");if(N.indexOf("rgb")>=0){rgb=N.match(/\d+/g);return"#"+K(rgb[0])+K(rgb[1])+K(rgb[2])}if(N&&N!="transparent"){return N}}return"#ffffff"}function M(N){switch(H){case"round":return Math.round(E*(1-Math.cos(Math.asin(N/E))));case"cool":return Math.round(E*(1+Math.cos(Math.asin(N/E))));case"sharp":return Math.round(E*(1-Math.cos(Math.acos(N/E))));case"bite":return Math.round(E*(Math.cos(Math.asin((E-N-1)/E))));case"slide":return Math.round(E*(Math.atan2(N,E/N)));case"jut":return Math.round(E*(Math.atan2(E,(E-N-1))));case"curl":return Math.round(E*(Math.atan(N)));case"tear":return Math.round(E*(Math.cos(N)));case"wicked":return Math.round(E*(Math.tan(N)));case"long":return Math.round(E*(Math.sqrt(N)));case"sculpt":return Math.round(E*(Math.log((E-N-1),E)));case"dog":return(N&1)?(N+1):E;case"dog2":return(N&2)?(N+1):E;case"dog3":return(N&3)?(N+1):E;case"fray":return(N%2)*E;case"notch":return E;case"bevel":return N+1}}F=(F||"").toLowerCase();var B=/keep/.test(F);var G=((F.match(/cc:(#[0-9a-f]+)/)||[])[1]);var J=((F.match(/sc:(#[0-9a-f]+)/)||[])[1]);var E=parseInt((F.match(/(\d+)px/)||[])[1])||10;var L=/round|bevel|notch|bite|cool|sharp|slide|jut|curl|tear|fray|wicked|sculpt|long|dog3|dog2|dog/;var H=((F.match(L)||["round"])[0]);var I={T:0,B:1};var A={TL:/top|tl/.test(F),TR:/top|tr/.test(F),BL:/bottom|bl/.test(F),BR:/bottom|br/.test(F)};if(!A.TL&&!A.TR&&!A.BL&&!A.BR){A={TL:1,TR:1,BL:1,BR:1}}var C=document.createElement("div");C.style.overflow="hidden";C.style.height="1px";C.style.backgroundColor=J||"transparent";C.style.borderStyle="solid";return this.each(function(R){var O={T:parseInt(jQuery.css(this,"paddingTop"))||0,R:parseInt(jQuery.css(this,"paddingRight"))||0,B:parseInt(jQuery.css(this,"paddingBottom"))||0,L:parseInt(jQuery.css(this,"paddingLeft"))||0};if(jQuery.browser.msie){this.style.zoom=1}if(!B){this.style.border="none"}C.style.borderColor=G||D(this.parentNode);var T=jQuery.curCSS(this,"height");for(var P in I){var U=I[P];C.style.borderStyle="none "+(A[P+"R"]?"solid":"none")+" none "+(A[P+"L"]?"solid":"none");var V=document.createElement("div");var N=V.style;U?this.appendChild(V):this.insertBefore(V,this.firstChild);if(U&&T!="auto"){if(jQuery.css(this,"position")=="static"){this.style.position="relative"}N.position="absolute";N.bottom=N.left=N.padding=N.margin="0";if(jQuery.browser.msie){N.setExpression("width","this.parentNode.offsetWidth")}else{N.width="100%"}}else{N.margin=!U?"-"+O.T+"px -"+O.R+"px "+(O.T-E)+"px -"+O.L+"px":(O.B-E)+"px -"+O.R+"px -"+O.B+"px -"+O.L+"px"}for(var Q=0;Q<E;Q++){var W=Math.max(0,M(Q));var S=C.cloneNode(false);S.style.borderWidth="0 "+(A[P+"R"]?W:0)+"px 0 "+(A[P+"L"]?W:0)+"px";U?V.appendChild(S):V.insertBefore(S,V.firstChild)}}})};jQuery.fn.hoverClass=function(A){return this.each(function(){jQuery(this).hover(function(){jQuery(this).addClass(A)},function(){jQuery(this).removeClass(A)})})};jQuery.fn.attachFocusBehavior=function(A){return this.each(function(){jQuery(this).focus(function(){jQuery(this).addClass(A)}).blur(function(){jQuery(this).removeClass(A)})})};jQuery.fn.removeDottedTabFocus=function(){return this.each(function(){jQuery(this).focus(function(){if(this.blur){this.blur()}})})};jQuery.extend(jQuery.expr[":"],{contains:"((a.firstChild && a.firstChild.nodeValue)||a.textContent||a.innerText||jQuery(a).text()||'').indexOf(m[3])>=0",nGt:"parseInt((a.firstChild && a.firstChild.nodeValue)||a.textContent||a.innerText||jQuery(a).text()||'0')>parseInt(m[3])",nLt:"parseInt((a.firstChild && a.firstChild.nodeValue)||a.textContent||a.innerText||jQuery(a).text()||'0')<parseInt(m[3])",nEq:"parseInt((a.firstChild && a.firstChild.nodeValue)||a.textContent||a.innerText||jQuery(a).text()||'0')==parseInt(m[3])"});jQuery.fn.extend({selectbox:function(A){return this.each(function(){new jQuery.SelectBox(this,A)})}});jQuery.SelectBox=function(S,D){var A=D||{};A.inputClass=A.inputClass||"selectbox";A.containerClass=A.containerClass||"selectbox-wrapper";A.hoverClass=A.hoverClass||"selected";A.debug=A.debug||false;var J=S.id;var E=-1;var C=false;var R=0;var Q=jQuery(S);var O=G(A);var B=L(A);Q.hide().before(B).before(O);P();B.click(function(){if(!C){O.toggle()}}).focus(function(){if(O.not(":visible")){C=true;O.show()}}).keydown(function(T){switch(T.keyCode){case 38:T.preventDefault();K(-1);break;case 40:T.preventDefault();K(1);break;case 13:T.preventDefault();F();H();break}}).blur(function(){if(O.is(":visible")&&R>0){if(A.debug){console.log("container visible and has focus")}}else{H()}});function H(){R=0;O.hide()}function P(){O.append(M()).hide();var T=B.width();O.width(T)}function G(U){var T=document.createElement("div");O=jQuery(T);O.attr("id",J+"_container");O.addClass(U.containerClass);return O}function L(U){var T=document.createElement("input");var V=jQuery(T);V.attr("id",J+"_input");V.attr("type","text");V.addClass(U.inputClass);V.attr("autocomplete","off");V.attr("readonly","readonly");V.attr("tabIndex",Q.attr("tabindex"));return V}function K(U){var T=jQuery("li",O);if(!T){return }E+=U;if(E<0){E=0}else{if(E>=T.size()){E=T.size()-1}}T.removeClass(A.hoverClass);jQuery(T[E]).addClass(A.hoverClass)}function F(V){var T=jQuery("li#"+V,O).get(0);if(A.debug){console.log("set current output : "+T.id)}var U=T.getAttribute("language");Q.val(U);B.val(jQuery(T).html());return true}function N(){return Q.val()}function I(){return B.val()}function M(){var U=new Array();var T=document.createElement("ul");Q.children("option").each(function(){var V=document.createElement("li");V.setAttribute("id",Q[0].id+"_"+jQuery(this).val().toLowerCase());V.setAttribute("language",jQuery(this).val());V.innerHTML=jQuery(this).html();jQuery(V).addClass(jQuery(this).val().toLowerCase());if(jQuery(this).is(":selected")){B.val(jQuery(this).html());jQuery(V).addClass(A.hoverClass)}T.appendChild(V);jQuery(V).mouseover(function(W){R=1;if(A.debug){console.log("out on : "+this.id)}jQuery(W.target,O).addClass(A.hoverClass)}).mouseout(function(W){R=-1;if(A.debug){console.log("out on : "+this.id)}jQuery(W.target,O).removeClass(A.hoverClass)}).click(function(W){if(A.debug){console.log("click on :"+this.id)}jQuery(this).addClass(A.hoverClass);F(this.id);H();if(typeof Q[0].onchange!="undefined"){Q[0].onchange()}})});return T}};(function(E){var I,H,G,D,F,J,C;jQuery.fn.cluetip=function(K){var L={width:275,height:"auto",cluezIndex:97,positionBy:"auto",topOffset:15,leftOffset:15,local:false,hideLocal:true,attribute:"rel",titleAttribute:"title",splitTitle:"",showTitle:true,cluetipClass:"default",hoverClass:"",waitImage:true,cursor:"help",arrows:false,dropShadow:true,dropShadowSteps:6,sticky:false,mouseOutClose:false,activation:"hover",closePosition:"top",closeText:"Close",truncate:0,fx:{open:"show",openSpeed:""},hoverIntent:{sensitivity:3,interval:50,timeout:0},onActivate:function(M){return true},onShow:function(M,N){},ajaxCache:true,ajaxProcess:function(M){M=jQuery(M).not("style, meta, link, script, title");return M},ajaxSettings:{dataType:"html"}};if(K&&K.ajaxSettings){jQuery.extend(L.ajaxSettings,K.ajaxSettings);delete K.ajaxSettings}if(K&&K.fx){jQuery.extend(L.fx,K.fx);delete K.fx}if(K&&K.hoverIntent){jQuery.extend(L.hoverIntent,K.hoverIntent);delete K.hoverIntent}jQuery.extend(L,K);return this.each(function(){var Y=false;var s=parseInt(L.cluezIndex,10)-1;var m=false;if(!I){H=jQuery('<div id="cluetip-inner"></div>');D=jQuery('<h3 id="cluetip-title"></h3>');G=jQuery('<div id="cluetip-outer"></div>').append(H).prepend(D);I=jQuery("<div></div>").attr({id:"cluetip"}).css({zIndex:L.cluezIndex}).append(G).append('<div id="cluetip-extra"></div>')[B](A).hide();jQuery('<div id="cluetip-waitimage"></div>').css({position:"absolute",zIndex:s-1}).insertBefore("#cluetip").hide();I.css({position:"absolute",zIndex:s});G.css({position:"relative",zIndex:s+1});F=jQuery('<div id="cluetip-arrows" class="cluetip-arrows"></div>').css({zIndex:s+1}).appendTo("#cluetip")}var r=(L.dropShadow)?+L.dropShadowSteps:0;if(!J){J=jQuery([]);for(var n=0;n<r;n++){J=J.add(jQuery("<div></div>").css({zIndex:s-n-1,opacity:0.1,top:1+n,left:1+n}))}J.css({position:"absolute",backgroundColor:"#000"}).prependTo(I)}var R=jQuery(this);var d=R.attr(L.attribute),P=L.cluetipClass;if(!d&&!L.splitTitle){return true}if(L.local&&L.hideLocal){jQuery(d+":first").hide()}var k=parseInt(L.topOffset,10),Q=parseInt(L.leftOffset,10);var e,S;var Z=isNaN(parseInt(L.height,10))?"auto":(/\D/g).test(L.height)?L.height:L.height+"px";var u,M,T,g,V;var q=parseInt(L.width,10)+parseInt(I.css("paddingLeft"))+parseInt(I.css("paddingRight"))+r;if(isNaN(q)){q=275}var p=this.offsetWidth;var j,U,h,W,b;var o;var N=(L.attribute!="title")?R.attr(L.titleAttribute):"";if(L.splitTitle){o=N.split(L.splitTitle);N=o.shift()}var l;var O=function(y){if(!L.onActivate(R)){return false}m=true;I.removeClass().css({width:L.width});if(d==R.attr("href")){R.css("cursor",L.cursor)}R.attr("title","");if(L.hoverClass){R.addClass(L.hoverClass)}M=T=R.offset().top;j=R.offset().left;W=y.pageX;V=y.pageY;if(R[0].tagName.toLowerCase()!="area"){u=jQuery(document).scrollTop();b=jQuery(window).width()}if(L.positionBy=="fixed"){U=p+j+Q;I.css({left:U})}else{U=(p>j&&j>q)||j+p+q+Q>b?j-q-Q:p+j+Q;if(R[0].tagName.toLowerCase()=="area"||L.positionBy=="mouse"||p+q>b){if(W+20+q>b){U=(W-q-Q)>=0?W-q-Q:W-(q/2)}else{U=W+Q}var w=U<0?y.pageY+k:y.pageY}I.css({left:(U>0&&L.positionBy!="bottomTop")?U:(W+(q/2)>b)?b/2-q/2:Math.max(W-(q/2),0)})}S=jQuery(window).height();if(o){for(var x=0;x<o.length;x++){if(x==0){H.html(o[x])}else{H.append('<div class="split-body">'+o[x]+"</div>")}}f(w)}else{if(!L.local&&d.indexOf("#")!=0){if(Y&&L.ajaxCache){H.html(Y);f(w)}else{var z=L.ajaxSettings;z.url=d;z.beforeSend=function(){G.children().empty();if(L.waitImage){jQuery("#cluetip-waitimage").css({top:V-10,left:parseInt(U+(q/2),10)}).show()}};z.error=function(){if(m){H.html("<i>sorry, the contents could not be loaded</i>")}};z.success=function(i){Y=L.ajaxProcess(i);if(m){H.html(Y)}};z.complete=function(){C=jQuery("#cluetip-inner img").length;if(C){jQuery("#cluetip-inner img").load(function(){C--;if(C<1){jQuery("#cluetip-waitimage").hide();if(m){f(w)}}})}else{jQuery("#cluetip-waitimage").hide();if(m){f(w)}}};jQuery.ajax(z)}}else{if(L.local){var AA=jQuery(d+":first");var v=jQuery.fn.wrapInner?AA.wrapInner("<div></div>").children().clone(true):AA.html();jQuery.fn.wrapInner?H.empty().append(v):H.html(v);f(w)}}}};var f=function(w){I.addClass("cluetip-"+P);if(L.truncate){var x=H.text().slice(0,L.truncate)+"...";H.html(x)}function i(){}N?D.show().html(N):(L.showTitle)?D.show().html("&nbsp;"):D.hide();if(L.sticky){var v=jQuery('<div id="cluetip-close"><a href="#">'+L.closeText+"</a></div>");(L.closePosition=="bottom")?v.appendTo(H):(L.closePosition=="title")?v.prependTo(D):v.prependTo(H);v.click(function(){X();return false});if(L.mouseOutClose){I.hover(function(){i()},function(){v.trigger("click")})}else{I.unbind("mouseout")}}var y="";G.css({overflow:Z=="auto"?"visible":"auto",height:Z});e=Z=="auto"?I.outerHeight():parseInt(Z,10);g=T;if(L.positionBy=="fixed"){g=T-L.dropShadowSteps+k}else{if((U<W&&Math.max(U,0)+q>W)||L.positionBy=="bottomTop"){if(T+e+k>u+S&&V-u>e+k){g=V-e-k;y="top"}else{g=V+k;y="bottom"}}else{if(T+e+k>u+S){g=(e>=S)?u:u+S-e-k}else{if(R.css("display")=="block"||R[0].tagName.toLowerCase()=="area"||L.positionBy=="mouse"){g=w-k}else{g=T-L.dropShadowSteps}}}}if(y==""){U<j?y="left":y="right"}I.css({top:g+"px"}).removeClass().addClass("clue-"+y+"-"+P).addClass(" cluetip-"+P);if(L.arrows){var z=(T-g-L.dropShadowSteps);F.css({top:(/(left|right)/.test(y)&&U>=0&&z>0)?z+"px":/(left|right)/.test(y)?0:""}).show()}else{F.hide()}J.hide();I.hide()[L.fx.open](L.fx.open!="show"&&L.fx.openSpeed);if(L.dropShadow){J.css({height:e,width:L.width}).show()}L.onShow(I,H)};var t=function(){m=false;jQuery("#cluetip-waitimage").hide();if(!L.sticky){X()}if(L.hoverClass){R.removeClass(L.hoverClass)}};var X=function(){G.parent().hide().removeClass().end().children().empty();if(N){R.attr("title",N)}R.css("cursor","");if(L.arrows){F.css({top:""})}};if(L.activation=="click"||L.activation=="toggle"){R.click(function(i){if(I.is(":hidden")){O(i)}else{t(i)}this.blur();return false})}else{R.click(function(){if(d==R.attr("href")){return false}});if(jQuery.fn.hoverIntent&&L.hoverIntent){R.hoverIntent({sensitivity:L.hoverIntent.sensitivity,interval:L.hoverIntent.interval,over:function(i){O(i)},timeout:L.hoverIntent.timeout,out:function(i){t(i)}})}else{R.hover(function(i){O(i)},function(i){t(i)})}}})};var B="appendTo",A="body";jQuery.cluetip={};jQuery.cluetip.setup=function(K){if(K&&K.insertionType&&(K.insertionType).match(/appendTo|prependTo|insertBefore|insertAfter/)){B=K.insertionType}if(K&&K.insertionElement){A=K.insertionElement}}})(jQuery);(function(A){A.blockUI=function(D,B,C){A.blockUI.impl.install(window,D,B,C)};A.blockUI.version=1.33;A.unblockUI=function(B){A.blockUI.impl.remove(window,B)};jQuery.fn.block=function(D,B,C){return this.each(function(){if(!this.$pos_checked){if(A.css(this,"position")=="static"){this.style.position="relative"}if(A.browser.msie){this.style.zoom=1}this.$pos_checked=1}A.blockUI.impl.install(this,D,B,C)})};jQuery.fn.unblock=function(B){return this.each(function(){A.blockUI.impl.remove(this,B)})};jQuery.fn.displayBox=function(K,L,I){var E=this[0];if(!E){return }var N=A(E);K=K||{};var M=N.width()||N.attr("width")||K.width||A.blockUI.defaults.displayBoxCSS.width;var J=N.height()||N.attr("height")||K.height||A.blockUI.defaults.displayBoxCSS.height;if(M[M.length-1]=="%"){var H=document.documentElement.clientWidth||document.body.clientWidth;M=parseInt(M)||100;M=(M*H)/100}if(J[J.length-1]=="%"){var F=document.documentElement.clientHeight||document.body.clientHeight;J=parseInt(J)||100;J=(J*F)/100}var G="-"+parseInt(M)/2+"px";var C="-"+parseInt(J)/2+"px";var D=navigator.userAgent.toLowerCase();var B={displayMode:L||1,noalpha:I&&/mac/.test(D)&&/firefox/.test(D)};A.blockUI.impl.install(window,E,{width:M,height:J,marginTop:C,marginLeft:G},B)};A.blockUI.defaults={pageMessage:" ",elementMessage:" ",overlayCSS:{backgroundColor:"#ccc",opacity:"0.4"},pageMessageCSS:{width:"0",margin:"-50px 0 0 -125px",top:"50%",left:"45%",textAlign:"center",color:"#000",backgroundColor:"#fff"},elementMessageCSS:{width:"250px",padding:"10px",textAlign:"center",backgroundColor:"#fff"},displayBoxCSS:{width:"400px",height:"400px",top:"50%",left:"50%"},ie6Stretch:1,allowTabToLeave:0,closeMessage:"Click to close",fadeOut:1,fadeTime:400};A.blockUI.impl={box:null,boxCallback:null,pageBlock:null,pageBlockEls:[],op8:window.opera&&window.opera.version()<9,ie6:A.browser.msie&&/MSIE 6.0/.test(navigator.userAgent),install:function(D,E,H,B){B=B||{};this.boxCallback=typeof B.displayMode=="function"?B.displayMode:null;this.box=B.displayMode?E:null;var J=(D==window);var O=this.op8||A.browser.mozilla&&/Linux/.test(navigator.platform);if(typeof B.alphaOverride!="undefined"){O=B.alphaOverride==0?1:0}if(J&&this.pageBlock){this.remove(window,{fadeOut:0})}if(E&&typeof E=="object"&&!E.jquery&&!E.nodeType){H=E;E=null}E=E?(E.nodeType?A(E):E):J?A.blockUI.defaults.pageMessage:A.blockUI.defaults.elementMessage;if(B.displayMode){var P=jQuery.extend({},A.blockUI.defaults.displayBoxCSS)}else{var P=jQuery.extend({},J?A.blockUI.defaults.pageMessageCSS:A.blockUI.defaults.elementMessageCSS)}H=jQuery.extend(P,H||{});var I=(A.browser.msie)?A('<iframe class="blockUI" style="z-index:1000;border:none;margin:0;padding:0;position:absolute;width:100%;height:100%;top:0;left:0" src="javascript:false;"></iframe>'):A('<div class="blockUI" style="display:none"></div>');var M=A('<div class="blockUI" style="z-index:1001;cursor:wait;border:none;margin:0;padding:0;width:100%;height:100%;top:0;left:0"></div>');var F=J?A('<div class="blockUI blockMsg" style="z-index:1002;cursor:wait;padding:0;position:fixed"></div>'):A('<div class="blockUI" style="display:none;z-index:1002;cursor:wait;position:absolute"></div>');M.css("position",J?"fixed":"absolute");if(E){F.css(H)}if(!O){M.css(A.blockUI.defaults.overlayCSS)}if(this.op8){M.css({width:""+D.clientWidth,height:""+D.clientHeight})}if(A.browser.msie){I.css("opacity","0.0")}A([I[0],M[0],F[0]]).appendTo(J?"body":D);var L=A.browser.msie&&(!A.boxModel||A("object,embed",J?null:D).length>0);if(this.ie6||L){if(J&&A.blockUI.defaults.ie6Stretch&&A.boxModel){A("html,body").css("height","100%")}if((this.ie6||!A.boxModel)&&!J){var N=this.sz(D,"borderTopWidth"),G=this.sz(D,"borderLeftWidth");var K=N?"(0 - "+N+")":0;var C=G?"(0 - "+G+")":0}A.each([I,M,F],function(Q,S){var R=S[0].style;R.position="absolute";if(Q<2){J?R.setExpression("height",'document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + "px"'):R.setExpression("height",'this.parentNode.offsetHeight + "px"');J?R.setExpression("width",'jQuery.boxModel && document.documentElement.clientWidth || document.body.clientWidth + "px"'):R.setExpression("width",'this.parentNode.offsetWidth + "px"');if(C){R.setExpression("left",C)}if(K){R.setExpression("top",K)}}else{if(J){R.setExpression("top",'(document.documentElement.clientHeight || document.body.clientHeight) / 2 - (this.offsetHeight / 2) + (blah = document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop) + "px"')}R.marginTop=0}})}if(B.displayMode){M.css("cursor","default").attr("title",A.blockUI.defaults.closeMessage);F.css("cursor","default");A([I[0],M[0],F[0]]).removeClass("blockUI").addClass("displayBox");A().click(A.blockUI.impl.boxHandler).bind("keypress",A.blockUI.impl.boxHandler)}else{this.bind(1,D)}F.append(E).show();if(E.jquery){E.show()}if(B.displayMode){return }if(J){this.pageBlock=F[0];this.pageBlockEls=A(":input:enabled:visible",this.pageBlock);setTimeout(this.focus,20)}else{this.center(F[0])}},remove:function(D,E){var F=A.extend({},A.blockUI.defaults,E);this.bind(0,D);var C=D==window;var B=C?A("body").children().filter(".blockUI"):A(".blockUI",D);if(C){this.pageBlock=this.pageBlockEls=null}if(F.fadeOut){B.fadeOut(F.fadeTime,function(){if(this.parentNode){this.parentNode.removeChild(this)}})}else{B.remove()}},boxRemove:function(B){A().unbind("click",A.blockUI.impl.boxHandler).unbind("keypress",A.blockUI.impl.boxHandler);if(this.boxCallback){this.boxCallback(this.box)}A("body .displayBox").hide().remove()},handler:function(E){if(E.keyCode&&E.keyCode==9){if(A.blockUI.impl.pageBlock&&!A.blockUI.defaults.allowTabToLeave){var D=A.blockUI.impl.pageBlockEls;var C=!E.shiftKey&&E.target==D[D.length-1];var B=E.shiftKey&&E.target==D[0];if(C||B){setTimeout(function(){A.blockUI.impl.focus(B)},10);return false}}}if(A(E.target).parents("div.blockMsg").length>0){return true}return A(E.target).parents().children().filter("div.blockUI").length==0},boxHandler:function(B){if((B.keyCode&&B.keyCode==27)||(B.type=="click"&&A(B.target).parents("div.blockMsg").length==0)){A.blockUI.impl.boxRemove()}return true},bind:function(B,E){var D=E==window;if(!B&&(D&&!this.pageBlock||!D&&!E.$blocked)){return }if(!D){E.$blocked=B}var C=A(E).find("a,:input");A.each(["mousedown","mouseup","keydown","keypress","click"],function(F,G){C[B?"bind":"unbind"](G,A.blockUI.impl.handler)})},focus:function(B){if(!A.blockUI.impl.pageBlockEls){return }var C=A.blockUI.impl.pageBlockEls[B===true?A.blockUI.impl.pageBlockEls.length-1:0];if(C){C.focus()}},center:function(E){var F=E.parentNode,D=E.style;var B=((F.offsetWidth-E.offsetWidth)/2)-this.sz(F,"borderLeftWidth");var C=((F.offsetHeight-E.offsetHeight)/2)-this.sz(F,"borderTopWidth");D.left=B>0?(B+"px"):"0";D.top=C>0?(C+"px"):"0"},sz:function(B,C){return parseInt(A.css(B,C))||0}}})(jQuery);jQuery.jPrintArea=function(A){try{var C=document.createElement("IFRAME");jQuery(C).css({position:"absolute",background:"#fff",width:"0",height:"0",border:"0",left:"-1500px",top:"-1500px"});jQuery("body").append(C);var H=null;if(C.contentDocument){H=C.contentDocument}else{if(C.contentWindow){H=C.contentWindow.document}else{if(C.document){H=C.document}else{alert("Error printing");return null}}}var J=jQuery('link[@rel="stylesheet"]');for(var D=0;D<J.length;D++){if(jQuery(J[D]).attr("media")=="print"){H.write('<link type="text/css" rel="stylesheet" href="'+J[D].href+'"></link>')}}var F=jQuery("div:hidden",A);jQuery(F).show();jQuery(F).prepend('<h2 class="print-details-title">Flight details</h2>');var E=jQuery(A).html();var G=jQuery("#header-wrapper",A).length>0?true:false;if(!G){E=jQuery("#header-wrapper").html()+E}var I=jQuery("#footer-wrapper",A).length>0?true:false;if(!G){E+=jQuery("#footer-wrapper").html()}H.write('<div class="'+jQuery(A).attr("class")+' print">'+E+"</div>");H.close();C.contentWindow.focus();C.contentWindow.print();jQuery("h2").remove(".print-details-title");jQuery(F).hide();jQuery("body").remove(C)}catch(B){}};var SlideShow=function(){this._settings={contentdivs:[],toclinks:[],topzindex:[],currentpage:1,prevpage:1};this._intervalId=0};SlideShow.prototype.init=function(C){try{for(var B in C){this._settings[B]=C[B]}if(jQuery("#"+this._settings.id).length>0){this._build()}}catch(A){}};SlideShow.prototype._build=function(){try{var H=this;jQuery("#"+this._settings.id+" div").each(function(J){if(jQuery(this).hasClass("contentdiv")){H._settings.contentdivs.push(this)}if(J==0){jQuery(this).show()}});var D=jQuery("#paginate-"+this._settings.id);var G="";var C=this._settings.toc;var A=this._settings.nextprev;if(typeof C=="string"&&C!="markup"||typeof C=="object"){for(var F=1;F<=this._settings.contentdivs.length;F++){G+='<a href="javascript:void(0);" id="'+this._settings.id+"_paginate_link"+F+'"class="toc">'+(typeof C=="string"?C.replace(/#increment/,F):C[F-1])+"</a> "}G=(A[0]!=""?'<a href="#prev" class="prev">'+A[0]+"</a> ":"")+G+(A[1]!=""?'<a href="#next" class="next">'+A[1]+"</a>":"");D.html(G)}var E=false;var I=0;jQuery("#paginate-"+this._settings.id+" a").each(function(J){if(jQuery(this).hasClass("toc")){if(!E){jQuery(this).addClass("selected");E=true}if(I>H._settings.contentdivs.length-1){jQuery(this).hide()}jQuery(this).attr("rel",++I);jQuery(this).click(function(){H._selectPage(jQuery(this).attr("rel"))});H._settings.toclinks.push(this)}else{if(jQuery(this).hasClass("prev")){jQuery(this).click(function(){H._nextPage(-1)})}else{if(jQuery(this).hasClass("next")){jQuery(this).click(function(){H._nextPage()})}}}});if(this._settings.autorotate[0]){this._intervalId=window.setInterval(this._nextPage.createDelegate(this,[1]),this._settings.autorotate[1])}}catch(B){}};SlideShow.prototype._nextPage=function(A){try{A=typeof A!="undefined"&&A!=null?parseInt(A):1;var B=(this._settings.currentpage+A)%(this._settings.contentdivs.length);if(B<1){B=(this._settings.contentdivs.length)-B}this._selectPage(B)}catch(C){}};SlideShow.prototype._selectPage=function(A){try{jQuery("#"+this._settings.id+"_paginate_link"+this._settings.currentpage).removeClass("selected");jQuery("#"+this._settings.id+"_paginate_link"+A).addClass("selected");jQuery(jQuery("#"+this._settings.id+" .contentdiv")[A-1]).css("z-index","1");jQuery(jQuery("#"+this._settings.id+" .contentdiv")[this._settings.currentpage-1]).css("z-index","2");jQuery(jQuery("#"+this._settings.id+" .contentdiv")[A-1]).show();jQuery(jQuery("#"+this._settings.id+" .contentdiv")[this._settings.currentpage-1]).animate({width:"hide"},"slow");this._settings.currentpage=parseInt(A)}catch(B){}};if(!Array.prototype.indexOf){Array.prototype.indexOf=function(B){var A=this.length;var C=Number(arguments[1])||0;C=(C<0)?Math.ceil(C):Math.floor(C);if(C<0){C+=A}for(;C<A;C++){if(C in this&&this[C]===B){return C}}return -1}}if(!Array.prototype.lastIndexOf){Array.prototype.lastIndexOf=function(B){var A=this.length;var C=Number(arguments[1]);if(isNaN(C)){C=A-1}else{C=(C<0)?Math.ceil(C):Math.floor(C);if(C<0){C+=A}else{if(C>=A){C=A-1}}}for(;C>-1;C--){if(C in this&&this[C]===B){return C}}return -1}}if(!Array.prototype.contains){Array.prototype.contains=function(A){var B=Number(arguments[1])||0;return this.indexOf(A,B)!=-1}}if(!Array.prototype.each){Array.prototype.each=function(B){var A=this.length;if(typeof B!="function"){throw new TypeError()}var D=arguments[1];for(var C=0;C<A;C++){if(C in this){B.call(D,this[C],C,this)}}}}if(!Array.prototype.every){Array.prototype.every=function(B){var A=this.length;if(typeof B!="function"){throw new TypeError()}var D=arguments[1];for(var C=0;C<A;C++){if(C in this&&!B.call(D,this[C],C,this)){return false}}return true}}if(!Array.prototype.extend){Array.prototype.add=function(C){for(var B=0,A=C.length;B<A;B++){this.push(C[B])}return this}}if(!Array.prototype.difference){Array.prototype.difference=function(D){var C=[];for(var B=0,A=this.length;B<A;B++){if(!D.hasValue(this[B])){C.push(this[B])}}return C}}if(!Array.prototype.filter){Array.prototype.filter=function(B){var A=this.length;if(typeof B!="function"){throw new TypeError()}var E=new Array();var D=arguments[1];for(var C=0;C<A;C++){if(C in this){var F=this[C];if(B.call(D,F,C,this)){E.push(F)}}}return E}}if(!Array.prototype.forEach){Array.prototype.forEach=Array.prototype.each}if(!Array.prototype.contains){Array.prototype.forEach=Array.prototype.each}if(!Array.prototype.include){Array.prototype.include=function(A){if(!this.hasValue(A)){this.push(A)}return this}}if(!Array.prototype.map){Array.prototype.map=function(B){var A=this.length;if(typeof B!="function"){throw new TypeError()}var E=new Array(A);var D=arguments[1];for(var C=0;C<A;C++){E[C]=B.call(D,this[C],C,this)}return E}}if(!Array.prototype.merge){Array.prototype.merge=function(C){for(var B=0,A=C.length;B<A;B++){this.include(C[B])}return this}}if(!Array.prototype.remove){Array.prototype.remove=function(C){var B=0;var A=this.length;while(B<A){if(this[B]===C){this.splice(B,1);A--}else{B++}}return this}}if(!Array.prototype.some){Array.prototype.some=function(B){var A=this.length;if(typeof B!="function"){throw new TypeError()}var D=arguments[1];for(var C=0;C<A;C++){if(C in this&&B.call(D,this[C],C,this)){return true}}return false}}if(!Function.prototype.createCallback){Function.prototype.createCallback=function(){var A=arguments;var B=this;return function(){return B.apply(window,A)}}}if(!Function.prototype.createDelegate){Function.prototype.createDelegate=function(C,B,A){var D=this;return function(){var F=B||arguments;if(A===true){F=Array.prototype.slice.call(arguments,0);F=F.concat(B)}else{if(typeof A=="number"){F=Array.prototype.slice.call(arguments,0);var E=[A,0].concat(B);Array.prototype.splice.apply(F,E)}}return D.apply(C||window,F)}}}if(!Function.prototype.defer){Function.prototype.defer=function(C,D,B,A){return setTimeout(this.createDelegate(D,B,A),C)}}if(!Function.prototype.createSequence){Function.prototype.createSequence=function(B,A){if(typeof B!="function"){return this}var C=this;return function(){var D=C.apply(this||window,arguments);B.apply(A||this||window,arguments);return D}}}a.namespace("MEB.keys");MEB.keys.codes={ENTER:13};MEB.keys.Manager=function(C,A,D){this._keyCode=C;this._callBack=D;for(var B=0;B<A.length;B++){YAHOO.util.Event.addListener($(A[B].id),"keypress",this._onKeyPressed,this,true)}};MEB.keys.Manager.prototype._onKeyPressed=function(A,C){var B=A.keyCode;if(B==C._keyCode){C._callBack()}};a.namespace("MEB.utilities");MEB.utilities.Modifiers=function(){};MEB.utilities.Modifiers.prototype.evaluate=function(str){try{var res=str;try{res=eval(str)}catch(exc){}return res}catch(exception){}};MEB.utilities.Modifiers.prototype.dayIndicator=function(E){try{var A=1000*60*60*24;var G=Math.floor(E.legs[0].dates.from.fullDate/A);var F=Math.floor(E.legs[E.legs.length-1].dates.to.fullDate/A);var D=F-G;var C="";if(D==1){C=MEB.utilities.i18n.translate("global","day").replace("{0}",D+"")}else{if(D>1){C=MEB.utilities.i18n.translate("global","days").replace("{0}",D+"")}}return C}catch(B){}};MEB.utilities.Modifiers.prototype.firstLetter=function(B){try{return B.substring(0,1).toUpperCase()||""}catch(A){}};MEB.utilities.Modifiers.prototype.substitute=function(){try{var str=arguments[0];for(var i=1;i<arguments.length;i++){var obj;try{obj=eval(arguments[i])}catch(exception){}obj=obj||arguments[i];if(typeof obj=="undefined"){obj=""}str=str.replace("{"+(i-1)+"}",obj)}return str}catch(exception){}};MEB.utilities.Modifiers.prototype.toHours=function(F,E){try{E=E||"h ";var D=parseInt(F,10)/60000;var C=Math.floor(D/60);var B=Math.floor(D-C*60);B=B<10?"0"+B:B;return C+E+B}catch(A){}};MEB.utilities.Modifiers.prototype.toPartOfDay=function(C){try{var A=parseInt(C);if(A>=0&&A<9){return"AM1"}else{if(A>=9&&A<12){return"AM2"}else{if(A>=12&&A<17){return"PM1"}else{if(A>=17&&A<21){return"PM2"}else{return"PM3"}}}}}catch(B){}};MEB.utilities.Modifiers.prototype.timeToStr=function(C){try{var B=parseInt(C);return MEB.date.formatter.format(MEB.date.format,new Date(B))}catch(A){}};MEB.utilities.Modifiers.prototype.toBestFareTime=function(C){try{var A=parseInt(C);if(A>=0&&A<12){return"m"}else{if(A>=12&&A<17){return"n"}else{if(A>=17&&A<24){return"e"}}}}catch(B){}};MEB.utilities.modifiers=new MEB.utilities.Modifiers();c.require("aria");a.namespace("MEB.utilities.sorter");MEB.utilities.sorter.QuickSort=function(){this._parent=null;this._data=[];this._length=0;this._comparator=null;this._desc=null};MEB.utilities.sorter.QuickSort.prototype.init=function(D,A,C){try{this._parent=$(D);this._data=$jq("#"+D+" "+A);this._length=this._data.length;this._comparator=C}catch(B){}};MEB.utilities.sorter.QuickSort.prototype._partition=function(G,B,A){try{var H=this._data[A];this._swap(A,B-1);var D=G;var C;for(var F=G;F<B-1;++F){C=this._comparator(this._data[F],H);C=this._desc?-1*C:C;if(C==-1||C===0){this._swap(D,F);++D}}this._swap(B-1,D);return D}catch(E){}};MEB.utilities.sorter.QuickSort.prototype._qSort=function(D,B){try{if(B-1>D){var A=D+Math.floor(Math.random()*(B-D));A=this._partition(D,B,A);this._qSort(D,A);this._qSort(A+1,B)}}catch(C){}};MEB.utilities.sorter.QuickSort.prototype._swap=function(D,A){try{var C=this._data[D];this._data[D]=this._data[A];this._data[A]=C}catch(B){}};MEB.utilities.sorter.QuickSort.prototype.sort=function(C){try{this._desc=C;if(this._length<=1){return }this._qSort(0,this._length);for(var B=0;B<this._data.length;B++){this._parent.appendChild($(this._data[B].getAttribute("linkTo")))}MEB.eventBus.fire({eventName:"onSortSucces",data:{}})}catch(A){MEB.eventBus.fire({eventName:"onSortError",data:{}})}};var TrimPath;(function(){if(TrimPath==null){TrimPath=new Object()}if(TrimPath.evalEx==null){TrimPath.evalEx=function(src){return eval(src)}}var UNDEFINED;if(Array.prototype.pop==null){Array.prototype.pop=function(){if(this.length===0){return UNDEFINED}return this[--this.length]}}if(Array.prototype.push==null){Array.prototype.push=function(){for(var i=0;i<arguments.length;++i){this[this.length]=arguments[i]}return this.length}}TrimPath.parseTemplate=function(tmplContent,optTmplName,optEtc){if(optEtc==null){optEtc=TrimPath.parseTemplate_etc}var funcSrc=parse(tmplContent,optTmplName,optEtc);var func=TrimPath.evalEx(funcSrc,optTmplName,1);if(func!=null){return new optEtc.Template(optTmplName,tmplContent,funcSrc,func,optEtc)}return null};try{String.prototype.process=function(context,optFlags){var template=TrimPath.parseTemplate(this,null);if(template!=null){return template.process(context,optFlags)}return this}}catch(e){}TrimPath.parseTemplate_etc={};TrimPath.parseTemplate_etc.statementTag="forelse|for|if|elseif|else|var|macro";TrimPath.parseTemplate_etc.statementDef={"if":{delta:1,prefix:"if (",suffix:") {",paramMin:1},"else":{delta:0,prefix:"} else {"},elseif:{delta:0,prefix:"} else if (",suffix:") {",paramDefault:"true"},"/if":{delta:-1,prefix:"}"},"for":{delta:1,paramMin:3,prefixFunc:function(stmtParts,state,tmplName,etc){if(stmtParts[2]!="in"){throw new etc.ParseError(tmplName,state.line,"bad for loop statement: "+stmtParts.join(" "))}var iterVar=stmtParts[1];var listVar="__LIST__"+iterVar;return["var ",listVar," = ",stmtParts[3],";","var __LENGTH_STACK__;","if (typeof(__LENGTH_STACK__) == 'undefined' || !__LENGTH_STACK__.length) __LENGTH_STACK__ = new Array();","__LENGTH_STACK__[__LENGTH_STACK__.length] = 0;","if ((",listVar,") != null) { ","var ",iterVar,"_ct = 0;","for (var ",iterVar,"_index in ",listVar,") { ",iterVar,"_ct++;","if (typeof(",listVar,"[",iterVar,"_index]) == 'function') {continue;}","__LENGTH_STACK__[__LENGTH_STACK__.length - 1]++;","var ",iterVar," = ",listVar,"[",iterVar,"_index];"].join("")}},forelse:{delta:0,prefix:"} } if (__LENGTH_STACK__[__LENGTH_STACK__.length - 1] == 0) { if (",suffix:") {",paramDefault:"true"},"/for":{delta:-1,prefix:"} }; delete __LENGTH_STACK__[__LENGTH_STACK__.length - 1];"},"var":{delta:0,prefix:"var ",suffix:";"},macro:{delta:1,prefixFunc:function(stmtParts,state,tmplName,etc){var macroName=stmtParts[1].split("(")[0];return["var ",macroName," = function",stmtParts.slice(1).join(" ").substring(macroName.length),"{ var _OUT_arr = []; var _OUT = { write: function(m) { if (m) _OUT_arr.push(m); } }; "].join("")}},"/macro":{delta:-1,prefix:" return _OUT_arr.join(''); };"}};TrimPath.parseTemplate_etc.modifierDef={eat:function(v){return""},escape:function(s){return String(s).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")},capitalize:function(s){return String(s).toUpperCase()},"default":function(s,d){return s!=null?s:d}};TrimPath.parseTemplate_etc.modifierDef.h=TrimPath.parseTemplate_etc.modifierDef.escape;TrimPath.parseTemplate_etc.Template=function(tmplName,tmplContent,funcSrc,func,etc){this.process=function(context,flags){if(context==null){context={}}if(context._MODIFIERS==null){context._MODIFIERS={}}if(context.defined==null){context.defined=function(str){return(context[str]!=undefined)}}for(var k in etc.modifierDef){if(context._MODIFIERS[k]==null){context._MODIFIERS[k]=etc.modifierDef[k]}}if(flags==null){flags={}}var resultArr=[];var resultOut={write:function(m){resultArr.push(m)}};try{func(resultOut,context,flags)}catch(e){if(flags.throwExceptions==true){throw e}var result=new String(resultArr.join("")+"[ERROR: "+e.toString()+(e.message?"; "+e.message:"")+"]");result.exception=e;return result}return resultArr.join("")};this.name=tmplName;this.source=tmplContent;this.sourceFunc=funcSrc;this.toString=function(){return"TrimPath.Template ["+tmplName+"]"}};TrimPath.parseTemplate_etc.ParseError=function(name,line,message){this.name=name;this.line=line;this.message=message};TrimPath.parseTemplate_etc.ParseError.prototype.toString=function(){return("TrimPath template ParseError in "+this.name+": line "+this.line+", "+this.message)};var parse=function(body,tmplName,etc){body=cleanWhiteSpace(body);var funcText=["var TrimPath_Template_TEMP = function(_OUT, _CONTEXT, _FLAGS) { with (_CONTEXT) {"];var state={stack:[],line:1};var endStmtPrev=-1;while(endStmtPrev+1<body.length){var begStmt=endStmtPrev;begStmt=body.indexOf("{",begStmt+1);while(begStmt>=0){var endStmt=body.indexOf("}",begStmt+1);var stmt=body.substring(begStmt,endStmt);var blockrx=stmt.match(/^\{(cdata|minify|eval)/);if(blockrx){var blockType=blockrx[1];var blockMarkerBeg=begStmt+blockType.length+1;var blockMarkerEnd=body.indexOf("}",blockMarkerBeg);if(blockMarkerEnd>=0){var blockMarker;if(blockMarkerEnd-blockMarkerBeg<=0){blockMarker="{/"+blockType+"}"}else{blockMarker=body.substring(blockMarkerBeg+1,blockMarkerEnd)}var blockEnd=body.indexOf(blockMarker,blockMarkerEnd+1);if(blockEnd>=0){emitSectionText(body.substring(endStmtPrev+1,begStmt),funcText);var blockText=body.substring(blockMarkerEnd+1,blockEnd);if(blockType=="cdata"){emitText(blockText,funcText)}else{if(blockType=="minify"){emitText(scrubWhiteSpace(blockText),funcText)}else{if(blockType=="eval"){if(blockText!=null&&blockText.length>0){funcText.push("_OUT.write( (function() { "+blockText+" })() );")}}}}begStmt=endStmtPrev=blockEnd+blockMarker.length-1}}}else{if(body.charAt(begStmt-1)!="$"&&body.charAt(begStmt-1)!="\\"){var offset=(body.charAt(begStmt+1)=="/"?2:1);if(body.substring(begStmt+offset,begStmt+10+offset).search(TrimPath.parseTemplate_etc.statementTag)==0){break}}}begStmt=body.indexOf("{",begStmt+1)}if(begStmt<0){break}var endStmt=body.indexOf("}",begStmt+1);if(endStmt<0){break}emitSectionText(body.substring(endStmtPrev+1,begStmt),funcText);emitStatement(body.substring(begStmt,endStmt+1),state,funcText,tmplName,etc);endStmtPrev=endStmt}emitSectionText(body.substring(endStmtPrev+1),funcText);if(state.stack.length!=0){throw new etc.ParseError(tmplName,state.line,"unclosed, unmatched statement(s): "+state.stack.join(","))}funcText.push("}}; TrimPath_Template_TEMP");return funcText.join("")};var emitStatement=function(stmtStr,state,funcText,tmplName,etc){var parts=stmtStr.slice(1,-1).split(" ");var stmt=etc.statementDef[parts[0]];if(stmt==null){emitSectionText(stmtStr,funcText);return }if(stmt.delta<0){if(state.stack.length<=0){throw new etc.ParseError(tmplName,state.line,"close tag does not match any previous statement: "+stmtStr)}state.stack.pop()}if(stmt.delta>0){state.stack.push(stmtStr)}if(stmt.paramMin!=null&&stmt.paramMin>=parts.length){throw new etc.ParseError(tmplName,state.line,"statement needs more parameters: "+stmtStr)}if(stmt.prefixFunc!=null){funcText.push(stmt.prefixFunc(parts,state,tmplName,etc))}else{funcText.push(stmt.prefix)}if(stmt.suffix!=null){if(parts.length<=1){if(stmt.paramDefault!=null){funcText.push(stmt.paramDefault)}}else{for(var i=1;i<parts.length;i++){if(i>1){funcText.push(" ")}funcText.push(parts[i])}}funcText.push(stmt.suffix)}};var emitSectionText=function(text,funcText){if(text.length<=0){return }var nlPrefix=0;var nlSuffix=text.length-1;while(nlPrefix<text.length&&(text.charAt(nlPrefix)=="\n")){nlPrefix++}while(nlSuffix>=0&&(text.charAt(nlSuffix)==" "||text.charAt(nlSuffix)=="\t")){nlSuffix--}if(nlSuffix<nlPrefix){nlSuffix=nlPrefix}if(nlPrefix>0){funcText.push('if (_FLAGS.keepWhitespace == true) _OUT.write("');var s=text.substring(0,nlPrefix).replace("\n","\\n");if(s.charAt(s.length-1)=="\n"){s=s.substring(0,s.length-1)}funcText.push(s);funcText.push('");')}var lines=text.substring(nlPrefix,nlSuffix+1).split("\n");for(var i=0;i<lines.length;i++){emitSectionTextLine(lines[i],funcText);if(i<lines.length-1){funcText.push('_OUT.write("\\n");\n')}}if(nlSuffix+1<text.length){funcText.push('if (_FLAGS.keepWhitespace == true) _OUT.write("');var s=text.substring(nlSuffix+1).replace("\n","\\n");if(s.charAt(s.length-1)=="\n"){s=s.substring(0,s.length-1)}funcText.push(s);funcText.push('");')}};var emitSectionTextLine=function(line,funcText){var endMarkPrev="}";var endExprPrev=-1;while(endExprPrev+endMarkPrev.length<line.length){var begMark="%{",endMark="}";var begExpr=line.indexOf(begMark,endExprPrev+endMarkPrev.length);if(begExpr<0){break}if(line.charAt(begExpr+2)=="%"){begMark="%{%";endMark="%}"}var endExpr=line.indexOf(endMark,begExpr+begMark.length);if(endExpr<0){break}emitText(line.substring(endExprPrev+endMarkPrev.length,begExpr),funcText);var exprArr=line.substring(begExpr+begMark.length,endExpr).replace(/\|\|/g,"#@@#").split("|");for(var k in exprArr){if(exprArr[k].replace){exprArr[k]=exprArr[k].replace(/#@@#/g,"||")}}funcText.push("_OUT.write(");emitExpression(exprArr,exprArr.length-1,funcText);funcText.push(");");endExprPrev=endExpr;endMarkPrev=endMark}emitText(line.substring(endExprPrev+endMarkPrev.length),funcText)};var emitText=function(text,funcText){if(text==null||text.length<=0){return }text=text.replace(/\\/g,"\\\\");text=text.replace(/\n/g,"\\n");text=text.replace(/"/g,'\\"');funcText.push('_OUT.write("');funcText.push(text);funcText.push('");')};var emitExpression=function(exprArr,index,funcText){var expr=exprArr[index];if(index<=0){funcText.push(expr);return }var parts=expr.split(":");funcText.push('_MODIFIERS["');funcText.push(parts[0]);funcText.push('"](');emitExpression(exprArr,index-1,funcText);if(parts.length>1){funcText.push(",");funcText.push(parts[1])}funcText.push(")")};var cleanWhiteSpace=function(result){result=result.replace(/\t/g,"    ");result=result.replace(/\r\n/g,"\n");result=result.replace(/\r/g,"\n");result=result.replace(/^(\s*\S*(\s+\S+)*)\s*$/,"$1");return result};var scrubWhiteSpace=function(result){result=result.replace(/^\s+/g,"");result=result.replace(/\s+$/g,"");result=result.replace(/\s+/g," ");result=result.replace(/^(\s*\S*(\s+\S+)*)\s*$/,"$1");return result};TrimPath.parseDOMTemplate=function(elementId,optDocument,optEtc){if(optDocument==null){optDocument=document}var element=optDocument.getElementById(elementId);var content=element.value;if(content==null){content=element.innerHTML}content=content.replace(/&lt;/g,"<").replace(/&gt;/g,">");return TrimPath.parseTemplate(content,elementId,optEtc)};TrimPath.processDOMTemplate=function(elementId,context,optFlags,optDocument,optEtc){return TrimPath.parseDOMTemplate(elementId,optDocument,optEtc).process(context,optFlags)}})();c.require("aria");a.namespace("MEB.utilities");MEB.utilities.VEWrapper=function(B,A){this._vMap=null;this._id=B;this._intervalID=null;if(A){this._center=A.center||new VELatLong(0,0);this._zoom=A.zoom||"1";this._style=A.style||"r";this._isFixed=A.isFixed||false;this._mode=A.mode||VEMapMode.Mode2D;this._dashBoardSize=A.dashBoardSize||VEDashboardSize.Normal;this._showMiniMap=A.showMiniMap||false;this._miniMapPosition=A.miniMapPosition||"rhbc";this._automaticLink=A.automaticLink||false;this._lineDisplay=A.lineDisplay.toLowerCase()||"straight";this._gcAccuracy=A.gcAccuracy||50;this._navCollapsed=A.navCollapsed||true}this._locations={};this._shapes={};this._key=null;this._shapeIcon=null;this._lineColor=null;this._defaultLayer=null;this._automaticLayer=null;this._geoRssLayer=null;this._toogleCtrlID="MSVE_navAction_toggleGlyphWrapper"};MEB.utilities.VEWrapper.prototype.init=function(){try{MEB.utilities.VEWrapper.safeLoader(this._safeInit.createDelegate(this))}catch(A){}};MEB.utilities.VEWrapper.safeLoader=function(B){try{if(!B()){setTimeout(function(){MEB.utilities.VEWrapper.safeLoader(B)},1000)}}catch(A){}};MEB.utilities.VEWrapper.prototype._safeInit=function(){var B=null;try{this._vMap=new VEMap(this._id);if(this._dashBoardSize){this._vMap.SetDashboardSize(this._dashBoardSize)}this._vMap.LoadMap(this._center,this._zoom,this._style,this._isFixed,this._mode);this._defaultLayer=new VEShapeLayer();this._vMap.AddShapeLayer(this._defaultLayer);if(this._showMiniMap){this.showMiniMap(this._miniMapPosition)}B=true;this._vMap.AttachEvent("onresize",this.setBestView.createDelegate(this))}catch(A){B=false}finally{return B}};MEB.utilities.VEWrapper.prototype._linkPlots=function(){try{if(this._automaticLayer!=null){this._vMap.DeleteShapeLayer(this._automaticLayer);this._automaticLayer=null}this._automaticLayer=new VEShapeLayer();this._vMap.AddShapeLayer(this._automaticLayer);var E=0;var A=0;var D=new Array();for(var C in this._locations){D[A++]=this._locations[C].LatLong;E++;if(E%2==0&&E>0){this.addLine(D,true,new VEColor(255,102,0,0.5),this._automaticLayer);A=0}}}catch(B){}};MEB.utilities.VEWrapper.prototype.addLine=function(D,E,A,C){try{E=E||false;C=C||this._defaultLayer;if(this._lineDisplay=="curve"){D=this._greatCircle(D)}var F=this._indexOfBreak(D);if(F==-1){return this._addLine(D,E,A,C)}else{return[this._addLine(D.slice(0,F),E,A,C),this._addLine(D.slice(F),E,A,C)]}}catch(B){}};MEB.utilities.VEWrapper.prototype._addLine=function(E,F,B,D){try{var A=new VEShape(VEShapeType.Polyline,E);D.AddShape(A);if(B){A.SetLineColor(B)}if(F){A.HideIcon()}}catch(C){}};MEB.utilities.VEWrapper.prototype.addPushpin=function(A,E,D){try{D=D||this._defaultLayer;var B=new VEShape(VEShapeType.Pushpin,A.LatLong);if(this._shapeIcon){B.SetCustomIcon(this._shapeIcon)}B.SetTitle(E.title);B.SetDescription(E.description);D.AddShape(B);return B}catch(C){}};MEB.utilities.VEWrapper.prototype.center=function(){try{this._vMap.SetCenterAndZoom(new VELatLong(0,0),0)}catch(A){}};MEB.utilities.VEWrapper.prototype._greatCircle=function(points){var res=[];try{with(Math){var lat1=points[0].Latitude*(PI/180);var lon1=points[0].Longitude*(PI/180);var lat2=points[1].Latitude*(PI/180);var lon2=points[1].Longitude*(PI/180);var d=2*asin(sqrt(pow((sin((lat1-lat2)/2)),2)+cos(lat1)*cos(lat2)*pow((sin((lon1-lon2)/2)),2)));var bearing=atan2(sin(lon1-lon2)*cos(lat2),cos(lat1)*sin(lat2)-sin(lat1)*cos(lat2)*cos(lon1-lon2))/-(PI/180);bearing=bearing<0?360+bearing:bearing;for(var n=0;n<this._gcAccuracy+1;n++){var f=(1/this._gcAccuracy)*n;f=f.toFixed(6);var A=sin((1-f)*d)/sin(d);var B=sin(f*d)/sin(d);var x=A*cos(lat1)*cos(lon1)+B*cos(lat2)*cos(lon2);var y=A*cos(lat1)*sin(lon1)+B*cos(lat2)*sin(lon2);var z=A*sin(lat1)+B*sin(lat2);var latN=atan2(z,sqrt(pow(x,2)+pow(y,2)));var lonN=atan2(y,x);var p=new VELatLong(latN/(PI/180),lonN/(PI/180));res.push(p)}}return res}catch(exception){}};MEB.utilities.VEWrapper.prototype.hideMiniMap=function(){try{this._vMap.HideMiniMap()}catch(A){}};MEB.utilities.VEWrapper.prototype._indexOfBreak=function(D){try{var C=Math.floor(D[0].Longitude);var E;for(var B=1;B<D.length;B++){E=Math.floor(D[B].Longitude);if((C>175&&E<-175)||(C<-175&&E>175)){return B}C=E}return -1}catch(A){}};MEB.utilities.VEWrapper.prototype.loadGeoRss=function(C){try{this._geoRssLayer=new VEShapeLayer();var B=new VEShapeSourceSpecification(VEDataType.GeoRSS,C,this._geoRssLayer);this._vMap.ImportShapeLayerData(B,function(){})}catch(A){}};MEB.utilities.VEWrapper.prototype.plot=function(B,D,C){try{this._key=B;var F=this;var E=function(H,G,K,J,I){F._onPlot(H,G,K,J,I);if(C){C(H,G,K,J,I)}};this._vMap.Find(null,D,null,null,0,20,false,false,false,false,E)}catch(A){}};MEB.utilities.VEWrapper.prototype._onPlot=function(){try{if(arguments[2].length>0){if(this._locations[this._key]!=null){this._vMap.DeleteShape(this._shapes[this._key]);this._shapes[this._key]=null;this._locations[this._key]=null}this._locations[this._key]=arguments[2][0];this._shapes[this._key]=this.addPushpin(this._locations[this._key],{title:arguments[2][0].Name,description:""});if(this._automaticLink){this._linkPlots()}}}catch(A){}};MEB.utilities.VEWrapper.prototype.reset=function(){try{this._vMap.DeleteShapeLayer(this._defaultLayer);this._defaultLayer=null;this._defaultLayer=new VEShapeLayer();this._vMap.AddShapeLayer(this._defaultLayer);this._shapes={};this._locations={};if(this._automaticLayer!=null){this._vMap.DeleteShapeLayer(this._automaticLayer);this._automaticLayer=null}this.center()}catch(A){}};MEB.utilities.VEWrapper.prototype.resize=function(C,A){try{this._vMap.Resize(C,A)}catch(B){}};MEB.utilities.VEWrapper.prototype.setBestView=function(){try{this._vMap.SetMapView(this._defaultLayer.GetBoundingRectangle())}catch(A){}};MEB.utilities.VEWrapper.prototype.setShapeIcon=function(A){this._shapeIcon=A};MEB.utilities.VEWrapper.prototype.showMiniMap=function(A){this._miniMapPosition=A||"rhbc";try{if(this._vMap.GetMapMode()==2){this._vMap.SetMapMode(VEMapMode.Mode2D)}var E={width:150,height:150};var D={width:parseInt(YAHOO.util.Dom.getStyle($(this._id),"width")),height:parseInt(YAHOO.util.Dom.getStyle($(this._id),"height"))};var B=null;if(this._miniMapPosition.toLowerCase()=="rhtc"){B={x:D.width-E.width,y:0}}else{if(this._miniMapPosition.toLowerCase()=="rhbc"){B={x:D.width-E.width,y:D.height-E.height}}else{if(this._miniMapPosition.toLowerCase()=="lhtc"){B={x:0,y:0}}else{if(this._miniMapPosition.toLowerCase()=="lhbc"){B={x:0,y:D.height-E.height}}}}}this._vMap.ShowMiniMap(B.x,B.y)}catch(C){}};MEB.utilities.VEWrapper.prototype.toggleNavigation=function(){try{if(this._intervalID!=null){window.clearInterval(this._intervalID)}document.getElementById(this._toogleCtrlID).click()}catch(A){this._intervalID=window.setInterval(this.toggleNavigation.createDelegate(this),500)}};c.require("aria");c.require("yui.container");a.namespace("MEB.popups");MEB.popups.PopupManager=function(){this._section="poma";this._waitingPopup=null;this._flightDetailsPopup=null;this._default_skin_name="default_skin";this._air_skin_name="air_skin";this._hotel_skin_name="hotel_skin";this._car_skin_name="car_skin";this._current_skin=null;this._plnext_skinning_behavior={hots:"hotel",cars:"car",flis:"air"};this._deactivate_meb_popup=false};MEB.popups.PopupManager.prototype.init=function(){try{this._initWaitingPopup();this._initFlyingDetailsPopup();MEB.eventBus.subscribe(this._onEvent.createDelegate(this))}catch(A){}};MEB.popups.PopupManager.prototype._initWaitingPopup=function(){try{this._waitingPopup=new YAHOO.widget.Panel("loading_message",{fixedcenter:true,close:false,draggable:false,modal:true,zindex:999,visible:false,underlay:"none"});this._waitingPopup.setHeader("<div class='tl'></div><div class='content'></div><div class='tr'></div>");var D='<div id="processing_block_wrapper"><div id="processing_block">';D+='<div id="search_icon"></div>';D+='<div id="popup_content_container"><div id="popup_content_position"><div id="popup_content">';D+='<h1 id="text_message">';D+=MEB.utilities.i18n.global.translate("info","PROCESSING");D+="</h1>";D+='<div id="throbber" ></div>';D+="</div></div></div></div></div>";this._waitingPopup.setBody(D);this._waitingPopup.setFooter("<div class='bl'></div><div class='content'></div><div class='br'></div>");this._waitingPopup.render(document.body);this._setSkin(this._default_skin_name);if((typeof (WDSWaitingImage)=="undefined")||(WDSWaitingImage==null)){}else{var B=$jq("body")[0].id;var A=this._plnext_skinning_behavior[B];if(A!=null){this._deactivate_meb_popup=false;if(A=="hotel"){this._setSkin(this._hotel_skin_name)}else{if(A=="car"){this._setSkin(this._car_skin_name)}else{if(A=="air"){this._setSkin(this._air_skin_name)}}}}else{this._deactivate_meb_popup=true}WDSWaitingImage=this}}catch(C){}};MEB.popups.PopupManager.prototype._initFlyingDetailsPopup=function(){try{this._flightDetailsPopup=new YAHOO.widget.Panel("popup_details",{width:"540px",top:"20px",fixedcenter:true,close:false,draggable:false,modal:true,zindex:999,visible:false,underlay:"none"})}catch(A){}};MEB.popups.PopupManager.prototype.pleaseWait=function(){try{if(this._deactivate_meb_popup==false){this._waitingPopup.show()}}catch(A){}};MEB.popups.PopupManager.prototype._delayedSubmit=function(B){try{setTimeout(function(){$jq("#"+B).submit()},50)}catch(A){}};MEB.popups.PopupManager.prototype._displayAndSubmit=function(B){try{this._waitingPopup.show();this._delayedSubmit(B)}catch(A){}};MEB.popups.PopupManager.prototype.displayAirPopupAndSubmit=function(B){try{this._setSkin(this._air_skin_name);this._displayAndSubmit(B)}catch(A){}};MEB.popups.PopupManager.prototype.displayHotelPopupAndSubmit=function(B){try{this._setSkin(this._hotel_skin_name);this._displayAndSubmit(B)}catch(A){}};MEB.popups.PopupManager.prototype.displayCarPopupAndSubmit=function(B){try{this._setSkin(this._car_skin_name);this._displayAndSubmit(B)}catch(A){}};MEB.popups.PopupManager.prototype._setSkin=function(B){try{if(this._current_skin!=null){$jq("#loading_message .bd").removeClass(this._current_skin)}$jq("#loading_message .bd").addClass(B);this._current_skin=B}catch(A){}};MEB.popups.PopupManager.prototype._showFlightDetails=function(C){try{this._flightDetailsPopup.setBody($jq("#"+C.getAttribute("linkTo")).html());this._flightDetailsPopup.setFooter('<a id="flight_details_close" href="javascript:void(0)" title="'+MEB.utilities.i18n.contact_us.translate("markup","FATAL_ERROR_CLOSE_LINK")+'" class="close">'+MEB.utilities.i18n.contact_us.translate("markup","FATAL_ERROR_CLOSE_LINK")+"</a>");this._flightDetailsPopup.render(document.body);var A=$jq("#popup_details .bd");A[0].style.overflowX="hidden";if(A.height()>550){A.height(550);A[0].style.overflowY="scroll"}this._flightDetailsPopup.show();var D=this;$jq("#flight_details_close").click(function(){D._flightDetailsPopup.hide();A.height("auto");A[0].style.overflowY="visible"})}catch(B){}};MEB.popups.PopupManager.prototype._onEvent=function(A,D){try{var C=D[0];switch(C.eventName){case"onShowFlightDetails":this._showFlightDetails(C.data.link);break;default:break}}catch(B){}};MEB.popups.waiting=new MEB.popups.PopupManager();c.onLoad("init",MEB.popups.waiting);(function(){if(typeof YAHOO_config==="undefined"){YAHOO_config={}}var B={info:{base:"http://yui.yahooapis.com/2.3.1/build/",skin:{defaultSkin:"sam",base:"assets/skins/",path:"skin.css",rollup:3},moduleInfo:{animation:{type:"js",path:"animation/animation-min.js",requires:["dom","event"]},autocomplete:{type:"js",path:"autocomplete/autocomplete-min.js",requires:["dom","event"],optional:["connection","animation"],skinnable:true},button:{type:"js",path:"button/button-beta-min.js",requires:["element"],optional:["menu"],skinnable:true},calendar:{type:"js",path:"calendar/calendar-min.js",requires:["event","dom"],skinnable:true},colorpicker:{type:"js",path:"colorpicker/colorpicker-beta-min.js",requires:["slider","element"],optional:["animation"],skinnable:true},connection:{type:"js",path:"connection/connection-min.js",requires:["event"]},container:{type:"js",path:"container/container-min.js",requires:["dom","event"],optional:["dragdrop","animation"],supersedes:["containercore"],skinnable:true},containercore:{type:"js",path:"container/container_core-min.js",requires:["dom","event"]},datasource:{type:"js",path:"datasource/datasource-beta-min.js",requires:["event"],optional:["connection"]},datatable:{type:"js",path:"datatable/datatable-beta-min.js",requires:["element","datasource"],optional:["calendar","dragdrop"],skinnable:true},dom:{type:"js",path:"dom/dom-min.js",requires:["yahoo"]},dragdrop:{type:"js",path:"dragdrop/dragdrop-min.js",requires:["dom","event"]},editor:{type:"js",path:"editor/editor-beta-min.js",requires:["menu","element","button"],optional:["animation","dragdrop"],skinnable:true},element:{type:"js",path:"element/element-beta-min.js",requires:["dom","event"]},event:{type:"js",path:"event/event-min.js",requires:["yahoo"]},fonts:{type:"css",path:"fonts/fonts-min.css"},grids:{type:"css",path:"grids/grids-min.css",requires:["fonts"],optional:["reset"]},history:{type:"js",path:"history/history-beta-min.js",requires:["event"]},imageloader:{type:"js",path:"imageloader/imageloader-experimental-min.js",requires:["event","dom"]},logger:{type:"js",path:"logger/logger-min.js",requires:["event","dom"],optional:["dragdrop"],skinnable:true},menu:{type:"js",path:"menu/menu-min.js",requires:["containercore"],skinnable:true},reset:{type:"css",path:"reset/reset-min.css"},"reset-fonts-grids":{type:"css",path:"reset-fonts-grids/reset-fonts-grids.css",supersedes:["reset","fonts","grids"]},slider:{type:"js",path:"slider/slider-min.js",requires:["dragdrop"],optional:["animation"]},tabview:{type:"js",path:"tabview/tabview-min.js",requires:["element"],optional:["connection"],skinnable:true},treeview:{type:"js",path:"treeview/treeview-min.js",requires:["event"],skinnable:true},utilities:{type:"js",path:"utilities/utilities.js",supersedes:["yahoo","event","dragdrop","animation","dom","connection","element","yahoo-dom-event"],rollup:6},yahoo:{type:"js",path:"yahoo/yahoo-min.js"},"yahoo-dom-event":{type:"js",path:"yahoo-dom-event/yahoo-dom-event.js",supersedes:["yahoo","event","dom"],rollup:3},yuiloader:{type:"js",path:"yuiloader/yuiloader-beta-min.js"},yuitest:{type:"js",path:"yuitest/yuitest-beta-min.js",requires:["logger"],skinnable:true}}},ObjectUtil:{appendArray:function(A,F){if(F){for(var E=0;E<F.length;E=E+1){A[F[E]]=true}}},clone:function(E){var A={};for(var F in E){A[F]=E[F]}return A},merge:function(){var A={},H=arguments,F,G;for(F=0;F<H.length;F=F+1){for(G in H[F]){A[G]=H[F][G]}}return A},keys:function(A,G){var H=[],F;for(F in A){H.push(F)}return H}},ArrayUtil:{appendArray:function(A,D){Array.prototype.push.apply(A,D)},indexOf:function(F,A){for(var E=0;E<F.length;E=E+1){if(F[E]===A){return E}}return -1},toObject:function(F){var A={};for(var E=0;E<F.length;E=E+1){A[F[E]]=true}return A},uniq:function(A){return B.ObjectUtil.keys(B.ArrayUtil.toObject(A))}},loaders:[],finishInit:function(A){A=A||YAHOO;A.env.YUIInfo=B.info;A.util.YUILoader=B.YUILoader},onModuleLoaded:function(G){var A=G.name,H;for(var F=0;F<B.loaders.length;F=F+1){B.loaders[F].loadNext(A)}},init:function(){var A=YAHOO_config,F=A.load,G=(typeof YAHOO!=="undefined"&&YAHOO.env);if(G){YAHOO.env.listeners.push(B.onModuleLoaded)}else{if(A.listener){B.cachedCallback=A.listener}A.listener=function(C){B.onModuleLoaded(C);if(B.cachedCallback){B.cachedCallback(C)}}}if(F||!G){F=F||{};var H=new B.YUILoader(F);H.onLoadComplete=function(){B.finishInit();if(F.onLoadComplete){H._pushEvents();F.onLoadComplete(H)}};if(!G){H.require("yahoo")}H.insert(null,F)}else{B.finishInit()}}};B.YUILoader=function(A){YAHOO_config.injecting=true;A=A||{};this._internalCallback=null;this.onLoadComplete=null;this.base=("base" in A)?A.base:B.info.base;this.allowRollup=("allowRollup" in A)?A.allowRollup:true;this.filter=A.filter;this.sandbox=A.sandbox;this.required={};this.moduleInfo=A.moduleInfo||B.info.moduleInfo;this.rollups=null;this.loadOptional=A.loadOptional||false;this.sorted=[];this.loaded={};this.dirty=true;this.inserted={};this.skin=A.skin||B.ObjectUtil.clone(B.info.skin);if(A.require){this.require(A.require)}B.loaders.push(this)};B.YUILoader.prototype={FILTERS:{RAW:{searchExp:"-min\\.js",replaceStr:".js"},DEBUG:{searchExp:"-min\\.js",replaceStr:"-debug.js"}},SKIN_PREFIX:"skin-",addModule:function(A){if(!A||!A.name||!A.type||(!A.path&&!A.fullpath)){return false}this.moduleInfo[A.name]=A;this.dirty=true;return true},require:function(A){var H=(typeof A==="string")?arguments:A;this.dirty=true;for(var G=0;G<H.length;G=G+1){this.required[H[G]]=true;var F=this.parseSkin(H[G]);if(F){this._addSkin(F.skin,F.module)}}B.ObjectUtil.appendArray(this.required,H)},_addSkin:function(A,E){var F=this.formatSkin(A);if(!this.moduleInfo[F]){this.addModule({name:F,type:"css",path:this.skin.base+A+"/"+this.skin.path,rollup:this.skin.rollup})}if(E){F=this.formatSkin(A,E);if(!this.moduleInfo[F]){this.addModule({name:F,type:"css",path:E+"/"+this.skin.base+A+"/"+E+".css"})}}},getRequires:function(M){if(!this.dirty&&M.expanded){return M.expanded}M.requires=M.requires||[];var N,A=[],K=M.requires,I=M.optional,L=M.supersedes,J=this.moduleInfo;for(N=0;N<K.length;N=N+1){A.push(K[N]);B.ArrayUtil.appendArray(A,this.getRequires(J[K[N]]))}if(I&&this.loadOptional){for(N=0;N<I.length;N=N+1){A.push(I[N]);B.ArrayUtil.appendArray(A,this.getRequires(J[I[N]]))}}M.expanded=B.ArrayUtil.uniq(A);return M.expanded},getProvides:function(H){var G=this.moduleInfo[H];var A={};A[H]=true;var F=G&&G.supersedes;B.ObjectUtil.appendArray(A,F);return A},calculate:function(A){if(this.dirty){this._setup(A);this._explode();this._skin();if(this.allowRollup){this._rollup()}this._reduce();this._sort();this.dirty=false}},_setup:function(A){A=A||{};this.loaded=B.ObjectUtil.clone(this.inserted);if(!this.sandbox&&typeof YAHOO!=="undefined"&&YAHOO.env){this.loaded=B.ObjectUtil.merge(this.loaded,YAHOO.env.modules)}if(A.ignore){B.ObjectUtil.appendArray(this.loaded,A.ignore)}if(A.force){for(var D=0;D<A.force.length;D=D+1){if(A.force[D] in this.loaded){delete this.loaded[A.force[D]]}}}},_explode:function(){var A=this.required,G,H;for(G in A){H=this.moduleInfo[G];if(H){var F=this.getRequires(H);if(F){B.ObjectUtil.appendArray(A,F)}}}},_skin:function(){var G=this.required,H,I;for(H in G){I=this.moduleInfo[H];if(I&&I.skinnable){var A=this.skin.overrides,J;if(A&&A[H]){for(J=0;J<A[H].length;J=J+1){this.require(this.formatSkin(A[H][J],H))}}else{this.require(this.formatSkin(this.skin.defaultSkin,H))}}}},formatSkin:function(A,F){var E=this.SKIN_PREFIX+A;if(F){E=E+"-"+F}return E},parseSkin:function(A){if(A.indexOf(this.SKIN_PREFIX)===0){var D=A.split("-");return{skin:D[1],module:D[2]}}return null},_rollup:function(){var R,S,T,N,P={},M=this.required,A;if(this.dirty||!this.rollups){for(R in this.moduleInfo){T=this.moduleInfo[R];if(T&&T.rollup){P[R]=T}}this.rollups=P}for(;;){var L=false;for(R in P){if(!M[R]&&!this.loaded[R]){T=this.moduleInfo[R];N=T.supersedes;A=true;if(!T.rollup){continue}var O=this.parseSkin(R),Q=0;if(O){for(S in M){if(R!==S&&this.parseSkin(S)){Q++;A=(Q>=T.rollup);if(A){break}}}}else{for(S=0;S<N.length;S=S+1){if(this.loaded[N[S]]){A=false;break}else{if(M[N[S]]){Q++;A=(Q>=T.rollup);if(A){break}}}}}if(A){M[R]=true;L=true;this.getRequires(T)}}}if(!L){break}}},_reduce:function(){var L,M,J,N,I=this.required;for(L in I){if(L in this.loaded){delete I[L]}else{var K=this.parseSkin(L);if(K){if(!K.module){var A=this.SKIN_PREFIX+K.skin;for(M in I){if(M!==L&&M.indexOf(A)>-1){delete I[M]}}}}else{N=this.moduleInfo[L];J=N&&N.supersedes;if(J){for(M=0;M<J.length;M=M+1){if(J[M] in I){delete I[J[M]]}}}}}}},_sort:function(){var Q=[],N=this.moduleInfo,U=this.loaded;var P=function(E,C){if(U[C]){return false}var F,D=N[E],H=D&&D.expanded;if(H&&B.ArrayUtil.indexOf(H,C)>-1){return true}var G=N[C]&&N[C].supersedes;if(G){for(F=0;F<G.length;F=F+1){if(P(E,G[F])){return true}}}return false};for(var V in this.required){Q.push(V)}var O=0;for(;;){var A=Q.length,R,S,W,X,T=false;for(W=O;W<A;W=W+1){R=Q[W];for(X=W+1;X<A;X=X+1){if(P(R,Q[X])){S=Q.splice(X,1);Q.splice(W,0,S[0]);T=true;break}}if(T){break}else{O=O+1}}if(!T){break}}this.sorted=Q},insert:function(A,G,I){if(!I){var J=this;this._internalCallback=function(){J._internalCallback=null;J.insert(A,G,"js")};this.insert(null,G,"css");return }G=G||{};this.onLoadComplete=A||this.onLoadComplete;var H=G&&G.filter||null;if(typeof H==="string"){H=H.toUpperCase();if(H==="DEBUG"){this.require("logger")}}this.filter=this.FILTERS[H]||H||this.FILTERS[this.filter]||this.filter;this.insertOptions=G;this.calculate(G);this.loading=true;this.loadType=I;this.loadNext()},loadNext:function(O){if(O){this.inserted[O]=true}if(!this.loading){return }if(O&&O!==this.loading){return }var M=this.sorted,P=M.length,R,A,L;for(R=0;R<P;R=R+1){if(M[R] in this.inserted){continue}if(M[R]===this.loading){return }A=this.moduleInfo[M[R]];if(!this.loadType||this.loadType===A.type){this.loading=M[R];if(A.type==="css"){L=A.fullpath||this._url(A.path);this.insertCss(L);this.inserted[M[R]]=true}else{L=A.fullpath||this._url(A.path);this.insertScript(L);if(A.verifier){var N=this,K=M[R];A.verifier(K,function(){N.loadNext(K)})}return }}}this.loading=null;if(this._internalCallback){var Q=this._internalCallback;this._internalCallback=null;Q(this)}else{if(this.onLoadComplete){this._pushEvents();this.onLoadComplete(this)}}},_pushEvents:function(){if(typeof YAHOO!=="undefined"&&YAHOO.util&&YAHOO.util.Event){YAHOO.util.Event._load()}},_url:function(A){var F=this.base||"",E=this.filter;F=F+A;if(E){F=F.replace(new RegExp(E.searchExp),E.replaceStr)}return F},insertScript:function(K,I){var L=I||window,H=L.document,A=H.createElement("script"),J=H.getElementsByTagName("head")[0];A.src=K;A.type="text/javascript";J.appendChild(A)},insertCss:function(K,I){var L=I||window,H=L.document,A=H.createElement("link"),J=H.getElementsByTagName("head")[0];A.href=K;A.type="text/css";A.rel="stylesheet";J.appendChild(A)},sandbox:function(A){}};B.init()})();c.require("aria");a.namespace("MEB.behaviors");a.namespace("MEB.objects");MEB.behaviors.Banners=function(){this._section="banners";this._slideShow=null};MEB.behaviors.Banners.prototype.init=function(){try{this._slideShow=new SlideShow();this._slideShow.init({id:"banners_slider",contentsource:["inline",""],toc:"#increment",nextprev:['<img src="'+MEB.resources.base+'/apps/meb/img/homepage/slideshow/previous.gif" />','<img src="'+MEB.resources.base+'/apps/meb/img/homepage/slideshow/next.gif" />'],enablefade:[true,0.1],autorotate:[true,10000],onChange:function(C,B){}});$jq("."+this._section+" button").click(function(){window.location.href=this.getAttribute("link")})}catch(A){}};MEB.objects.banners=new MEB.behaviors.Banners();c.onLoad("init",MEB.objects.banners);c.require("aria");a.namespace("MEB.behaviors.global");a.namespace("MEB.objects.global");MEB.behaviors.global.Header=function(){this._section="gl_header"};MEB.behaviors.global.Header.prototype.init=function(){try{jQuery("#"+this._section+"_menu li").each(function(){jQuery(this).hover(function(){jQuery(this).addClass("menuhover")},function(){jQuery(this).removeClass("menuhover")})});jQuery("#secondary-menu a").hover(function(){jQuery(this).fadeTo("fast",1);jQuery(this).addClass("sec-menu-hover");jQuery(this).next("em").animate({opacity:"show"},"slow");jQuery(this).next("em").text(jQuery(this).attr("title"))},function(){jQuery(this).fadeTo("fast",0.5);jQuery(this).removeClass("sec-menu-hover");jQuery(this).next("em").animate({opacity:"hide"},"fast")});this._addFocusBehaviorToParentElement("menuhover","#top-menu .primary-menu li.primary-menu-item a");this._addFocusBehaviorToSubMenu("menuhover");$jq("#top-menu .secondary-menu a").attachFocusBehavior("with-focus")}catch(A){}};MEB.behaviors.global.Header.prototype._addFocusBehaviorToParentElement=function(C,B){try{$jq(B).each(function(){$jq(this).focus(function(){$jq(this).parent().addClass(C)}).blur(function(){$jq(this).parent().removeClass(C)})})}catch(A){}};MEB.behaviors.global.Header.prototype._addFocusBehaviorToSubMenu=function(B){try{var C="#top-menu .primary-menu li.primary-menu-item ul li a";$jq(C).each(function(){$jq(this).focus(function(){$jq(this).parent().addClass(B);$jq(this).parent().parent().parent().addClass(B)}).blur(function(){$jq(this).parent().removeClass(B);$jq(this).parent().parent().parent().removeClass(B)})})}catch(A){}};MEB.objects.global.header=new MEB.behaviors.global.Header();c.onLoad("init",MEB.objects.global.header);c.require("aria");a.namespace("MEB.behaviors.global");a.namespace("MEB.objects.global");MEB.behaviors.global.Footer=function(){this._section="gl_footer"};MEB.behaviors.global.Footer.prototype.init=function(){try{var B=this;jQuery(".language-selection li").click(function(C){C.preventDefault();C.stopPropagation();var D=this.getAttribute("value");YAHOO.util.Cookie.remove(MEB.cookies.LANGUAGE);YAHOO.util.Cookie.set(MEB.cookies.LANGUAGE,D,MEB.cookies.options);window.location.href=jQuery("#"+B._section+"_baseUrl")[0].value.replace("@language@",D)})}catch(A){}};MEB.objects.global.footer=new MEB.behaviors.global.Footer();c.onLoad("init",MEB.objects.global.footer);c.require("aria");c.require("uic.Errors");c.require("uic.Check");c.require("yui.container");c.require("yui.animation");a.namespace("MEB.behaviors.contact_us");a.namespace("MEB.objects.contact_us");MEB.behaviors.contact_us.ContactUs=function(){this._section="cous";this._contactUsPopup=null;this._mailActionUri=null;this._default_error_message=null};MEB.behaviors.contact_us.ContactUs.prototype.init=function(){try{this._contactUsPopup=new YAHOO.widget.Panel("contactus",{width:"700px",fixedcenter:true,close:false,draggable:false,modal:true,zindex:999,visible:false,underlay:"none"});this._contactUsPopup.render(document.body);this._addValidatorsToForm();this._presetTopic();var A=$jq(".contact_us_link");var C=0;for(C=0;C<=A.length;C++){YAHOO.util.Event.addListener(A[C],"click",this.popupContactUsForm,this)}YAHOO.util.Event.addListener(this._section+"_close_link","click",this._closeContactUsForm,this);YAHOO.util.Event.addListener(this._section+"_submit","click",this._sendMail,this);this._default_error_message=MEB.utilities.i18n.contact_us.translate("error","DEFAULT_MESSAGE");$jq(".form-common-button").hoverClass("form-common-button-hover");$jq(".mail-button").hoverClass("mail-button-hover");$("MAIL_BODY",this).setContextErrorText(MEB.utilities.i18n.contact_us.translate("error","MAIL_BODY_ERROR"))}catch(B){}};MEB.behaviors.contact_us.ContactUs.prototype._presetTopic=function(){try{if(c.isInDom("contact_us_topic")){var B=$("contact_us_topic").value;var A=$("MAIL_SUBJECT",this);switch(B){case"about_us":A.setIndex(1);break;case"advertise":A.setIndex(2);break;case"help_faq":A.setIndex(3);break;case"privacy":A.setIndex(4);break;case"legal_notice":A.setIndex(5);break;default:break}}}catch(C){}};MEB.behaviors.contact_us.ContactUs.prototype._addValidatorsToForm=function(){try{$("MAIL_SUBJECT",this).addValidator("METHOD","error",this._checkSelectTopic.createDelegate(this,[$("MAIL_SUBJECT",this)]))}catch(A){}};MEB.behaviors.contact_us.ContactUs.prototype._updateErrorMessageAndDisplay=function(B){try{$(this._section+"_error_message_panel").style.display="block"}catch(A){}};MEB.behaviors.contact_us.ContactUs.prototype._displayErrorMessage=function(){try{if(arguments.length>=1){if(2==arguments.length){var B=arguments[1];if("3001"==B){window.location="http://"+window.document.location.host+$("homepage_url_redirect",this).value}}$jq("#"+this._section+"_error_message_panel p")[0].innerHTML=arguments[0]}else{$jq("#"+this._section+"_error_message_panel p")[0].innerHTML=this._default_error_message}$(this._section+"_error_message_panel").style.display="block"}catch(A){}};MEB.behaviors.contact_us.ContactUs.prototype._displayContactForm=function(){$(this._section+"_form_content").style.display="block";$jq("#contactus")[0].style.display="block"};MEB.behaviors.contact_us.ContactUs.prototype._displayThrobber=function(){$(this._section+"_throbber").style.visibility="visible"};MEB.behaviors.contact_us.ContactUs.prototype._hideThrobber=function(){$(this._section+"_throbber").style.visibility="hidden"};MEB.behaviors.contact_us.ContactUs.prototype._displayConfirmation=function(){$(this._section+"_confirmation_content").style.display="block";$(this._section+"_form_content").style.display="none";$(this._section+"_error_message_panel").style.display="none";YAHOO.util.Event.addListener(this._section+"_confirmation_close_link","click",this._closeContactUsForm,this)};MEB.behaviors.contact_us.ContactUs.prototype._checkSelectTopic=function(C){try{var A=C.getValue();if(A=="default_topic"){return false}return true}catch(B){}};MEB.behaviors.contact_us.ContactUs.prototype._closeContactUsForm=function(A,C){try{if(null!=A){YAHOO.util.Event.stopEvent(A)}C._resetContactUsForm();$jq("#contactus")[0].style.display="none";C._hideThrobber();C._contactUsPopup.hide()}catch(B){}};MEB.behaviors.contact_us.ContactUs.prototype._resetContactUsForm=function(){try{$(this._section+"_confirmation_content").style.display="none";$(this._section+"_error_message_panel").style.display="none";$jq($("MAIL_NAME",this).getInput()).removeClass("error");$jq($("MAIL_FROM",this).getInput()).removeClass("error");$jq($("MAIL_SUBJECT",this).getInput()).removeClass("error");$jq($("MAIL_BODY",this).getInput()).removeClass("error");$("MAIL_NAME",this).getInput().value="";$("MAIL_FROM",this).getInput().value="";$("MAIL_SUBJECT",this).setValue("default_topic");$("MAIL_BODY",this).getInput().value="";this._displayContactForm()}catch(A){}};MEB.behaviors.contact_us.ContactUs.prototype._sendMail=function(evt,obj){try{YAHOO.util.Event.stopEvent(evt);obj._displayThrobber();if(MEB.errors.manager.formIsOk(obj._section+"_contact_us_form")){var mailActionUri=$(obj._section+"_contact_us_form",obj).action;var postParams="MAIL_FROM_PAGE="+$("MAIL_FROM_PAGE",obj).value+"&";postParams+="MAIL_CC="+$("MAIL_CC",obj).value+"&";postParams+="MAIL_NAME="+$("MAIL_NAME",obj).getInput().value+"&";postParams+="MAIL_FROM="+$("MAIL_FROM",obj).getInput().value+"&";postParams+="MAIL_SUBJECT="+$("MAIL_SUBJECT",obj).getInput().value+"&";postParams+="MAIL_BODY="+$("MAIL_BODY",obj).getInput().value;var callback={scope:obj,success:function(o){if(o.responseText!=""){var json_response=eval("("+o.responseText+")");if("success"==json_response.GENERAL.status){this._displayConfirmation()}else{if("generr"==json_response.GENERAL.status){var firstError=json_response.ERRORS[0];if(null!=firstError.text){this._displayErrorMessage(firstError.text,firstError.number)}}}}else{this._displayErrorMessage()}},failure:function(o){this._displayErrorMessage()}};var transaction=YAHOO.util.Connect.asyncRequest("POST",mailActionUri,callback,postParams)}else{obj._displayErrorMessage()}setTimeout(function(){obj._hideThrobber()},"1000")}catch(exception){}};MEB.behaviors.contact_us.ContactUs.prototype.popupContactUsForm=function(A,C){try{if(null!=A){YAHOO.util.Event.stopEvent(A)}C._displayContactForm();C._contactUsPopup.show()}catch(B){}};MEB.objects.contact_us.contactUsForm=new MEB.behaviors.contact_us.ContactUs();c.onLoad("init",MEB.objects.contact_us.contactUsForm,MEB.objects.contact_us.contactUsForm._section);c.require("aria");a.namespace("MEB.behaviors.poll");a.namespace("MEB.objects.poll");MEB.behaviors.poll.Poll=function(){this._section="poll"};MEB.behaviors.poll.Poll.prototype.init=function(){try{$jq(".pds-votebutton").hoverClass("pds-votebutton-hover")}catch(A){}};MEB.objects.poll.pollInstance=new MEB.behaviors.poll.Poll();c.onLoad("init",MEB.objects.poll.pollInstance);c.require("aria");a.namespace("MEB.behaviors.destination_cloud");a.namespace("MEB.objects.destination_cloud");MEB.behaviors.destination_cloud.DestinationCloudContainer=function(){this._section="decl";this._selected_cloud=this._section+"_flight_label";this._airCloudHasBeenInitialized=false;this._carCloudHasBeenInitialized=false;this._hotelCloudHasBeenInitialized=false;this._currentCloud="air"};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype.init=function(){try{MEB.eventBus.subscribe(this._onEvent.createDelegate(this));this._selected_cloud=this._section+"_flight_label";$jq("#"+this._selected_cloud+" a").addClass("selected");this._selectAirCloud();$jq("#tag-cloud-wrapper").show();YAHOO.util.Event.addListener(this._section+"_flight_label","click",this._onSelectDestinationCloudType,this);YAHOO.util.Event.addListener(this._section+"_hotel_label","click",this._onSelectDestinationCloudType,this);YAHOO.util.Event.addListener(this._section+"_car_label","click",this._onSelectDestinationCloudType,this)}catch(A){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._onSelectDestinationCloudType=function(A,D){try{YAHOO.util.Event.stopEvent(A);var C=this.id;if(C==D._selected_cloud){return }else{switch(C){case D._section+"_flight_label":D._selectAirCloud();break;case D._section+"_hotel_label":D._selectHotelCloud();break;case D._section+"_car_label":D._selectCarCloud();break}}}catch(B){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._selectAirCloud=function(){try{this._initCloud("air");$jq("#"+this._selected_cloud+" a").removeClass("selected");this._selected_cloud=this._section+"_flight_label";$jq("#"+this._selected_cloud+" a").addClass("selected");$jq("#car_cloud_content").hide();$jq("#hotel_cloud_content").hide();$jq("#air_cloud_content").show()}catch(A){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._selectHotelCloud=function(){try{this._initCloud("hotel");$jq("#"+this._selected_cloud+" a").removeClass("selected");this._selected_cloud=this._section+"_hotel_label";$jq("#"+this._selected_cloud+" a").addClass("selected");$jq("#air_cloud_content").hide();$jq("#car_cloud_content").hide();$jq("#hotel_cloud_content").show()}catch(A){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._selectCarCloud=function(){try{this._initCloud("car");$jq("#"+this._selected_cloud+" a").removeClass("selected");this._selected_cloud=this._section+"_car_label";$jq("#"+this._selected_cloud+" a").addClass("selected");$jq("#air_cloud_content").hide();$jq("#hotel_cloud_content").hide();$jq("#car_cloud_content").show()}catch(A){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._initCloud=function(D){try{if((D=="air"&&!this._airCloudHasBeenInitialized)||(D=="hotel"&&!this._hotelCloudHasBeenInitialized)||(D=="car"&&!this._carCloudHasBeenInitialized)){this._currentCloud=D;var E={success:this._onGetCloudSucces,failure:this._onGetCloudFailed,scope:this};var A=$jq("#"+this._section+"_form")[0];$jq("#"+this._section+"_type")[0].value=D;YAHOO.util.Connect.setForm(A);var C=YAHOO.util.Connect.asyncRequest(A.method||"GET",A.action,E)}}catch(B){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._getData=function(obj){try{var _data=obj.responseText;if(_data.length==0){return[]}_data=_data.substring(_data.indexOf("["),_data.lastIndexOf("]")+1);_data=_data.replace(/\\/g,"");var res=eval("("+_data+")");var a,b,tmp;for(var i=0;i<res.length;i++){a=Math.floor(Math.random()*100)%res.length;b=Math.floor(Math.random()*100)%res.length;tmp=res[a];res[a]=res[b];res[b]=tmp}return res}catch(exception){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._onGetCloudSucces=function(F){try{MEB.data[this._currentCloud+"TopDestinations"]=this._getData(F);if(MEB.data[this._currentCloud+"TopDestinations"].length>0){var E=$jq("#"+this._currentCloud+"_cloud_content");E.html("");var A=null;for(var C=0;C<MEB.data[this._currentCloud+"TopDestinations"].length;C++){A=this._section+"_"+this._currentCloud+"_dest_"+C;var D=MEB.data[this._currentCloud+"TopDestinations"][C].name.replace(/ /g,"&#160;");E.append('<a id="'+A+'" class="cloud_'+MEB.data[this._currentCloud+"TopDestinations"][C].weight+'" href="#">'+D+"</a> ");YAHOO.util.Event.addListener(A,"click",this._onSelectTopDestination,{type:this._currentCloud.substring(0,1).toUpperCase()+this._currentCloud.substring(1),data:MEB.data[this._currentCloud+"TopDestinations"][C]});E.append("\n")}this["_"+this._currentCloud+"CloudHasBeenInitialized"]=true}}catch(B){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._onGetCloudFailed=function(){try{}catch(A){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._onSelectTopDestination=function(A,C){try{YAHOO.util.Event.stopEvent(A);YAHOO.util.Event.stopPropagation(A);MEB.eventBus.fire({eventName:"onSelect"+C.type+"TopDestination",data:{city:C.data.name,iata:C.data.iata}})}catch(B){}};MEB.behaviors.destination_cloud.DestinationCloudContainer.prototype._onEvent=function(A,C){var B=C[0];switch(B.eventName){case"onAirFormSelected":this._selectAirCloud();break;case"onHotelFormSelected":this._selectHotelCloud();break;case"onCarFormSelected":this._selectCarCloud();break;default:break}};MEB.objects.destination_cloud.destinationCloud=new MEB.behaviors.destination_cloud.DestinationCloudContainer();c.onLoad("init",MEB.objects.destination_cloud.destinationCloud);c.require("aria");a.namespace("MEB.behaviors.welcome");a.namespace("MEB.objects.welcome");MEB.behaviors.welcome.Welcome=function(){this._section="welc";this._initial_sentence_wording="Search. Find. Travel.";this._wording_Search="Search";this._wording_Find="Find";this._wording_Travel="Travel"};MEB.behaviors.welcome.Welcome.prototype.init=function(){try{this._initial_sentence_wording=$("welcome-slogan-content").innerHTML;var A=this._initial_sentence_wording.split(".");if(A.length!=4){}else{if(null!=A[0]){this._wording_Search=$jq.trim(A[0])}if(null!=A[1]){this._wording_Find=$jq.trim(A[1])}if(null!=A[2]){this._wording_Travel=$jq.trim(A[2])}}$("search-slogan").innerHTML=this._wording_Search;$("find-slogan").innerHTML=this._wording_Find;$("travel-slogan").innerHTML=this._wording_Travel}catch(B){}};MEB.objects.welcome.Welcome=new MEB.behaviors.welcome.Welcome();c.onLoad("init",MEB.objects.welcome.Welcome);c.require("aria");a.namespace("MEB.behaviors.quick_links");a.namespace("MEB.objects.quick_links");MEB.behaviors.quick_links.QuickLinks=function(){this._section="quli"};MEB.behaviors.quick_links.QuickLinks.prototype.init=function(){try{$jq("a.social-bookmark").click(function(){this.target="_blank"});$jq(".bm-item").hoverClass("hover-bm");$jq(".bm-item").attachFocusBehavior("hover-bm")}catch(A){}};MEB.objects.quick_links.quickLinks=new MEB.behaviors.quick_links.QuickLinks();c.onLoad("init",MEB.objects.quick_links.quickLinks,MEB.objects.quick_links.quickLinks._section);c.require("aria");c.require("uic.Errors");c.require("uic.Check");c.require("util.simpleDateFormat");a.namespace("MEB.behaviors.quick.search");a.namespace("MEB.objects.quick.search");MEB.behaviors.quick.search.SearchForm=function(){this._section="quse";this._searchType="qs-flights";this._openedForm="quick-search-form";this._tripType=null;this._isShowingPrefAir=false;this._hotelNightNumber=null;this._dropoffType=null};MEB.behaviors.quick.search.SearchForm.prototype.init=function(){try{MEB.eventBus.subscribe(this._onEvent.createDelegate(this));var obj=eval("("+YAHOO.util.Cookie.get(MEB.cookies.LAST_AIR_DEPARTURE_CITY)+")");if(typeof obj!="undefined"&&obj!=null){if(("undefined"==typeof (obj.lang))||(("undefined"!=typeof (obj.lang))&&(obj.lang==MEB.meta.current_language))){if($("from",this).getValue()==""){$("from",this).setValue(obj.value);$("from",this).setCode(obj.code)}}}this._addValidator();if(c.isInDom(this._section+"_air_availability_search")){YAHOO.util.Event.addListener($(this._section+"_air_availability_search",this),"click",this._onAirAvailabilitySubmit,this)}if(c.isInDom(this._section+"_air_best_fares_search")){YAHOO.util.Event.addListener($(this._section+"_air_best_fares_search",this),"click",this._onAirBestFaresSubmit,this)}if(c.isInDom(this._section+"_hotel_availability_search")){YAHOO.util.Event.addListener($(this._section+"_hotel_availability_search",this),"click",this._onHotelAvailabilitySubmit,this)}if(c.isInDom(this._section+"_hotel_best_fares_search")){YAHOO.util.Event.addListener($(this._section+"_hotel_best_fares_search",this),"click",this._onHotelBestFaresSubmit,this)}if(c.isInDom(this._section+"_car_availability_search")){YAHOO.util.Event.addListener($(this._section+"_car_availability_search",this),"click",this._onCarAvailabilitySubmit,this)}if(c.isInDom(this._section+"_car_best_fares_search")){YAHOO.util.Event.addListener($(this._section+"_car_best_fares_search",this),"click",this._onCarBestFaresSubmit,this)}YAHOO.util.Event.addListener($("qs-flights",this),"mousedown",this._onChooseSearchType,this);YAHOO.util.Event.addListener($("qs-hotels",this),"mousedown",this._onChooseSearchType,this);YAHOO.util.Event.addListener($("qs-cars",this),"mousedown",this._onChooseSearchType,this);YAHOO.util.Event.addListener($(this._section+"_radio_round",this),"click",this._onChooseTripType,this);YAHOO.util.Event.addListener($(this._section+"_radio_oneway",this),"click",this._onChooseTripType,this);YAHOO.util.Event.addListener($(this._section+"_radio_dropoff_same",this),"click",this._onChooseDropoffType,this);YAHOO.util.Event.addListener($(this._section+"_radio_dropoff_different",this),"click",this._onChooseDropoffType,this);YAHOO.util.Event.addListener($(this._section+"_advanced_search",this),"click",this._onAdvancedSearch,this);this._dropoffType=$jq("input[@name='"+this._section+"_dropoff_type']:checked")[0].value;this._tripType=$jq("input[@name='"+this._section+"_trip_type']:checked")[0].value;this._updateFlightReturningDisplay();this._updateCarDropoffDisplay();this._resetDate();$("date_to",this).bind($("date_from",this),7);$("date_to",this).setDate(new Date($("date_from",this).getDate().getTime()+7*24*60*60*1000));this._hotelNightNumber=1;$("hotel_check_out",this).bind($("hotel_check_in",this),1);$("hotel_check_out",this).setDate(new Date($("hotel_check_in",this).getDate().getTime()+this._hotelNightNumber*24*60*60*1000));this._updateHotelCheckOutDate(null,this);$("drop_off_date",this).bind($("pick_up_date",this),1);$("drop_off_date",this).setDate(new Date($("pick_up_date",this).getDate().getTime()+24*60*60*1000));this._addNightCounterBehavior();$jq(".qs-menu-link").hoverClass("qs-tab-hover");$jq(".flight-search-button").hoverClass("flight-search-button-hover");$jq(".fares-search-button").hoverClass("fares-search-button-hover");$jq(".hotel-search-button").hoverClass("hotel-search-button-hover");$jq(".car-search-button").hoverClass("car-search-button-hover");$jq(".quick-search-button").attachFocusBehavior("quick-search-button-hover");$jq(".qs-menu-link").attachFocusBehavior("qs-tab-focus");var airFormKeyManager=new MEB.keys.Manager(MEB.keys.codes.ENTER,$jq("#quick-search #qs-flights a"),this._displayAirForm.createDelegate(this));var carFormKeyManager=new MEB.keys.Manager(MEB.keys.codes.ENTER,$jq("#quick-search #qs-cars a"),this._displayCarForm.createDelegate(this));var hotelFormKeyManager=new MEB.keys.Manager(MEB.keys.codes.ENTER,$jq("#quick-search #qs-hotels a"),this._displayHotelForm.createDelegate(this))}catch(exception){}};MEB.behaviors.quick.search.SearchForm.prototype._updateCarDropoffDisplay=function(){if("same"==this._dropoffType){$jq("#different_location label")[0].style.fontWeight="normal";$jq("#same_location label")[0].style.fontWeight="bold";$jq(".car_drop_off_location").addClass("hidden")}else{if("diff"==this._dropoffType){$jq("#different_location label")[0].style.fontWeight="bold";$jq("#same_location label")[0].style.fontWeight="normal";$jq(".car_drop_off_location").removeClass("hidden")}}};MEB.behaviors.quick.search.SearchForm.prototype._updateFlightReturningDisplay=function(){if("R"==this._tripType){$jq("#oneway label")[0].style.fontWeight="normal";$jq("#round label")[0].style.fontWeight="bold";$jq("#"+this._section+"_return_date").show()}else{if("O"==this._tripType){$jq("#oneway label")[0].style.fontWeight="bold";$jq("#round label")[0].style.fontWeight="normal";$jq("#"+this._section+"_return_date").hide()}}};MEB.behaviors.quick.search.SearchForm.prototype._addValidator=function(){try{$("from",this).addValidator("METHOD","error",this._checkDestination.createDelegate(this,["from"]));$("to",this).addValidator("METHOD","error",this._checkDestination.createDelegate(this,["to"]));$("date_to",this).getTextField().addValidator("METHOD","error",this._checkDate.createDelegate(this,["date_to"]));$("hotel_check_out",this).getTextField().addValidator("METHOD","error",this._checkDate.createDelegate(this,["hotel_check_out"]));$("car_pick_up_location",this).addValidator("METHOD","error",this._checkDestination.createDelegate(this,["car_pick_up_location"]));$("car_drop_off_location",this).addValidator("METHOD","error",this._checkDestination.createDelegate(this,["car_drop_off_location"]));$("drop_off_date",this).getTextField().addValidator("METHOD","error",this._checkDate.createDelegate(this,["drop_off_date"]))}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._checkDestination=function(B){try{if(this._searchType=="qs-cars"){if((this._dropoffType=="same")&&(B=="car_drop_off_location")){return true}}return MEB.errors.manager.checkTextField($(B,this))}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._addNightCounterBehavior=function(){try{$("hotel_check_in",this).subscribe("select",this._updateHotelNight,this,true);$("hotel_check_out",this).subscribe("select",this._updateHotelNight,this,true);$("hotel_check_out",this).subscribe("change",this._updateHotelNight,this,true);YAHOO.util.Event.addListener($("hotel_night",this).getInput(),"keyup",this._updateHotelCheckOutDate,this)}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._checkDate=function(){try{var D=null;var B=null;if("qs-flights"==this._searchType){if(this._tripType=="R"){D=$("date_from",this);B=$("date_to",this)}else{D=$("date_from",this);return MEB.errors.manager.checkDate(D)}}else{if("qs-hotels"==this._searchType){B=$("hotel_check_out",this);D=$("hotel_check_in",this)}else{if("qs-cars"==this._searchType){B=$("drop_off_date",this);D=$("pick_up_date",this)}}}var A=(MEB.errors.manager.checkDate(B))&&(MEB.errors.manager.checkDate(B,D.getDate().getTime())>-1);return(MEB.errors.manager.checkDate(B))&&(MEB.errors.manager.checkDate(B,D.getDate().getTime())>-1)}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._checkDropOffLocationTextField=function(B){try{if(this._dropoffType=="same"){return true}return MEB.errors.manager.checkTextField(B)}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._getDate=function(D){try{var A=$(D,this).getDate();var C;return{day:A.getDate(),month:(C=parseInt(A.getMonth()+1))<10?"0"+C:C,shift_month:(C=parseInt(A.getMonth()))<10?"0"+C:C,year:A.getFullYear(),full_date_with_default_time:(A.getFullYear()+""+((C=parseInt(A.getMonth()+1))<10?"0"+C:C)+""+((day=parseInt(A.getDate()))<10?"0"+day:day)+"2359"),full_date:(A.getFullYear()+""+((C=parseInt(A.getMonth()+1))<10?"0"+C:C)+""+((day=parseInt(A.getDate()))<10?"0"+day:day))}}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._onAirBestFaresSubmit=function(A,C){try{YAHOO.util.Event.stopEvent(A);YAHOO.util.Event.stopPropagation(A);C._submitBestFareAirForm(C._section+"_global_bf_form")}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._submitBestFareAirForm=function(E){try{if(MEB.errors.manager.checkForm(this._section+"_user_input")){var B;var A=new util.simpleDateFormat();$(E+"_from",this).value=(B=$("from",this).getCode())==""?$("from",this).getValue():B;$(E+"_date_from",this).value=A.format("MM/dd/yyyy",$("date_from",this).getDate());$(E+"_time_from",this).value=$("time_from",this).getValue()=="ANY"?"a":MEB.utilities.modifiers.toBestFareTime($("time_from",this).getValue().substring(0,2));$(E+"_date_to",this).value=A.format("MM/dd/yyyy",$("date_to",this).getDate());$(E+"_to",this).value=(B=$("to",this).getCode())==""?$("to",this).getValue():B;$(E+"_time_to",this).value=$("time_to",this).getValue()=="ANY"?"a":MEB.utilities.modifiers.toBestFareTime($("time_to",this).getValue().substring(0,2));$(E+"_trip_type",this).value=this._tripType;$(E+"_check_nonstop",this).value=$("check_nonstop",this).isCheck()?"y":"n";$(E+"_adult_traveller",this).value=$("travel_adult",this).getValue();var D='{code : "'+$("from",this).getCode()+'",value : "'+$("from",this).getValue()+'",lang : "'+MEB.meta.current_language+'"}';YAHOO.util.Cookie.set(MEB.cookies.LAST_AIR_DEPARTURE_CITY,D,MEB.cookies.options)}}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._onAdvancedSearch=function(A,D){try{YAHOO.util.Event.preventDefault(A);YAHOO.util.Event.stopPropagation(A);$(D._section+"_user_input_fromIata",D).value=$("from",D).getCode();$(D._section+"_user_input_toIata",D).value=$("to",D).getCode();var B=$("date_from",D).getDate();if(typeof B!="undefined"&&B!=null){$(D._section+"_user_input_df",D).value=B.getTime()+2*60*60*1000}B=$("date_to",D).getDate();if(typeof B!="undefined"&&B!=null){$(D._section+"_user_input_dt",D).value=$("date_to",D).getDate().getTime()+2*60*60*1000}$(D._section+"_user_input_direct",D).value=$("check_nonstop",D).isCheck()}catch(C){}finally{$(D._section+"_user_input",D).submit()}};MEB.behaviors.quick.search.SearchForm.prototype._onCarBestFaresSubmit=function(A,C){try{YAHOO.util.Event.stopEvent(A);YAHOO.util.Event.stopPropagation(A);C._submitBestFareCarForm()}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._submitBestFareCarForm=function(){try{if(MEB.errors.manager.checkForm(this._section+"_car_user_input")){var D=this._section+"_global_bf_form";$(D).action=$(D).action.replace(/air/g,"car");var E=null;if(this._dropoffType=="diff"){E=false}else{if(this._dropoffType=="same"){E=true}}var B;$(D+"_ap",this).value=(B=$("car_pick_up_location",this).getCode())==""?$("car_pick_up_location",this).getValue():B;$(D+"_crc",this).value=$("car_pick_up_location",this).getValue();if(E){$(D+"_ap2",this).value=(B=$("car_pick_up_location",this).getCode())==""?$("car_pick_up_location",this).getValue():B;$(D+"_crc2",this).value=$("car_pick_up_location",this).getValue()}else{$(D+"_ap2",this).value=(B=$("car_drop_off_location",this).getCode())==""?$("car_drop_off_location",this).getValue():B;$(D+"_crc2",this).value=$("car_drop_off_location",this).getValue()}$(D+"_time_from",this).value=$("pick_up_time",this).getValue();$(D+"_time_to",this).value=$("drop_off_time",this).getValue();var A=new util.simpleDateFormat();$(D+"_date_from",this).value=A.format("MM/dd/yyyy",$("pick_up_date",this).getDate());$(D+"_date_to",this).value=A.format("MM/dd/yyyy",$("drop_off_date",this).getDate());MEB.popups.waiting.displayCarPopupAndSubmit(D)}}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._onHotelBestFaresSubmit=function(A,C){try{YAHOO.util.Event.stopEvent(A);YAHOO.util.Event.stopPropagation(A);C._submitBestFareHotelForm()}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._submitBestFareHotelForm=function(){try{if(MEB.errors.manager.checkForm(this._section+"_hotel_user_input")){var C=this._section+"_global_bf_form";$(C).action=$(C).action.replace(/air/g,"hotel");var A=new util.simpleDateFormat();$(C+"_date_from",this).value=A.format("MM/dd/yyyy",$("hotel_check_in",this).getDate());$(C+"_date_to",this).value=A.format("MM/dd/yyyy",$("hotel_check_out",this).getDate());$(C+"_adult_traveller",this).value=$("hotel_number_guest",this).getValue();$(C+"_crc",this).value=$("hotel_location",this).getValue();MEB.popups.waiting.displayHotelPopupAndSubmit(C)}}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._submitAirForm=function(){try{if(MEB.errors.manager.checkForm(this._section+"_user_input")){$("TRIP_TYPE",this).value=this._tripType;$("DIRECT_NON_STOP",this).value=$("check_nonstop",this).isCheck();$("FIELD_ADT_NUMBER",this).value=$("travel_adult",this).getValue();var B="";if(this._tripType=="R"||this._tripType=="O"){$("B_LOCATION_1",this).value=(B=$("from",this).getCode())==""?$("from",this).getValue():B;$("E_LOCATION_1",this).value=(B=$("to",this).getCode())==""?$("to",this).getValue():B;var D=this._getDate("date_from");$("Month1",this).value=D.year+""+(D.shift_month);$("Day1",this).value=D.day;$("Hours1",this).value=$("time_from",this).getValue();if(this._tripType=="R"){var A=this._getDate("date_to");$("Month2",this).value=A.year+""+(A.shift_month);$("Day2",this).value=A.day;$("Hours2",this).value=$("time_to",this).getValue()}}var E='{code : "'+$("from",this).getCode()+'",value : "'+$("from",this).getValue()+'",lang : "'+MEB.meta.current_language+'"}';YAHOO.util.Cookie.set(MEB.cookies.LAST_AIR_DEPARTURE_CITY,E,MEB.cookies.options);MEB.popups.waiting.displayAirPopupAndSubmit(this._section+"_form")}}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._submitCarForm=function(){try{if(MEB.errors.manager.checkForm(this._section+"_car_user_input")){var A=$("car_pick_up_location",this);$("CAR_B_LOCATION",this).value=A.getCode();var F=null;if(this._dropoffType=="diff"){F=false}else{if(this._dropoffType=="same"){F=true}}if(F){A=$("car_pick_up_location",this);$("CAR_E_LOCATION",this).value=A.getCode();$("CAR_PLTG_DROPOFF_DIFF_PICKUP",this).value=0;$("CAR_PLTG_DISPLAY_DROPOFF",this).value=""}else{A=$("car_drop_off_location",this);$("CAR_E_LOCATION",this).value=A.getCode();$("CAR_PLTG_DROPOFF_DIFF_PICKUP",this).value=1;$("CAR_PLTG_DISPLAY_DROPOFF",this).value="on"}var B=this._getDate("pick_up_date");var E=$("pick_up_time",this).getValue();if(E=="ANY"){E="2359"}$("CAR_B_Time",this).value=E;$("CAR_B_DAY",this).value=B.day;$("CAR_B_MONTH",this).value=B.year+""+B.month;$("CAR_B_DATE",this).value=B.full_date+E;$("CAR_backB_DATE",this).value=B.full_date+E;$("CAR_Month1",this).value=B.year+""+(B.shift_month);$("CAR_Day1",this).value=B.day;var D=$("drop_off_time",this).getValue();if(D=="ANY"){D="2359"}B=this._getDate("drop_off_date");$("CAR_E_Time",this).value=D;$("CAR_E_DAY",this).value=B.day;$("CAR_E_MONTH",this).value=B.year+""+B.month;$("CAR_E_DATE",this).value=B.full_date+D;$("CAR_backE_DATE",this).value=B.full_date+D;$("CAR_Month2",this).value=B.year+""+(B.shift_month);$("CAR_Day2",this).value=B.day;MEB.popups.waiting.displayCarPopupAndSubmit(this._section+"_car_form")}}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._submitHotelForm=function(){try{if(MEB.errors.manager.checkForm(this._section+"_hotel_user_input")){var A=$("hotel_location",this);$("HOTEL_B_LOCATION",this).value=A.getCode();$("HOTEL_COUNTRY_CODE",this).value="";var B=this._getDate("hotel_check_in");$("HOTEL_B_DAY",this).value=B.day;$("HOTEL_B_MONTH",this).value=B.year+""+(B.shift_month);$("HOTEL_B_DATE",this).value=B.full_date_with_default_time;$("HOTEL_backB_DATE",this).value=B.full_date_with_default_time;B=this._getDate("hotel_check_out");$("HOTEL_E_DAY",this).value=B.day;$("HOTEL_E_MONTH",this).value=B.year+""+(B.shift_month);$("HOTEL_E_DATE",this).value=B.full_date_with_default_time;$("HOTEL_backE_DATE",this).value=B.full_date_with_default_time;$("HOTEL_OCCUPANCY",this).value=$("hotel_number_guest",this).getValue();MEB.popups.waiting.displayHotelPopupAndSubmit(this._section+"_hotel_form")}}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._onAirAvailabilitySubmit=function(A,C){try{YAHOO.util.Event.stopEvent(A);YAHOO.util.Event.stopPropagation(A);C._submitAirForm()}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._onHotelAvailabilitySubmit=function(A,C){try{YAHOO.util.Event.stopEvent(A);YAHOO.util.Event.stopPropagation(A);C._submitHotelForm()}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._onCarAvailabilitySubmit=function(A,C){try{YAHOO.util.Event.stopEvent(A);YAHOO.util.Event.stopPropagation(A);C._submitCarForm()}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._onChooseDropoffType=function(A,D){try{var B=this.value;if(B==D._dropoffType){return }switch(B){case"same":$jq(".car_drop_off_location").addClass("hidden");$jq("#different_location label")[0].style.fontWeight="normal";$jq("#same_location label")[0].style.fontWeight="bold";break;case"diff":$jq(".car_drop_off_location").removeClass("hidden");$jq("#different_location label")[0].style.fontWeight="bold";$jq("#same_location label")[0].style.fontWeight="normal";break;default:break}D._dropoffType=B}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._onChooseSearchType=function(A,D){var B=this.id;try{if(B==D._searchType){return }else{$jq("#qsearch-tab-navigation .button-tabs a").blur();switch(B){case"qs-flights":$jq("#quse_radio_flight").focus();D._displayAirForm();break;case"qs-hotels":$jq("#quse_radio_hotel").focus();D._displayHotelForm();break;case"qs-cars":$jq("#quse_radio_car").focus();D._displayCarForm();break}}}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._displayAirForm=function(){try{$jq("#"+MEB.errors.container).hide();$jq("#"+this._searchType+" a").removeClass("qs-tab-open");this._searchType="qs-flights";$jq("#"+this._searchType+" a").addClass("qs-tab-open");$jq("#"+this._openedForm).hide();$jq("#quick-search-form").show();this._openedForm="quick-search-form";MEB.eventBus.fire({eventName:"onAirFormSelected"})}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._displayHotelForm=function(){try{$jq("#"+MEB.errors.container).hide();$jq("#"+this._searchType+" a").removeClass("qs-tab-open");this._searchType="qs-hotels";$jq("#"+this._searchType+" a").addClass("qs-tab-open");$jq("#"+this._openedForm).hide();$jq("#hotel-quick-search-form").show();this._openedForm="hotel-quick-search-form";MEB.eventBus.fire({eventName:"onHotelFormSelected"})}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._displayCarForm=function(){try{$jq("#"+MEB.errors.container).hide();$jq("#"+this._searchType+" a").removeClass("qs-tab-open");this._searchType="qs-cars";$jq("#"+this._searchType+" a").addClass("qs-tab-open");$jq("#"+this._openedForm).hide();$jq("#car-quick-search-form").show();this._openedForm="car-quick-search-form";MEB.eventBus.fire({eventName:"onCarFormSelected"})}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._onChooseTripType=function(A,D){var B=this.value;try{if(B==D._tripType){return }switch(B){case"R":$jq("#"+D._section+"_return_date").show();$jq("#oneway label")[0].style.fontWeight="normal";$jq("#round label")[0].style.fontWeight="bold";break;case"O":$jq("#"+D._section+"_return_date").hide();$jq("#oneway label")[0].style.fontWeight="bold";$jq("#round label")[0].style.fontWeight="normal";break}D._tripType=B}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._onEvent=function(A,D){try{var C=D[0];switch(C.eventName){case"onSelectTopDestination":if(this._searchType=="qs-flights"){$("to",this).setCode(C.data.iata);$("to",this).setValue(C.data.city+" ("+C.data.iata+")")}break;case"onSelectAirTopDestination":this._displayAirForm();$("to",this).setCode(C.data.iata);$("to",this).setValue(C.data.city+" ("+C.data.iata+")");break;case"onSelectHotelTopDestination":this._displayHotelForm();$("hotel_location",this).setCode(C.data.iata);$("hotel_location",this).setValue(C.data.city+" ("+C.data.iata+")");break;case"onSelectCarTopDestination":this._displayCarForm();$("car_pick_up_location",this).setCode(C.data.iata);$("car_pick_up_location",this).setValue(C.data.city+" ("+C.data.iata+")");break;default:break}}catch(B){}};MEB.behaviors.quick.search.SearchForm.prototype._resetDate=function(){try{$("date_from",this).setDate(new Date());$("hotel_check_in",this).setDate(new Date());$("pick_up_date",this).setDate(new Date())}catch(A){}};MEB.behaviors.quick.search.SearchForm.prototype._updateHotelCheckOutDate=function(B,D){try{var A=$("hotel_night",D).getValue();if(MEB.errors.manager.isPositiveInteger(A+"")){D._hotelNightNumber=Math.round(A);$("hotel_check_out",D).setDate(new Date($("hotel_check_in",D).getDate().getTime()+D._hotelNightNumber*24*60*60*1000))}}catch(C){}};MEB.behaviors.quick.search.SearchForm.prototype._updateHotelNight=function(){try{var D=null;var A=null;D=$("hotel_check_in",this).getDate().getTime();A=$("hotel_check_out",this).getDate().getTime();var C=Math.round((A-D)/(1000*60*60*24));if(MEB.errors.manager.isPositiveInteger(C+"")){this._hotelNightNumber=C;$("hotel_night",this).setValue(C)}else{this._hotelNightNumber=0;$("hotel_night",this).setValue(0)}}catch(B){}};MEB.objects.quick.search.quickSearchForm=new MEB.behaviors.quick.search.SearchForm();c.onLoad("init",MEB.objects.quick.search.quickSearchForm,MEB.objects.quick.search.quickSearchForm._section);c.require("aria");a.namespace("MEB.behaviors");a.namespace("MEB.objects");MEB.behaviors.Slideshow=function(){this._section="slideshow";this._slideShow=null};MEB.behaviors.Slideshow.prototype.init=function(){try{this._slideShow=new SlideShow();this._slideShow.init({id:this._section+"_slider",contentsource:["inline",""],toc:"#increment",nextprev:['<img src="'+MEB.resources.base+'/apps/meb/img/homepage/slideshow/previous.gif" />','<img src="'+MEB.resources.base+'/apps/meb/img/homepage/slideshow/next.gif" />'],enablefade:[true,0.1],autorotate:[true,10000],onChange:function(C,B){}})}catch(A){}};MEB.objects.slideShow=new MEB.behaviors.Slideshow();c.onLoad("init",MEB.objects.slideShow);
