/*    HTTP Host:  static.ak.fbcdn.net                                          */
/*    Generated:  February 10th 2010 12:15:27 AM PST                           */
/*      Machine:  10.16.140.106                                                */
/*       Source:  Backing Store                                                */
/*     Location:  js/ettfh4b1ey0okc04.pkg.js h:24zzd0rd                        */
/*       Locale:  nu_ll                                                        */
/*         Path:  js/ettfh4b1ey0okc04.pkg.js                                   */

if (window.CavalryLogger) { CavalryLogger.start_js(["js\/ettfh4b1ey0okc04.pkg.js"]); }

function ads_refresh(tab,_L1,_L2,_L3,_L4,_L5,_L6){if(window.ads_refreshing)return;if(_L5===undefined)_L5=0;var _L7=['sidebar_ads','home_sponsor_nile'];var _L8=[];for(var i=0;i<_L7.length;i++)if(ge(_L7[i]))_L8.push(_L7[i]);if(_L8.length==0)return;var _La={'page':_L1,'tab':tab,'locations':_L8,'photo_refresh':(_L4?'yes':'no'),'cache':_L5};var _Lb=function(_L6,_Ld){window.ads_refreshing=false;if(!_L6){var _Le=_Ld.getPayload();for(var id in _Le){var elem=ge(id);if(elem&&_Le[id].length>0)if(ua.ie()<7){elem.outerHTML=_Le[id];}else DOM.replace(elem,HTML(_Le[id]));}}if(_L2)_L2(_Ld);}.curry(_L6);var _Lc=function(_Ld){window.ads_refreshing=false;if(_L3)_L3(_Ld);};new AsyncRequest().setURI('/ajax/location_refresh.php').setData(_La).setOption('bundle',true).setHandler(_Lb).setErrorHandler(_Lc).send();window.ads_refreshing=true;}function social_ads_pagecache_log_imps(){var ads=DOM.scry(document,'div.pagecache_social_ad');for(var i=0;i<ads.length;i++){var _L2={'meta':DataStore.get(ads[i],'link_data')};new AsyncRequest().setURI('/ajax/social_ad_impression.php').setOption('bundle',true).setData(_L2).send();}}
function adjustImage(obj){var _L1=obj.parentNode;while(CSS.getStyle(_L1,'display')!='block'&&_L1.parentNode)_L1=_L1.parentNode;var _L2=_L1.offsetWidth;if(obj.offsetWidth>_L2)try{if(ua.ie()<8){var _L3=document.createElement('div');_L3.style.filter='progid:DXImageTransform.Microsoft.AlphaImageLoader(src="'+obj.src.replace('"','%22')+'", sizingMethod="scale")';_L3.style.width=_L2+'px';_L3.style.height=Math.floor(((_L2/obj.offsetWidth)*obj.offsetHeight))+'px';if(obj.parentNode.tagName=='A')_L3.style.cursor='pointer';obj.parentNode.insertBefore(_L3,obj);obj.parentNode.removeChild(obj);}else throw 1;}catch(e){obj.style.width=_L2+'px';}CSS.removeClass(obj,'img_loading');}function imageConstrainSize(src,_L1,_L2,_L3){var _L4=new Image();_L4.onload=function(){if(_L4.width>0&&_L4.height>0){var _L5=_L4.width;var _L6=_L4.height;if(_L5>_L1||_L6>_L2){var _L7=_L2/_L1;var _L8=_L6/_L5;if(_L8>_L7){_L5=_L5*(_L2/_L6);_L6=_L2;}else{_L6=_L6*(_L1/_L5);_L5=_L1;}}var _L9=ge(_L3);if(_L9){var _La=document.createElement('img');_La.src=src;_La.width=_L5;_La.height=_L6;_L9.parentNode.insertBefore(_La,_L9);_L9.parentNode.removeChild(_L9);}}};_L4.src=src;}function image_has_loaded(img){if(img.naturalWidth!==undefined){return img.complete&&img.width!=0;}else if(img.height==20&&img.width==20&&img.complete){return false;}else if(img.complete===undefined&&ua.safari()<500){var _L1=new Image();_L1.src=img.src;return _L1.complete;}return img.complete;}function image_has_failed(obj){if((obj.complete==null&&obj.width==20&&obj.height==20)||(obj.mimeType!=null&&obj.complete&&obj.mimeType=='')||(obj.naturalHeight!=null&&obj.complete&&obj.naturalHeight==0))return true;}
function animation(obj){if(obj==undefined){Util.error("Creating animation on non-existant object");return;}if(this==window){return new animation(obj);}else{this.obj=obj;this._reset_state();this.queue=[];this.last_attr=null;}}animation.resolution=20;animation.offset=0;animation.prototype._reset_state=function(){this.state={attrs:{},duration:500};};animation.prototype.stop=function(){this._reset_state();this.queue=[];return this;};animation.prototype._build_container=function(){if(this.container_div){this._refresh_container();return;}if(this.obj.firstChild&&this.obj.firstChild.__animation_refs){this.container_div=this.obj.firstChild;this.container_div.__animation_refs++;this._refresh_container();return;}var _L0=document.createElement('div');_L0.style.padding='0px';_L0.style.margin='0px';_L0.style.border='0px';_L0.__animation_refs=1;var _L1=this.obj.childNodes;while(_L1.length)_L0.appendChild(_L1[0]);this.obj.appendChild(_L0);this.obj.style.overflow='hidden';this.container_div=_L0;this._refresh_container();};animation.prototype._refresh_container=function(){this.container_div.style.height='auto';this.container_div.style.width='auto';this.container_div.style.height=this.container_div.offsetHeight+'px';this.container_div.style.width=this.container_div.offsetWidth+'px';};animation.prototype._destroy_container=function(){if(!this.container_div)return;if(!--this.container_div.__animation_refs){var _L0=this.container_div.childNodes;while(_L0.length)this.obj.appendChild(_L0[0]);this.obj.removeChild(this.container_div);}this.container_div=null;};animation.ATTR_TO=1;animation.ATTR_BY=2;animation.ATTR_FROM=3;animation.prototype._attr=function(_L0,_L1,_L2){_L0=_L0.replace(/-[a-z]/gi,function(l){return l.substring(1).toUpperCase();});var _L3=false;switch(_L0){case 'background':this._attr('backgroundColor',_L1,_L2);return this;case 'margin':_L1=animation.parse_group(_L1);this._attr('marginBottom',_L1[0],_L2);this._attr('marginLeft',_L1[1],_L2);this._attr('marginRight',_L1[2],_L2);this._attr('marginTop',_L1[3],_L2);return this;case 'padding':_L1=animation.parse_group(_L1);this._attr('paddingBottom',_L1[0],_L2);this._attr('paddingLeft',_L1[1],_L2);this._attr('paddingRight',_L1[2],_L2);this._attr('paddingTop',_L1[3],_L2);return this;case 'backgroundColor':case 'borderColor':case 'color':_L1=animation.parse_color(_L1);break;case 'opacity':_L1=parseFloat(_L1,10);break;case 'height':case 'width':if(_L1=='auto'){_L3=true;}else _L1=parseInt(_L1,10);break;case 'borderWidth':case 'lineHeight':case 'fontSize':case 'marginBottom':case 'marginLeft':case 'marginRight':case 'marginTop':case 'paddingBottom':case 'paddingLeft':case 'paddingRight':case 'paddingTop':case 'bottom':case 'left':case 'right':case 'top':case 'scrollTop':case 'scrollLeft':_L1=parseInt(_L1,10);break;default:throw new Error(_L0+' is not a supported attribute!');}if(this.state.attrs[_L0]===undefined)this.state.attrs[_L0]={};if(_L3)this.state.attrs[_L0].auto=true;switch(_L2){case animation.ATTR_FROM:this.state.attrs[_L0].start=_L1;break;case animation.ATTR_BY:this.state.attrs[_L0].by=true;case animation.ATTR_TO:this.state.attrs[_L0].value=_L1;break;}};animation.prototype.to=function(_L0,_L1){if(_L1===undefined){this._attr(this.last_attr,_L0,animation.ATTR_TO);}else{this._attr(_L0,_L1,animation.ATTR_TO);this.last_attr=_L0;}return this;};animation.prototype.by=function(_L0,_L1){if(_L1===undefined){this._attr(this.last_attr,_L0,animation.ATTR_BY);}else{this._attr(_L0,_L1,animation.ATTR_BY);this.last_attr=_L0;}return this;};animation.prototype.from=function(_L0,_L1){if(_L1===undefined){this._attr(this.last_attr,_L0,animation.ATTR_FROM);}else{this._attr(_L0,_L1,animation.ATTR_FROM);this.last_attr=_L0;}return this;};animation.prototype.duration=function(_L0){this.state.duration=_L0?_L0:0;return this;};animation.prototype.checkpoint=function(_L0,_L1){if(_L0===undefined)_L0=1;this.state.checkpoint=_L0;this.queue.push(this.state);this._reset_state();this.state.checkpointcb=_L1;return this;};animation.prototype.blind=function(){this.state.blind=true;return this;};animation.prototype.hide=function(){this.state.hide=true;return this;};animation.prototype.show=function(){this.state.show=true;return this;};animation.prototype.ease=function(_L0){this.state.ease=_L0;return this;};animation.prototype.go=function(){var _L0=(new Date()).getTime();this.queue.push(this.state);for(var i=0;i<this.queue.length;i++){this.queue[i].start=_L0-animation.offset;if(this.queue[i].checkpoint)_L0+=this.queue[i].checkpoint*this.queue[i].duration;}animation.push(this);return this;};animation.prototype._frame=function(_L0){var _L1=true;var _L2=false;var _L3=false;for(var i=0;i<this.queue.length;i++){var cur=this.queue[i];if(cur.start>_L0){_L1=false;continue;}if(cur.checkpointcb){this._callback(cur.checkpointcb,_L0-cur.start);cur.checkpointcb=null;}if(cur.started===undefined){if(cur.show)this.obj.style.display='block';for(var a in cur.attrs){if(cur.attrs[a].start!==undefined)continue;switch(a){case 'backgroundColor':case 'borderColor':case 'color':var val=animation.parse_color(CSS.getStyle(this.obj,a=='borderColor'?'borderLeftColor':a));if(cur.attrs[a].by){cur.attrs[a].value[0]=Math.min(255,Math.max(0,cur.attrs[a].value[0]+val[0]));cur.attrs[a].value[1]=Math.min(255,Math.max(0,cur.attrs[a].value[1]+val[1]));cur.attrs[a].value[2]=Math.min(255,Math.max(0,cur.attrs[a].value[2]+val[2]));}break;case 'opacity':var val=CSS.getOpacity(this.obj);if(cur.attrs[a].by)cur.attrs[a].value=Math.min(1,Math.max(0,cur.attrs[a].value+val));break;case 'height':var val=DOM.getBoxHeight(this.obj);if(cur.attrs[a].by)cur.attrs[a].value+=val;break;case 'width':var val=DOM.getBoxWidth(this.obj);if(cur.attrs[a].by)cur.attrs[a].value+=val;break;case 'scrollLeft':case 'scrollTop':var val=(this.obj==document.body)?(document.documentElement[a]||document.body[a]):this.obj[a];if(cur.attrs[a].by)cur.attrs[a].value+=val;cur['last'+a]=val;break;default:var val=parseInt(CSS.getStyle(this.obj,a),10)||0;if(cur.attrs[a].by)cur.attrs[a].value+=val;break;}cur.attrs[a].start=val;}if((cur.attrs.height&&cur.attrs.height.auto)||(cur.attrs.width&&cur.attrs.width.auto)){if(ua.firefox()<3)_L3=true;this._destroy_container();for(var a in {height:1,width:1,fontSize:1,borderLeftWidth:1,borderRightWidth:1,borderTopWidth:1,borderBottomWidth:1,paddingLeft:1,paddingRight:1,paddingTop:1,paddingBottom:1})if(cur.attrs[a])this.obj.style[a]=cur.attrs[a].value+(typeof cur.attrs[a].value=='number'?'px':'');if(cur.attrs.height&&cur.attrs.height.auto)cur.attrs.height.value=DOM.getBoxHeight(this.obj);if(cur.attrs.width&&cur.attrs.width.auto)cur.attrs.width.value=DOM.getBoxWidth(this.obj);}cur.started=true;if(cur.blind)this._build_container();}var p=(_L0-cur.start)/cur.duration;if(p>=1){p=1;if(cur.hide)this.obj.style.display='none';}else _L1=false;var pc=cur.ease?cur.ease(p):p;if(!_L2&&p!=1&&cur.blind)_L2=true;if(_L3&&this.obj.parentNode){var _La=this.obj.parentNode;var _Lb=this.obj.nextSibling;_La.removeChild(this.obj);}for(var a in cur.attrs)switch(a){case 'backgroundColor':case 'borderColor':case 'color':this.obj.style[a]='rgb('+animation.calc_tween(pc,cur.attrs[a].start[0],cur.attrs[a].value[0],true)+','+animation.calc_tween(pc,cur.attrs[a].start[1],cur.attrs[a].value[1],true)+','+animation.calc_tween(pc,cur.attrs[a].start[2],cur.attrs[a].value[2],true)+')';break;case 'opacity':CSS.setOpacity(this.obj,animation.calc_tween(pc,cur.attrs[a].start,cur.attrs[a].value));break;case 'height':case 'width':this.obj.style[a]=pc==1&&cur.attrs[a].auto?'auto':animation.calc_tween(pc,cur.attrs[a].start,cur.attrs[a].value,true)+'px';break;case 'scrollLeft':case 'scrollTop':var _Lc=this.obj==document.body;var val=(_Lc)?(document.documentElement[a]||document.body[a]):this.obj[a];if(cur['last'+a]!=val){delete cur.attrs[a];}else{var _Ld=animation.calc_tween(pc,cur.attrs[a].start,cur.attrs[a].value,true)-val;if(DOMScroll.usingScrollWrapper()||!_Lc){this.obj[a]=_Ld+val;}else if(a=='scrollLeft'){window.scrollBy(_Ld,0);}else window.scrollBy(0,_Ld);cur['last'+a]=_Ld+val;}break;default:this.obj.style[a]=animation.calc_tween(pc,cur.attrs[a].start,cur.attrs[a].value,true)+'px';break;}if(p==1){this.queue.splice(i--,1);this._callback(cur.ondone,_L0-cur.start-cur.duration);}}if(_L3)_La[_Lb?'insertBefore':'appendChild'](this.obj,_Lb);if(!_L2&&this.container_div)this._destroy_container();return !_L1;};animation.prototype.ondone=function(fn){this.state.ondone=fn;return this;};animation.prototype._callback=function(_L0,_L1){if(_L0){animation.offset=_L1;_L0.call(this);animation.offset=0;}};animation.calc_tween=function(p,v1,v2,_L3){return (_L3?parseInt:parseFloat)((v2-v1)*p+v1,10);};animation.parse_color=function(_L0){var hex=/^#([a-f0-9]{1,2})([a-f0-9]{1,2})([a-f0-9]{1,2})$/i.exec(_L0);if(hex){return [parseInt(hex[1].length==1?hex[1]+hex[1]:hex[1],16),parseInt(hex[2].length==1?hex[2]+hex[2]:hex[2],16),parseInt(hex[3].length==1?hex[3]+hex[3]:hex[3],16)];}else{var rgb=/^rgba? *\(([0-9]+), *([0-9]+), *([0-9]+)(?:, *([0-9]+))?\)$/.exec(_L0);if(rgb){if(rgb[4]==='0'){return [255,255,255];}else return [parseInt(rgb[1],10),parseInt(rgb[2],10),parseInt(rgb[3],10)];}else if(_L0=='transparent'){return [255,255,255];}else throw 'Named color attributes are not supported.';}};animation.parse_group=function(_L0){var _L0=trim(_L0).split(/ +/);if(_L0.length==4){return _L0;}else if(_L0.length==3){return [_L0[0],_L0[1],_L0[2],_L0[1]];}else if(_L0.length==2){return [_L0[0],_L0[1],_L0[0],_L0[1]];}else return [_L0[0],_L0[0],_L0[0],_L0[0]];};animation.push=function(_L0){if(!animation.active)animation.active=[];animation.active.push(_L0);if(!animation.timeout)animation.timeout=setInterval(animation.animate.bind(animation),animation.resolution,false);animation.animate(true);};animation.animate=function(_L0){var _L1=(new Date()).getTime();for(var i=_L0===true?animation.active.length-1:0;i<animation.active.length;i++)try{if(!animation.active[i]._frame(_L1))animation.active.splice(i--,1);}catch(e){animation.active.splice(i--,1);}if(animation.active.length==0){clearInterval(animation.timeout);animation.timeout=null;}};animation.ease={};animation.ease.begin=function(p){return Math.sin(Math.PI/2*(p-1))+1;};animation.ease.end=function(p){return Math.sin(.5*Math.PI*p);};animation.ease.both=function(p){return .5*Math.sin(Math.PI*(p-.5))+.5;};
function URI(uri){if(uri===window){Util.error('what the hell are you doing');return;}if(this===window)return new URI(uri||window.location.href);this.parse(uri||'');}copy_properties(URI,{getRequestURI:function(_L0,_L1){_L0=_L0===undefined||_L0;if(_L0&&window.PageTransitions&&PageTransitions.isInitialized()){return PageTransitions.getCurrentURI(!!_L1).getQualifiedURI();}else return new URI(window.location.href);},getMostRecentURI:function(){if(window.PageTransitions&&PageTransitions.isInitialized()){return PageTransitions.getMostRecentURI().getQualifiedURI();}else return new URI(window.location.href);},expression:/(((\w+):\/\/)([^\/:]*)(:(\d+))?)?([^#?]*)(\?([^#]*))?(#(.*))?/,arrayQueryExpression:/^(\w+)((?:\[\w*\])+)=?(.*)/,explodeQuery:function(q){if(!q)return {};var _L1={};q=q.replace(/%5B/ig,'[').replace(/%5D/ig,']');q=q.split('&');for(var ii=0,_L3=q.length;ii<_L3;ii++){var _L4=q[ii].match(URI.arrayQueryExpression);if(!_L4){var _L5=q[ii].split('=');_L1[URI.decodeComponent(_L5[0])]=_L5[1]===undefined?null:URI.decodeComponent(_L5[1]);}else{var _L6=_L4[2].split(/\]\[|\[|\]/).slice(0,-1);var _L7=_L4[1];var _L8=URI.decodeComponent(_L4[3]||'');_L6[0]=_L7;var _L9=_L1;for(var i=0;i<_L6.length-1;i++)if(_L6[i]){if(_L9[_L6[i]]===undefined)if(_L6[i+1]&&!_L6[i+1].match(/\d+$/)){_L9[_L6[i]]={};}else _L9[_L6[i]]=[];_L9=_L9[_L6[i]];}else{if(_L6[i+1]&&!_L6[i+1].match(/\d+$/)){_L9.push({});}else _L9.push([]);_L9=_L9[_L9.length-1];}if(_L9 instanceof Array&&_L6[_L6.length-1]==''){_L9.push(_L8);}else _L9[_L6[_L6.length-1]]=_L8;}}return _L1;},implodeQuery:function(obj,_L1,_L2){_L1=_L1||'';if(_L2===undefined)_L2=true;var r=[];if(obj===null||obj===undefined){r.push(_L2?URI.encodeComponent(_L1):_L1);}else if(obj instanceof Array){for(var ii=0;ii<obj.length;++ii)try{if(obj[ii]!==undefined)r.push(URI.implodeQuery(obj[ii],_L1?(_L1+'['+ii+']'):ii));}catch(ignored){}}else if(typeof(obj)=='object'){if(DOM.isNode(obj)){r.push('{node}');}else for(var k in obj)try{if(obj[k]!==undefined)r.push(URI.implodeQuery(obj[k],_L1?(_L1+'['+k+']'):k));}catch(ignored){}}else if(_L2){r.push(URI.encodeComponent(_L1)+'='+URI.encodeComponent(obj));}else r.push(_L1+'='+obj);return r.join('&');},encodeComponent:function(raw){var _L1=String(raw).split(/([\[\]])/);for(var i=0,_L3=_L1.length;i<_L3;i+=2)_L1[i]=window.encodeURIComponent(_L1[i]);return _L1.join('');},decodeComponent:function(_L0){return window.decodeURIComponent(_L0.replace(/\+/g,' '));}});copy_properties(URI.prototype,{parse:function(uri){var m=uri.toString().match(URI.expression);copy_properties(this,{protocol:m[3]||'',domain:m[4]||'',port:m[6]||'',path:m[7]||'',query_s:m[9]||'',fragment:m[11]||''});return this;},setProtocol:function(p){this.protocol=p;return this;},getProtocol:function(){return this.protocol;},setQueryData:function(o){this.query_s=URI.implodeQuery(o);return this;},addQueryData:function(o){return this.setQueryData(copy_properties(this.getQueryData(),o));},removeQueryData:function(_L0){if(!(_L0 instanceof Array))_L0=[_L0];var _L1=this.getQueryData();for(var i=0,_L3=_L0.length;i<_L3;++i)delete _L1[_L0[i]];return this.setQueryData(_L1);},getQueryData:function(){return URI.explodeQuery(this.query_s);},setFragment:function(f){this.fragment=f;return this;},getFragment:function(){return this.fragment;},setDomain:function(d){this.domain=d;return this;},getDomain:function(){return this.domain;},setPort:function(p){this.port=p;return this;},getPort:function(){return this.port;},setPath:function(p){this.path=p;return this;},getPath:function(){return this.path.replace(/^\/+/,'/');},toString:function(){var r='';this.protocol&&(r+=this.protocol+'://');this.domain&&(r+=this.domain);this.port&&(r+=':'+this.port);if(this.domain&&!this.path)r+='/';this.path&&(r+=this.path);this.query_s&&(r+='?'+this.query_s);this.fragment&&(r+='#'+this.fragment);return r;},valueOf:function(){return this.toString();},isFacebookURI:function(){if(!URI._facebookURIRegex)URI._facebookURIRegex=new RegExp('(^|\.)facebook\.('+env_get('tlds').join('|')+')([^.]*)$','i');return !this.domain||URI._facebookURIRegex.test(this.domain);},isQuicklingEnabled:function(){return window.Quickling&&Quickling.isActive()&&Quickling.isPageActive(this);},getRegisteredDomain:function(){if(!this.domain)return '';if(!this.isFacebookURI())return null;var _L0=this.domain.split('.');var _L1=_L0.indexOf('facebook');return _L0.slice(_L1).join('.');},getTld:function(_L0){if(!this.domain)return '';var _L1=this.domain.split('.');var tld=_L1[_L1.length-1];if(_L0)return tld;var _L3=env_get('tlds');if(_L3.indexOf(tld)==-1)for(var i=0;i<_L3.length;++i){var _L5=_L3[i];if(new RegExp(_L5+'$').test(this.domain)){tld=_L5;break;}}return tld;},getUnqualifiedURI:function(){return new URI(this).setProtocol(null).setDomain(null).setPort(null);},getQualifiedURI:function(){var uri=new URI(this);if(!uri.getDomain()){var _L1=URI();uri.setProtocol(_L1.getProtocol()).setDomain(_L1.getDomain()).setPort(_L1.getPort());}return uri;},isSameOrigin:function(_L0){var uri=_L0||window.location.href;if(!(uri instanceof URI))uri=new URI(uri.toString());if(this.getProtocol()&&this.getProtocol()!=uri.getProtocol())return false;if(this.getDomain()&&this.getDomain()!=uri.getDomain())return false;return true;},coerceToSameOrigin:function(_L0){var uri=_L0||window.location.href;if(!(uri instanceof URI))uri=new URI(uri.toString());if(this.isSameOrigin(uri))return true;if(this.getProtocol()!=uri.getProtocol())return false;var dst=uri.getDomain().split('.');var src=this.getDomain().split('.');var _L4;if(uri.isFacebookURI())while((_L4=dst.pop())&&_L4==src.pop())if(_L4=='facebook'){this.setDomain(uri.getDomain());return true;}return false;},go:function(){goURI(this);},setSubdomain:function(_L0){var uri=new URI(this).getQualifiedURI();var _L2=uri.getDomain().split('.');if(_L2.length<=2){_L2.unshift(_L0);}else _L2[0]=_L0;return uri.setDomain(_L2.join('.'));},getSubdomain:function(){if(!this.getDomain())return '';var _L0=this.getDomain().split('.');if(_L0.length<=2){return '';}else return _L0[0];}});
function intl_set_xmode(_L0){(new AsyncRequest()).setURI('/ajax/intl/save_xmode.php').setData({xmode:_L0}).setHandler(function(){document.location.reload();}).send();}function intl_set_cmode(_L0){(new AsyncRequest()).setURI('/ajax/intl/save_xmode.php').setData({cmode:_L0}).setHandler(function(){document.location.reload();}).send();}function intl_set_vmode(_L0){(new AsyncRequest()).setURI('/ajax/intl/save_xmode.php').setData({vmode:_L0}).setHandler(function(){document.location.reload();}).send();}function intl_set_amode(_L0){(new AsyncRequest()).setURI('/ajax/intl/save_xmode.php').setData({amode:_L0,app:false}).setHandler(function(){document.location.reload();}).send();}function intl_set_pmode(_L0){CSS.toggleClass($('translations_nub'),'pnub');if(_L0==0){CSS.addClass($('progress_check'),'progress_hidden');CSS.removeClass($('progress_check'),'progress_shown');}else{CSS.addClass($('progress_check'),'progress_shown');CSS.removeClass($('progress_check'),'progress_hidden');}(new AsyncRequest()).setURI('/ajax/intl/save_xmode.php').setData({pmode:_L0}).setHandler(function(){}).send();}function intl_set_locale(obj,_L1,_L2){if(!_L2)var _L2=obj.options[obj.selectedIndex].value;intl_save_locale(_L2,true,null,_L1);}function intl_save_locale(_L0,_L1,_L2,_L3){new AsyncRequest().setURI('/ajax/intl/save_locale.php').setData({locale:_L0,source:_L3}).setHandler(function(_L4){if(_L1){document.location.reload();}else goURI(_L2);}).send();}function intl_toggle_beta_locale_install(obj){if(obj.checked){show($('beta_locale_install'));}else hide($('beta_locale_install'));}function intl_set_cookie_locale(_L0,uri,_L2){var _L3=getCookie('locale');new AsyncRequest().setURI('/ajax/intl/save_locale_cookie_logging.php').setData({'new_locale':_L0,'old_locale':_L3,'source':_L2}).setReadOnly(true).send();setCookie('locale',_L0,7*24*3600000);if(URI.getRequestURI().getTld()!='com'){transferCookieToComTld('locale',function(_L4){if(_L4)clearCookie('locale');goURI(uri);});}else goURI(uri);}function intl_disable_rooster_save(obj){var _L1=document.getElementById('install_translation_app');_L1.disabled=!obj.checked;var _L2=document.getElementById('install_container');if(obj.checked){_L2.style.display='block';}else _L2.style.display='none';}function intl_confirm_rooster_and_install_app(uid,_L1){goURI('/add.php?api_key=efa7a7045708fcadede8d705e39b1642');}function intl_locale_is_rtl(){return ('rtl'==CSS.getStyle(document.body,'direction'));}function intl_is_left_click(e){if(e.which==null){if(e.button<2&&!e.ctrlKey)return true;}else if(e.which<2&&!e.ctrlKey)return true;return false;}function intl_left_click_cancelBubble(e){if(intl_is_left_click(e))e.cancelBubble=true;}
function getRadioFormValue(obj){for(i=0;i<obj.length;i++)if(obj[i].checked)return obj[i].value;return null;}function get_all_form_inputs(_L0){_L0=_L0||document;return [].concat($A(DOM.scry(_L0,'input')),$A(DOM.scry(_L0,'select')),$A(DOM.scry(_L0,'textarea')),$A(DOM.scry(_L0,'button')));}function get_form_select_value(_L0){return _L0.options[_L0.selectedIndex].value;}function set_form_select_value(_L0,_L1){for(var i=0;i<_L0.options.length;++i)if(_L0.options[i].value==_L1){_L0.selectedIndex=i;break;}}function get_form_attr(_L0,_L1){var val=_L0[_L1];if(typeof val=='object'&&val.tagName=='INPUT'){var pn=val.parentNode,ns=val.nextSibling,_L5=val;pn.removeChild(_L5);val=_L0[_L1];ns?pn.insertBefore(_L5,ns):pn.appendChild(_L5);}return val;}function serialize_form_helper(_L0,_L1,_L2){var _L3=/([^\]]+)\[([^\]]*)\](.*)/.exec(_L1);if(_L3){_L0[_L3[1]]=_L0[_L3[1]]||{};if(_L3[2]==''){var i=0;while(_L0[_L3[1]][i]!=undefined)i++;}else i=_L3[2];if(_L3[3]==''){_L0[_L3[1]][i]=_L2;}else serialize_form_helper(_L0[_L3[1]],i.concat(_L3[3]),_L2);}else _L0[_L1]=_L2;}function serialize_form_fix(_L0){var _L1=[];for(var i in _L0){if(_L0 instanceof Object)_L0[i]=serialize_form_fix(_L0[i]);_L1.push(i);}var j=0,_L4=true;_L1.sort().each(function(i){if(i!=j++)_L4=false;});if(_L4){var ret={};_L1.each(function(i){ret[i]=_L0[i];});return ret;}else return _L0;}function form_get_elements(obj){return $A(obj.tagName=='FORM'?obj.elements:get_all_form_inputs(obj));}function serialize_form(obj,_L1){var _L2={};form_get_elements(obj).forEach(function(_L3){if(_L3.name&&!_L3.disabled&&_L3.type!='submit')if(!_L3.type||((_L3.type=='radio'||_L3.type=='checkbox')&&_L3.checked)||_L3.type=='text'||_L3.type=='password'||_L3.type=='hidden'||_L3.tagName=='TEXTAREA'||_L3.tagName=='SELECT')serialize_form_helper(_L2,_L3.name,_L3.value);});if(_L1&&'submit'==_L1.type&&DOM.contains(obj,_L1)&&DOM.isNode(_L1,['input','button']))serialize_form_helper(_L2,_L1.name,_L1.value);return serialize_form_fix(_L2);}function form_set_disabled(_L0,_L1){form_get_elements(_L0).forEach(function(_L2){if(_L2.disabled!=undefined)if(_L1){DataStore.set(_L2,'origDisabledState',_L2.disabled);_L2.disabled=_L1;}else{if(DataStore.get(_L2,'origDisabledState')!==true)_L2.disabled=false;DataStore.remove(_L2,'origDisabledState');}});}function bootstrap_form(_L0,_L1){var _L2=_L0.method.toUpperCase();_L1=DOM.getNearest(_L1,['input','button']);var _L3=serialize_form(_L0,_L1);form_set_disabled(_L0,true);var _L4=_L0;if(CSS.hasClass(_L1,'stat_elem'))_L4=_L1;new AsyncRequest(_L0.action).setData(_L3).setReadOnly(_L2=='GET').setMethod(_L2).setHandler(AsyncRequest.responseOpsHandler.bind(null,_L0)).setStatusElement(_L4).setFinallyHandler(form_set_disabled.bind(null,_L0,false)).send();}function do_post(uri){var _L1=/(^([^?])+)\??(.*)$/.exec(uri.toString());var _L2=document.createElement('form');_L2.action=_L1[1];_L2.method='post';_L2.style.display='none';var _L3=/([\w]+)(?:=([^&]+)|&|$)/g;var _L4=null;if(ge('post_form_id'))_L1[3]+='&post_form_id='+$('post_form_id').value;if(ge('fb_dtsg'))_L1[3]+='&fb_dtsg='+$('fb_dtsg').value;while(_L4=_L3.exec(_L1[3])){var _L5=document.createElement('input');_L5.type='hidden';_L5.name=decodeURIComponent(_L4[1]);_L5.value=decodeURIComponent(_L4[2]);_L2.appendChild(_L5);}DOM.getRootElement().appendChild(_L2);_L2.submit();return false;}function dynamic_post(uri,_L1,_L2){var _L3=document.createElement('form');_L3.action=uri.toString();_L3.method='POST';_L3.style.display='none';if(_L2)_L3.target=_L2;if(ge('post_form_id'))_L1['post_form_id']=$('post_form_id').value;if(ge('fb_dtsg'))_L1['fb_dtsg']=$('fb_dtsg').value;_L1['post_form_id_source']='dynamic_post';_L1['next']=htmlspecialchars(document.location.href);create_hidden_inputs(_L1,_L3);DOM.getRootElement().appendChild(_L3);_L3.submit();return false;}function create_hidden_inputs(_L0,_L1,_L2,_L3){_L2=_L2||{};var _L4;var _L5=URI.implodeQuery(_L0,'',false);var _L6=_L5.split('&');for(var i=0;i<_L6.length;i++)if(_L6[i]){var _L8=_L6[i].split('=');var n=_L8[0];var v=_L8[1];if(n===undefined||v===undefined)continue;v=URI.decodeComponent(v);if(_L2[n]&&_L3){_L2[n].value=v;}else{_L4=$N('input',{type:'hidden',name:n,value:v});_L2[n]=_L4;_L1.appendChild(_L4);}}return _L2;}
function KeyEventController(){copy_properties(this,{handlers:{}});document.onkeyup=this.onkeyevent.bind(this,'onkeyup');document.onkeydown=this.onkeyevent.bind(this,'onkeydown');document.onkeypress=this.onkeyevent.bind(this,'onkeypress');}copy_properties(KeyEventController,{instance:null,getInstance:function(){return KeyEventController.instance||(KeyEventController.instance=new KeyEventController());},defaultFilter:function(_L0,_L1){_L0=$E(_L0);return KeyEventController.filterEventTypes(_L0,_L1)&&KeyEventController.filterEventTargets(_L0,_L1)&&KeyEventController.filterEventModifiers(_L0,_L1);},filterEventTypes:function(_L0,_L1){if(_L1==='onkeydown')return true;return false;},filterEventTargets:function(_L0,_L1){var _L2=$E(_L0).getTarget();if(DOM.isNode(_L2,['input','select','textarea','object','embed']))if(_L2.type!='checkbox'&&_L2.type!='radio')return false;return true;},filterEventModifiers:function(_L0,_L1){if(_L0.ctrlKey||_L0.altKey||_L0.metaKey||_L0.repeat)return false;return true;},registerKey:function(key,_L1,_L2){if(_L2===undefined)_L2=KeyEventController.defaultFilter;var ctl=KeyEventController.getInstance();var eqv=ctl.mapKey(key);if(is_empty(ctl.handlers))onunloadRegister(ctl.resetHandlers.bind(ctl));for(var ii=0;ii<eqv.length;ii++){key=eqv[ii];if(!ctl.handlers[key])ctl.handlers[key]=[];ctl.handlers[key].push({callback:_L1,filter:_L2});}},keyCodeMap:{'[':[219],']':[221],'`':[192],'LEFT':[KEYS.LEFT,63234],'RIGHT':[KEYS.RIGHT,63235],'RETURN':[KEYS.RETURN],'TAB':[KEYS.TAB],'DOWN':[KEYS.DOWN,63233],'UP':[KEYS.UP,63232],'ESCAPE':[KEYS.ESC]}});copy_properties(KeyEventController.prototype,{mapKey:function(k){if(typeof(k)=='number')return [48+k,96+k];if(KeyEventController.keyCodeMap[k.toUpperCase()])return KeyEventController.keyCodeMap[k.toUpperCase()];var u=k.toUpperCase().charCodeAt(0);return [u];},onkeyevent:function(_L0,e){e=$E(e);var evt=null;var _L3=this.handlers[e.keyCode];var _L4,_L5,_L6;if(_L3)for(var ii=0;ii<_L3.length;ii++){_L4=_L3[ii].callback;_L5=_L3[ii].filter;try{if(!_L5||_L5(e,_L0)){_L6=_L4(e,_L0);if(_L6===false)return Event.kill(e);}}catch(exception){Util.error('Uncaught exception in key handler: %x',exception);}}return true;},resetHandlers:function(){this.handlers={};}});
function Rect(t,r,b,l,_L4){if(this===window){if(t instanceof Rect)return t;if(t instanceof Vector2)return new Rect(t.y,t.x,t.y,t.x,t.domain);return Rect.getElementBounds($(t));}copy_properties(this,{t:t,r:r,b:b,l:l,domain:_L4||'pure'});}copy_properties(Rect.prototype,{w:function(){return this.r-this.l;},h:function(){return this.b-this.t;},area:function(){return this.w()*this.h();},toString:function(){return '(('+this.l+', '+this.t+'), ('+this.r+', '+this.b+'))';},intersects:function(v){v=Rect(v).convertTo(this.domain);var u=this;if(u.l>v.r||v.l>u.r||u.t>v.b||v.t>u.b)return false;return true;},clipTo:function(_L0){_L0=_L0.convertTo(this.domain);if(!this.intersects(_L0))return null;return new Rect(Math.max(this.t,_L0.t),Math.min(this.r,_L0.r),Math.min(this.b,_L0.b),Math.max(this.l,_L0.l),this.domain);},contains:function(v){v=Rect(v).convertTo(this.domain);var u=this;if(v instanceof Vector2){return (u.l<=v.x&&u.r>=v.x&&u.t<=v.y&&u.b>=v.y);}else return (u.l<=v.l&&u.r>=u.r&&u.t<=v.t&&u.b>=v.b);},canContain:function(v){v=Rect(v).convertTo(this.domain);return (v.h()<=this.h())&&(v.w()<=this.w());},forceBelow:function(v,min){min=min||0;v=Rect(v).convertTo(this.domain);if(v.b>this.t)return this.add(0,(v.b-this.t)+min);return this;},add:function(vx,vy){if(arguments.length==1){if(vx.domain!='pure')vx=vx.convertTo(this.domain);return this.add(vx.x,vx.y);}var dx=parseFloat(vx);var dy=parseFloat(vy);return new Rect(this.t+dy,this.r+dx,this.b+dy,this.l+dx,this.domain);},sub:function(vx,vy){if(arguments.length==1){return this.add(vx.mul(-1));}else return this.add(-vx,-vy);},expand:function(x,y){return new Rect(this.t,this.r+x,this.b+y,this.l,this.domain);},scale:function(x,y){y=y||x;return new Rect(this.t,this.l+(this.w()*x),this.t+(this.h()*y),this.l,this.domain);},setDimensions:function(x,y){return new Rect(this.t,this.l+x,this.t+y,this.l,this.domain);},setPosition:function(x,y){return new Rect(x,this.w(),this.h(),y,this.domain);},boundWithin:function(v){var x=0,y=0;if(this.l<v.l){x=v.l-this.l;}else if(this.r>v.r)x=v.r-this.r;if(this.t<v.t){y=v.t-this.t;}else if(this.b>v.b)y=v.b-this.b;return this.add(x,y);},setElementBounds:function(el){this.getPositionVector().setElementPosition(el);this.getDimensionVector().setElementDimensions(el);return this;},getPositionVector:function(){return new Vector2(this.l,this.t,this.domain);},getDimensionVector:function(){return new Vector2(this.w(),this.h(),'pure');},convertTo:function(_L0){if(this.domain==_L0)return this;if(_L0=='pure')return new Rect(this.t,this.r,this.b,this.l,'pure');if(this.domain=='pure'){Util.error('Unable to convert a pure rect to %q coordinates.',_L0);return new Rect(0,0,0,0);}var p=new Vector2(this.l,this.t,this.domain).convertTo(_L0);return new Rect(p.y,p.x+this.w(),p.y+this.h(),p.x,_L0);},constrict:function(x,y){if(typeof(y)=='undefined')y=x;x=x||0;return new Rect(this.t+y,this.r-x,this.b-y,this.l+x,this.domain);},expandX:function(){return new Rect(this.t,Number.POSITIVE_INFINITY,this.b,Number.NEGATIVE_INFINITY);},expandY:function(){return new Rect(number.NEGATIVE_INFINITY,this.r,Number.POSITIVE_INFINITY,this.l);},drawBox:function(_L0){var d=$N('div',{style:{position:'absolute',border:'2px solid '+(_L0||'red'),zIndex:'10000'}});this.setElementBounds(d);document.body.appendChild(d);}});copy_properties(Rect,{newFromVectors:function(pos,dim){return new Rect(pos.y,pos.x+dim.x,pos.y+dim.y,pos.x,pos.domain);},getElementBounds:function(el){return Rect.newFromVectors(Vector2.getElementPosition(el),Vector2.getElementDimensions(el));},getViewportBounds:function(){return Rect.newFromVectors(Vector2.getScrollPosition(),Vector2.getViewportDimensions());},getDocumentBounds:function(){return Rect.newFromVectors(new Vector2(0,0,'document'),Vector2.getDocumentDimensions());}});
function Dialog(_L0){Dialog._setup();this._show_loading=true;this._loading_text=null;this._auto_focus=true;this._fade_enabled=true;this._onload_handlers=[];this._top=125;this._content=null;this._obj=null;this._popup=null;this._overlay=null;this._iframe=null;this._hidden_objects=[];if(_L0)this._setFromModel(_L0);}copy_properties(Dialog,{OK:{name:'ok',label:_tx("Oke")},CANCEL:{name:'cancel',label:_tx("Batalkan"),className:'inputaux'},CLOSE:{name:'close',label:_tx("Tutup")},NEXT:{name:'next',label:_tx("Berikutnya")},SAVE:{name:'save',label:_tx("Simpan")},SUBMIT:{name:'submit',label:_tx("Kirim")},CONFIRM:{name:'confirm',label:_tx("Konfirmasi")},DELETE:{name:'delete',label:_tx("Hapus")}});copy_properties(Dialog,{OK_AND_CANCEL:[Dialog.OK,Dialog.CANCEL],_STANDARD_BUTTONS:[Dialog.OK,Dialog.CANCEL,Dialog.CLOSE,Dialog.SAVE,Dialog.SUBMIT,Dialog.CONFIRM,Dialog.DELETE],SHOULD_HIDE_OBJECTS:!ua.windows(),MODALITY:{DARK:'dark',WHITE:'white'},SHOULD_USE_IFRAME:ua.ie()<7||(ua.osx()&&ua.firefox()),dialogStack:null,newButton:function(_L0,_L1,_L2,_L3){var _L4={name:_L0,label:_L1};if(_L2)_L4.className=_L2;if(_L3)_L4.handler=_L3;return _L4;},getCurrent:function(){var _L0=Dialog.dialogStack;if(!_L0||!_L0.length)return null;return _L0[_L0.length-1];},createConfirmationDialog:function(_L0,_L1,_L2,_L3){_L2=_L2||Dialog.CONFIRM;return new Dialog().setClassName('confirm_dialog').setTitle(_L1||_tx("Perlu Konfirmasi")).setBody(_L0||_tx("Apakah Anda yakin akan melakukan tindakan ini?")).setButtons([_L2,Dialog.CANCEL]).setCancelHandler(_L3||bagofholding).setModal();},bootstrap:function(uri,_L1,_L2,_L3,_L4){_L1=_L1||{};copy_properties(_L1,new URI(uri).getQueryData());_L3=_L3||(_L2?'GET':'POST');var _L5=new Dialog(_L4).setAsync(new AsyncRequest().setURI(uri).setData(_L1).setReadOnly(!!_L2).setMethod(_L3));_L5.show();return false;},showFormAjax:function(_L0,uri,_L2,_L3){var _L4='dialog_ajax_form__'+(+new Date());var _L5=new Dialog().setTitle(_L0).setShowLoading(true).show();var _L6=function(_Lb){if(_Lb.getError()!=true){_L5.hide();ErrorDialog.showAsyncError(_Lb);}else _L5.setBody(_Lb.getPayload()).setButtons(Dialog.OK).clearHandler().show();};var _L7=function(_Lb){var _Lc='<form id="'+_L4+'" onsubmit="return false;">'+_Lb.getPayload()+'</form>';var _Ld=[Dialog.newButton(_L2.toLowerCase(),_L2),Dialog.CANCEL];_L5.setBody(_Lc).setButtons(_Ld).setHandler(_L8).show();};var _L8=function(){new AsyncRequest().setURI(uri).setData(serialize_form(ge(_L4))).setHandler(_L9).setErrorHandler(_La).send();};var _L9=function(_Lb){_L5.setBody(_Lb.getPayload()).setButtons([Dialog.OK]).show();if(_L3){window.location.reload();}else _L5.setAutohide(750);};var _La=function(_Lb){if(_Lb.getError()==kError_Global_ValidationError){_L7(_Lb);}else if(_Lb.getError()!=true){ErrorDialog.showAsyncError(_Lb);}else _L6(_Lb);};new AsyncRequest().setURI(uri).setReadOnly(true).setHandler(_L7).setErrorHandler(_L6).send();},_basicMutator:function(_L0){return function(_L1){this[_L0]=_L1;this._dirty();return this;};},_findButton:function(_L0,_L1){if(_L0)for(var i=0;i<_L0.length;++i)if(_L0[i].name==_L1)return _L0[i];return null;},_setup:function(){if(Dialog._is_set_up)return;Dialog._is_set_up=true;var _L0=function(_L1,_L2){return _L2=='onkeyup'&&KeyEventController.filterEventModifiers(_L1,_L2);};KeyEventController.registerKey('ESCAPE',Dialog._handleEscapeKey,_L0);},_hideAll:function(){if(Dialog.dialogStack!==null&&Dialog.dialogStack.length){var _L0=Dialog.dialogStack.clone();Dialog.dialogStack=null;for(var i=_L0.length-1;i>=0;i--)_L0[i].hide();}},_handleEscapeKey:function(_L0,_L1){var _L2=Dialog.getCurrent();if(!_L2)return true;var _L3=_L2._semi_modal;var _L4=_L2._buttons;if(!_L4&&!_L3)return true;if(_L3&&!_L4){_L2.hide();return true;}var _L5=Dialog._findButton(_L4,'cancel');if(_L5){var _L6=_L5;}else if(_L4.length==1){var _L6=_L4[0];}else return true;_L2._handleButton(_L6);return false;},call_or_eval:function(obj,func,args){if(!func)return undefined;args=args||{};if(typeof(func)=='string'){var params=keys(args).join(', ');func=eval('({f: function('+params+') { '+func+'}})').f;}return func.apply(obj,values(args));}});copy_properties(Dialog.prototype,{show:function(_L0){this._showing=true;if(_L0){if(this._overlay)this._overlay.style.display='';if(this._iframe)this._iframe.style.display='';this._obj.style.display='';}else this._dirty();return this;},showLoading:function(){this._renderDialog($N('div',{className:'dialog_loading'},this._loading_text||_tx("Memuat...")));return this;},hide:function(_L0){if(!this._showing)return this;this._showing=false;if(this._autohide_timeout){clearTimeout(this._autohide_timeout);this._autohide_timeout=null;}if(this._fade_enabled&&(!Dialog.dialogStack||Dialog.dialogStack.length<=1)){this._fadeOut(_L0);}else this._hide(_L0);return this;},fade_out:function(_L0){this.setAutohide(_L0);return this;},getRoot:function(){return this._obj;},getButtonElement:function(_L0){if(typeof _L0=='string')_L0=Dialog._findButton(this._buttons,_L0);if(!_L0||!_L0.name)return null;var _L1=DOM.scry(this._popup,'input');var _L2=function(_L3){return _L3.name==_L0.name;};return _L1.filter(_L2)[0]||null;},getContentNode:function(){var _L0=DOM.scry(this._content,'div.dialog_content');if(_L0.length!=1)Util.error(_L0.length+" dialog_content divs in this dialog?  Weird.");return _L0[0];},getFormData:function(){return serialize_form(this.getContentNode());},setShowing:function(){this.show();return this;},setHiding:function(){this.hide();return this;},setTitle:Dialog._basicMutator('_title'),setBody:Dialog._basicMutator('_body'),setExtraData:Dialog._basicMutator('_extra_data'),setShowLoading:Dialog._basicMutator('_show_loading'),setLoadingText:Dialog._basicMutator('_loading_text'),setFullBleed:Dialog._basicMutator('_full_bleed'),setImmediateRendering:Dialog._basicMutator('_immediate_rendering'),setUserData:Dialog._basicMutator('_user_data'),getUserData:function(){return this._user_data;},setAutohide:function(_L0){if(_L0){if(this._showing){this._autohide_timeout=setTimeout(this.hide.shield(this),_L0);}else this._autohide=_L0;}else{this._autohide=null;if(this._autohide_timeout){clearTimeout(this._autohide_timeout);this._autohide_timeout=null;}}return this;},setSummary:Dialog._basicMutator('_summary'),setButtons:function(b){var _L1;if(!(b instanceof Array)){_L1=Array.from(arguments);}else _L1=b;for(var i=0;i<_L1.length;++i)if(typeof _L1[i]=='string'){var _L3=Dialog._findButton(Dialog._STANDARD_BUTTONS,_L1[i]);if(!_L3)Util.error('Unknown button: '+_L1[i]);_L1[i]=_L3;}this._buttons=_L1;this._dirtyButtons();return this;},setButtonsMessage:Dialog._basicMutator('_buttons_message'),setStackable:function(_L0,_L1){this._is_stackable=_L0;this._shown_while_stacked=_L0&&_L1;return this;},setHandler:function(_L0){this._handler=_L0;return this;},setCancelHandler:function(_L0){this._cancelHandler=_L0;return this;},setCloseHandler:function(_L0){this._close_handler=Dialog.call_or_eval.bind(null,this,_L0);return this;},clearHandler:function(){return this.setHandler(null);},setPostURI:function(_L0,_L1){if(_L1===undefined)_L1=true;if(_L1){this.setHandler(this._submitForm.bind(this,'POST',_L0));}else this.setHandler(function(){dynamic_post(_L0,this.getFormData());this.hide();}.bind(this));return this;},setGetURI:function(_L0){this.setHandler(this._submitForm.bind(this,'GET',_L0));return this;},setModal:function(_L0,_L1){if(_L0===undefined)_L0=true;if(this._showing&&this._modal&&!_L0)Util.error("At the moment we don't support un-modal-ing a modal dialog");if(_L0&&_L1)switch(_L1){case Dialog.MODALITY.DARK:this._modal_class='dark_dialog_overlay';break;case Dialog.MODALITY.WHITE:this._modal_class='light_dialog_overlay';break;}this._modal=_L0;return this;},setSemiModal:function(_L0){if(_L0===undefined)_L0=true;if(_L0)this.setModal(true,Dialog.MODALITY.DARK);this._semi_modal=_L0;return this;},setContentWidth:Dialog._basicMutator('_content_width'),setTitleLoading:function(_L0){if(_L0===undefined)_L0=true;var _L1=DOM.find(this._popup,'h2.dialog_title');if(_L1)CSS.conditionClass(_L1,'loading',_L0);return this;},setClassName:Dialog._basicMutator('_class_name'),setFading:Dialog._basicMutator('_fade_enabled'),setFooter:Dialog._basicMutator('_footer'),setAutoFocus:Dialog._basicMutator('_auto_focus'),setTop:Dialog._basicMutator('_top'),onloadRegister:function(_L0){arrayize(_L0).forEach(function(i){if(typeof i=='string')i=new Function(i);this._onload_handlers.push(i.bind(this));}.bind(this));return this;},setAsyncURL:function(url){return this.setAsync(new AsyncRequest(url));},setAsync:function(_L0){var _L1=function(_L4){if(this._async_request!=_L0)return;this._async_request=null;var _L5=_L4.getPayload();if(typeof _L5=='string'){this.setBody(_L5);}else this._setFromModel(_L5);this._update(true);}.bind(this);var _L2=_L0.getData();_L2.__d=1;_L0.setData(_L2);var _L3=bind(this,'hide');_L0.setHandler(chain(_L0.getHandler(),_L1)).setErrorHandler(chain(_L3,_L0.getErrorHandler())).setTransportErrorHandler(chain(_L3,_L0.getTransportErrorHandler())).send();this._async_request=_L0;this._dirty();return this;},_dirty:function(){if(!this._is_dirty){this._is_dirty=true;if(this._immediate_rendering){this._update();}else bind(this,'_update').defer();}},_dirtyButtons:function(){if(this._immediate_rendering){this._updateButtons();}else bind(this,'_updateButtons').defer();},_format:function(_L0){if(typeof _L0=='string')return HTML(_L0).setDeferred(true);return _L0;},_update:function(_L0){if(!this._is_dirty&&_L0!==true)return;this._is_dirty=false;if(!this._showing)return;if(this._autohide&&!this._async_request&&!this._autohide_timeout)this._autohide_timeout=setTimeout(bind(this,'hide'),this._autohide);if(!this._async_request||!this._show_loading){var _L1=[];if(this._summary)_L1.push($N('div',{className:'dialog_summary'},this._format(this._summary)));_L1.push($N('div',{className:'dialog_body'},this._format(this._body)));var _L2=this._getButtonContent();if(_L2.length)_L1.push($N('div',{className:'dialog_buttons'},_L2));if(this._footer)_L1.push($N('div',{className:'dialog_footer'},this._format(this._footer)));_L1=$N('div',{className:'dialog_content'},_L1);if(this._title){var _L3=$N('h2',{className:'dialog_title'},$N('span',this._format(this._title)));_L1=[_L3,_L1];}else _L1=[_L1];this._renderDialog(_L1);for(var i=0;i<this._onload_handlers.length;++i)try{this._onload_handlers[i]();}catch(ex){Util.error('Uncaught exception in dialog onload hook: %x',ex);}this._onload_handlers=[];}else this.showLoading();if(this._content_width)this._popup.style.width=(this._content_width+42)+'px';},_updateButtons:function(){if(!this._showing)return;var _L0=this._getButtonContent();var _L1=$N('div',{className:'dialog_buttons'},_L0);var _L2=DOM.scry(this._content,'div.dialog_buttons')[0]||null;if(!_L2){var _L3=DOM.scry(this._content,'div.dialog_body')[0]||null;if(_L3)DOM.insertAfter(_L3,_L1);return;}DOM.replace(_L2,_L1);},_getButtonContent:function(){var _L0=[];if((this._buttons&&this._buttons.length>0)||this._buttons_message){var _L0=[];if(this._buttons_message)_L0.push($N('div',{className:'dialog_buttons_msg'},this._format(this._buttons_message)));if(this._buttons)for(var i=0;i<this._buttons.length;i++){var _L2=this._buttons[i];var _L3=$N('input',{className:'inputsubmit',type:'button',name:_L2.name||'',value:_L2.label});CSS.addClass(_L3,_L2.className);_L3.listen('click',this._handleButton.bind(this,_L2.name));_L0.push(_L3);}}return _L0;},_shouldUseIframe:function(){return Dialog.SHOULD_USE_IFRAME||(this._modal&&ua.ie()==7);},_renderDialog:function(_L0){if(Dialog.dialogStack===null)onunloadRegister(Dialog._hideAll,true);if(!this._obj)this._buildDialog();if(this._class_name)CSS.addClass(this._obj,this._class_name);CSS.conditionClass(this._obj,'full_bleed',this._full_bleed);if(typeof _L0=='string')_L0=HTML(_L0).setDeferred(this._immediate_rendering!==true);DOM.setContent(this._content,_L0);var _L1=this._content.getElementsByTagName('img');for(var i=0;i<_L1.length;i++)_L1[i].onload=chain(_L1[i].onload,this._hideObjects.bind(this));this._showDialog();if(this._auto_focus)this._focusFirstTextboxOrButton.bind(this).defer();return this;},_buildDialog:function(){this._obj=$N('div',{className:'generic_dialog'});this._obj.style.display='none';DOM.getRootElement().appendChild(this._obj);if(this._shouldUseIframe())this._buildIframe();if(!this._popup)this._popup=$N('div',{className:'generic_dialog_popup'});this._popup.style.left=this._popup.style.top='';this._obj.appendChild(this._popup);this._buildDialogContent();},_showDialog:function(){if(this._modal)if(this._overlay){this._overlay.style.display='';}else this._buildOverlay();if(this._obj&&this._obj.style.display){this._obj.style.visibility='hidden';this._obj.style.display='';this._resetDialog();this._obj.style.visibility='';this._obj.dialog=this;}else this._resetDialog();this._hideObjects();clearInterval(this.active_hiding);this.active_hiding=setInterval(this._activeResize.bind(this),500);if(!Dialog.dialogStack)Dialog.dialogStack=[];var _L0=Dialog.dialogStack;if(_L0.length){var _L1=_L0[_L0.length-1];if(_L1!=this&&!_L1._is_stackable)_L1._hide();for(var i=_L0.length-1;i>=0;i--)if(_L0[i]==this){_L0.splice(i,1);}else if(!_L0[i]._shown_while_stacked)_L0[i]._hide(true);}_L0.push(this);return this;},_activeResize:function(){if(this.last_offset_height!=this._content.offsetHeight){this._hideObjects();this.last_offset_height=this._content.offsetHeight;}},_hideObjects:function(){var _L0=[],_L1=[];var _L2=Rect.getElementBounds(this._content);var _L3=[].concat($A(DOM.scry(document.body,'embed')),$A(DOM.scry(document.body,'object')));for(var i=0;i<_L3.length;i++)if(Dialog.SHOULD_HIDE_OBJECTS||(_L3[i].getAttribute('wmode')||'').toLowerCase()!='transparent')_L1.push(_L3[i]);for(var i=0;i<_L1.length;i++){var _L5=_L1[i].offsetHeight?_L1[i]:_L1[i].parentNode;var _L6=Rect.getElementBounds(_L5);if(!DOM.contains(this._content,_L1[i])&&_L2.intersects(_L6)&&this._hidden_objects.indexOf(_L5)==-1)_L0.push(_L5);}for(var i=0;i<_L0.length;i++){this._hidden_objects.push(_L0[i]);_L0[i].style.visibility='hidden';}},_buildDialogContent:function(){CSS.addClass(this._obj,'pop_dialog');if(intl_locale_is_rtl())CSS.addClass(this._obj,'pop_dialog_rtl');var _L0;if(ua.ie()<=6){_L0='<div class="pop_squarecontainer">'+'<div class="pop_squareborder pop_borderopacity"></div>'+'<div class="pop_content pop_content_old" id="pop_content"></div>'+'</div>';}else if(ua.firefox()>=3||ua.safari()>=3){_L0='<div class="pop_container_advanced">'+'<div class="pop_content" id="pop_content"></div>'+'</div>';}else _L0='<div class="pop_container">'+'<div class="pop_verticalslab"></div>'+'<div class="pop_horizontalslab"></div>'+'<div class="pop_topleft"></div>'+'<div class="pop_topright"></div>'+'<div class="pop_bottomright"></div>'+'<div class="pop_bottomleft"></div>'+'<div class="pop_content pop_content_old" id="pop_content"></div>'+'</div>';set_inner_html(this._popup,_L0);this._frame=DOM.find(this._popup,'div.pop_content');this._content=this._frame;},_buildIframe:function(){if(!this._iframe&&!(this._iframe=ge('generic_dialog_iframe')))this._iframe=$N('iframe',{id:'generic_dialog_iframe',src:'/common/blank.html'});this._iframe.frameBorder='0';onloadRegister(function(){DOM.getRootElement().appendChild(this._iframe);}.bind(this));},_buildOverlay:function(){this._overlay=$N('div',{id:'generic_dialog_overlay'});if(this._modal_class)CSS.addClass(this._overlay,this._modal_class);if(this._semi_modal)Event.listen(this._overlay,'click',this.hide.bind(this));if(ua.ie()<7)this._overlay.style.height=Vector2.getDocumentDimensions().y+'px';onloadRegister(function(){DOMScroll.getScrollRoot().appendChild(this._overlay);}.bind(this));},_focusFirstTextboxOrButton:function(){var _L0=['input[type="text"]','textarea','input[type="password"]','input[type="button"]','input[type="submit"]'];var _L1=[];for(var ii=0;ii<_L0.length&&_L1.length==0;ii++)_L1=DOM.scry(this._content,_L0[ii]);if(_L1.length>0){var _L3=_L1[0];try{if(elementY(_L3)>0&&elementX(_L3)>0)_L3.focus();}catch(e){}}return true;},_resetDialog:function(){if(!this._popup)return;this._resetDialogObj();this._buildIframe();this._resetIframe();},_resetIframe:function(){if(!this._shouldUseIframe())return;if(this._modal){this._iframe.style.left='0px';this._iframe.style.top='0px';this._iframe.style.width='100%';var _L0=Math.max(10000,Vector2.getDocumentDimensions().y);this._iframe.style.height=_L0+'px';}else{Vector2.getElementDimensions(this._frame).setElementDimensions(this._iframe);Vector2.getElementPosition(this._frame).setElementPosition(this._iframe);}this._iframe.style.display='';},_resetDialogObj:function(){var _L0=this._popup.find('div.pop_content');var _L1=Vector2.getScrollPosition().y;var _L2=Vector2.getViewportDimensions().y;var top=_L1+this._top+'px';if(_L2<=400){this._popup.style.top='20px';return;}if(this._top+_L0.clientHeight>_L2){var _L4=Math.max(_L2-_L0.clientHeight,0);top=((_L4/2)+_L1)+'px';}this._popup.style.top=top;},_fadeOut:function(_L0){if(!this._popup)return;try{animation(this._obj).duration(0).checkpoint().to('opacity',0).hide().duration(250).ondone(this._hide.bind(this,_L0)).go();}catch(e){this._hide(_L0);}},_hide:function(_L0){if(this._obj)this._obj.style.display='none';if(this._overlay)if(_L0){this._overlay.style.display='none';}else{DOM.remove(this._overlay);this._overlay=null;}if(this._iframe)this._iframe.style.display='none';if(this.timeout){clearTimeout(this.timeout);this.timeout=null;}if(this._hidden_objects.length){for(var i=0,il=this._hidden_objects.length;i<il;i++)this._hidden_objects[i].style.visibility='';this._hidden_objects=[];}clearInterval(this.active_hiding);if(_L0)return;this.destroy();},destroy:function(){if(Dialog.dialogStack&&Dialog.dialogStack.length){var _L0=Dialog.dialogStack;for(var i=_L0.length-1;i>=0;i--)if(_L0[i]==this)_L0.splice(i,1);if(_L0.length){_L0[_L0.length-1]._dirty();_L0[_L0.length-1]._showDialog();}}if(this._obj){DOM.remove(this._obj);this._obj=null;}if(this._close_handler)this._close_handler();},_handleButton:function(_L0){if(typeof _L0=='string')_L0=Dialog._findButton(this._buttons,_L0);if(!_L0){Util.error('Huh?  How did this button get here?');return;}var _L1=Dialog.call_or_eval(_L0,_L0.handler);if(_L1===false)return;if(_L0==Dialog.CANCEL){Dialog.call_or_eval(this,this._cancelHandler);}else if(Dialog.call_or_eval(this,this._handler,{button:_L0})===false)return;this.hide();},_submitForm:function(_L0,uri,_L2){var _L3=this.getFormData();_L3[_L2.name]=_L2.label;if(this._extra_data)copy_properties(_L3,this._extra_data);var _L4=new AsyncRequest().setURI(uri).setData(_L3).setMethod(_L0).setReadOnly(_L0=='GET');this.setAsync(_L4);return false;},_setFromModel:function(_L0){for(var _L1 in _L0){if(_L1=='onloadRegister'){this.onloadRegister(_L0[_L1]);continue;}var _L2=this['set'+_L1.substr(0,1).toUpperCase()+_L1.substr(1)];if(!_L2){Util.error("Unknown Dialog property: "+_L1);}else _L2.apply(this,arrayize(_L0[_L1]));}}});function ContextualDialog(_L0){this.parent.construct(this);}ContextualDialog.extend('Dialog');copy_properties(ContextualDialog,{ARROW_PADDING_X:5,ARROW_PADDING_Y:10,ARROW_WIDTH:13,_bottoms:[0],max_bottom:0,_updateMaxBottom:function(){ContextualDialog.max_bottom=Math.max.apply(Math,ContextualDialog._bottoms);}});ContextualDialog.prototype={setContext:Dialog._basicMutator('_context'),_buildDialogContent:function(){CSS.addClass(this._obj,'contextual_dialog');set_inner_html(this._popup,'<div class="contextual_arrow"><span>^_^keke1</span></div><div class="contextual_dialog_content"></div>');this._arrow=DOM.find(this._popup,'div.contextual_arrow');this._content=this._frame=DOM.find(this._popup,'div.contextual_dialog_content');},_resetDialogObj:function(){if(!this._context)return;var _L0=Vector2.getElementPosition(this._context);var _L1=DOMScroll.getScrollRoot().offsetWidth;var _L2=(_L1-this._popup.offsetWidth)/2;var _L3,_L4;if(_L0.x<_L1/2){this._arrow.className='contextual_arrow_rev';_L3=Math.min(_L2,_L0.x+this._context.offsetWidth-ContextualDialog.ARROW_PADDING_X);_L4=_L0.x-_L3+this._context.offsetWidth+ContextualDialog.ARROW_PADDING_X;}else{this._arrow.className='contextual_arrow';_L3=Math.max(_L2,_L0.x-this._popup.offsetWidth+ContextualDialog.ARROW_PADDING_X);_L4=_L0.x-_L3-ContextualDialog.ARROW_PADDING_X-ContextualDialog.ARROW_WIDTH;}_L3=_L3||0;_L4=_L4||0;new Vector2(_L3,_L0.y+this._context.offsetHeight-this._arrow.offsetHeight+ContextualDialog.ARROW_PADDING_Y,'document').setElementPosition(this._popup);this._arrow.style.backgroundPosition=_L4+'px';},_renderDialog:function(_L0){if(window!=top)this._auto_focus=false;this.parent._renderDialog(_L0);var _L1=Vector2.getElementDimensions(this._content).y+Vector2.getElementPosition(this._content).y;ContextualDialog._bottoms.push(_L1);this._bottom=_L1;ContextualDialog._updateMaxBottom();},_hide:function(){this.parent._hide();if(this._bottom){var bs=ContextualDialog._bottoms;bs.splice(bs.indexOf(this._bottom),1);ContextualDialog._updateMaxBottom();}}};function ErrorDialog(){this.parent.construct(this);this.setClassName('errorDialog').setModal(true);this.setStackable(true);return this;}ErrorDialog.extend('Dialog');copy_properties(ErrorDialog,{showAsyncError:function(_L0){if(window.send_error_signal){var vip=env_get('vip');if(vip===undefined)vip='-';send_error_signal('async_error',_L0.getError()+":"+vip);}try{return (new ErrorDialog()).showError(_L0.getErrorSummary(),_L0.getErrorDescription());}catch(ex){aiert(_L0);}}});copy_properties(ErrorDialog.prototype,{showError:function(_L0,_L1){return this.setTitle(_L0).setBody(_L1).setButtons([Dialog.OK]).show();}});var DialogBootstrapEndpoints={LIST_EDITOR:'/friends/ajax/edit_list.php',EDIT_APPS_DIALOG:'/ajax/editapp_dialog.php'};function BorderlessDialog(_L0){this.parent.construct(this);this._auto_focus=false;}BorderlessDialog.extend('Dialog');BorderlessDialog.prototype={setContext:Dialog._basicMutator('_context'),_buildDialogContent:function(){CSS.addClass(this._obj,'borderless_dialog');set_inner_html(this._popup,'<div class="borderless_dialog_content"></div>');this._content=this._frame=DOM.find(this._popup,'div.borderless_dialog_content');},_resetDialogObj:function(){if(!this._context)return;var _L0=Vector2.getElementPosition(this._context);var _L1=DOMScroll.getScrollRoot().offsetWidth;var _L2=(_L1-this._popup.offsetWidth)/2;var _L3;if(_L0.x<_L1/2){_L3=Math.min(_L2,_L0.x+this._context.offsetWidth);}else _L3=Math.max(_L2,_L0.x-this._popup.offsetWidth);_L3=_L3||0;new Vector2(_L3,_L0.y+this._context.offsetHeight,'document').setElementPosition(this._popup);}};
function escapeURI(u){if(encodeURIComponent)return encodeURIComponent(u);if(escape)return escape(u);}function htmlspecialchars(_L0){if(typeof(_L0)=='undefined'||_L0===null||!_L0.toString)return '';if(_L0===false){return '0';}else if(_L0===true)return '1';return _L0.toString().replace(/&/g,'&amp;').replace(/"/g,'&quot;').replace(/'/g,'&#039;').replace(/</g,'&lt;').replace(/>/g,'&gt;');}function htmlize(_L0){return htmlspecialchars(_L0).replace(/\n/g,'<br />');}function escape_js_quotes(_L0){if(typeof(_L0)=='undefined'||!_L0.toString)return '';return _L0.toString().replace(/\\/g,'\\\\').replace(/\n/g,'\\n').replace(/\r/g,'\\r').replace(/"/g,'\\x22').replace(/'/g,'\\\'').replace(/</g,'\\x3c').replace(/>/g,'\\x3e').replace(/&/g,'\\x26');}
function sprintf(){if(arguments.length==0){Util.warn('sprintf() was called with no arguments; it should be called with at '+'least one argument.');return '';}var _L0=['This is an argument vector.'];for(var ii=arguments.length-1;ii>0;ii--)if(typeof(arguments[ii])=="undefined"){Util.log('You passed an undefined argument (argument '+ii+') to sprintf(). '+'Pattern was: `'+(arguments[0])+'\'.','error');_L0.push('');}else if(arguments[ii]===null){_L0.push('');}else if(arguments[ii]===true){_L0.push('true');}else if(arguments[ii]===false){_L0.push('false');}else{if(!arguments[ii].toString){Util.log('Argument '+(ii+1)+' to sprintf() does not have a toString() '+'method. The pattern was: `'+(arguments[0])+'\'.','error');return '';}_L0.push(arguments[ii]);}var _L2=arguments[0];_L2=_L2.toString().split('%');var _L3=_L2.length;var _L4=_L2[0];for(var ii=1;ii<_L3;ii++){if(_L0.length==0){Util.log('Not enough arguments were provide to sprintf(). The pattern was: '+'`'+(arguments[0])+'\'.','error');return '';}if(!_L2[ii].length){_L4+="%";continue;}var p=0;var m=0;var r='';var _L8=' ';var _L9=null;var _La=null;var _Lb='';var pos=0;if(m=_L2[ii].match(/^('.)?(?:(-?\d+\.)?(-?\d+)?)/)){if(m[2]!==undefined&&m[2].length)_L9=parseInt(_Lb=m[2]);if(m[3]!==undefined&&m[3].length)if(_L9!==null){_La=parseInt(m[3]);}else _L9=parseInt(_Lb=m[3]);pos=m[0].length;if(m[1]!==undefined&&m[1].length){_L8=m[1].charAt(1);}else if(_Lb.charAt(0)==0)_L8='0';}switch(_L2[ii].charAt(pos)){case 's':case '#':raw=htmlspecialchars(_L0.pop().toString());break;case 'h':raw=_L0.pop().toString();break;case 'd':raw=parseInt(_L0.pop()).toString();break;case 'f':raw=parseFloat(_L0.pop()).toString();break;case 'q':raw="`"+htmlspecialchars(_L0.pop().toString())+"'";break;case 'e':raw="'"+escape_js_quotes(_L0.pop().toString())+"'";break;case 'L':var _Ld=_L0.pop();for(var ii=0;ii<_Ld.length;ii++)_Ld[ii]="`"+htmlspecialchars(_L0.pop().toString())+"'";if(_Ld.length>1)_Ld[_Ld.length-1]='and '+_Ld[_Ld.length-1];raw=_Ld.join(', ');break;case 'x':var x=_L0.pop();var _Lf=null;var src=null;try{if(typeof(x['line'])!='undefined'){_Lf=x.line;}else if(typeof(x['lineNumber'])!='undefined')_Lf=x.lineNumber;if(typeof(x['sourceURL'])!='undefined'){src=x['sourceURL'];}else if(typeof(x['fileName'])!='undefined')src=x['fileName'];}catch(exception){}var s='[An Exception]';try{s=x.message||x.toString();}catch(exception){}raw=s+' [at '+Stack.frameSrcToString(src,_Lf)+']';break;default:raw="%"+_L2[ii].charAt(pos+1);break;}if(_L9!==null)if(raw.length<Math.abs(_L9)){var _L12='';var _L13=(Math.abs(_L9)-raw.length);for(var ll=0;ll<_L13;ll++)_L12+=_L8;if(_L9<0){raw+=_L12;}else raw=_L12+raw;}if(_La!==null)if(raw.length>_La)raw=raw.substr(0,_La);_L4+=raw+_L2[ii].substring(pos+1);}if(_L0.length>1)Util.log('Too many arguments ('+(_L0.length-1)+' extras) were passed to '+'sprintf(). Pattern was: `'+(arguments[0])+'\'.','error');return _L4;}
function AsyncRequest(uri){var dispatchResponse=bind(this,function(_L0){if(_L0.instrument){this.cavalrylogger=CavalryLogger.getInstance(_L0.instrument);if(_L0.tti_event)this.cavalrylogger.setTTIEvent(_L0.tti_event);this.cavalrylogger.setTimeStamp('t_js');if(this.t_start)this.cavalrylogger.setValue('t_start',this.t_start);}if(!this._asyncResponse)this._asyncResponse=_L0;try{this.clearStatusIndicator();if(this.initialHandler(_L0)!==false){if(this.handler)try{this.handler(_L0);}catch(exception){this.finallyHandler(_L0);throw exception;}this.finallyHandler(_L0);if(_L0.instrument){this.cavalrylogger.setTimeStamp('t_html');this.cavalrylogger.setTimeStamp('t_domcontent');}var _L1=_L0.onload;if(_L1)for(var ii=0;ii<_L1.length;ii++)try{(new Function(_L1[ii]))();}catch(exception){Util.error('An onload hook in response to a request to to URI %q threw an '+'exception: %x. (This is not a problem with AsyncRequest, it is '+'a problem with the registered hook.)',this.getURI(),exception);}if(_L0.instrument){this.cavalrylogger.setTimeStamp('t_hooks');this.cavalrylogger.setTimeStamp('t_layout');this.cavalrylogger.setTimeStamp('t_onload');}var _L3=_L0.onafterload;if(_L3)for(var ii=0;ii<_L3.length;ii++)try{(new Function(_L3[ii]))();}catch(exception){Util.error('An onafterload hook in response to a request to to URI %q threw an '+'exception: %x. (This is not a problem with AsyncRequest, it is '+'a problem with the registered hook.)',this.getURI(),exception);}var _L4=_L0.invalidate_cache;if(_L4&&_L4.length)Arbiter.inform(Arbiter.PAGECACHE_INVALIDATE,_L4);}if(_L0.cacheObservation&&typeof(TabConsoleCacheobserver)!='undefined'&&TabConsoleCacheobserver.instance)TabConsoleCacheobserver.getInstance().addAsyncObservation(_L0.cacheObservation);}catch(exception){Util.error('The user supplied handler function for an AsyncRequest to URI %q '+'threw an exception: %x. (This is not a problem with AsyncRequest, it '+'is a problem with the callback, which failed to catch the exception.)',this.getURI(),exception);}});var replayResponse=bind(this,function(){if(!this._asyncResponse){Util.warn('Unable to replay AsyncResponse for an AsyncRequest to '+this.getURI());return;}else if(this._asyncResponse.dontReplay)return;Util.log('replaying the response for '+this.getURI());this._asyncResponse.setReplay(true);dispatchResponse(this._asyncResponse);});var dispatchErrorResponse=bind(this,function(_L0,_L1){try{this.clearStatusIndicator();var _L2=_L0.getError();if(_L2==kError_Async_ConfirmationRequired||_L2==kError_Async_InternalCaptchaRequired||_L2==kError_Verification_ConfirmEmail){var _L3=false;if(_L2==kError_Async_ConfirmationRequired||_L2==kError_Async_InternalCaptchaRequired)_L3=true;var _L4=_L0.getPayload();this._displayServerDialog(_L4.__dialog,_L3);}else if(this.initialHandler(_L0)!==false){try{if(_L1){this.transportErrorHandler(_L0);}else this.errorHandler(_L0);}catch(exception){this.finallyHandler(_L0);throw exception;}this.finallyHandler(_L0);}}catch(exception){Util.error('Async error handler threw an exception for URI %q, when processing a '+'%d error: %x.',this.getURI(),_L0.getError(),exception);}});var _interpretTransportResponse=bind(this,function(){if(this.getOption('suppressEvaluation')){var r=new AsyncResponse();r.payload=this.transport;return {asyncResponse:r};}var shield="for (;;);";var shieldlen=shield.length;if(this.transport.responseText.length<=shieldlen){var kind=this.transport.responseText.length?('a '+this.transport.responseText.length+' byte'):'an empty';return {transportError:sprintf('An error occurred when making an AsyncRequest to %q. '+'The server returned '+kind+' response.',this.getURI())};}var text=this.transport.responseText;var offset=0;while(text.charAt(offset)==" "||text.charAt(offset)=="\n")offset++;if(offset&&text.substring(offset,offset+shieldlen)==shield)Util.error('Response for request to endpoint %q seems to be valid, but was '+'preceeded by whitespace. (This probably means that someone '+'committed whitespace in a header file.)',this.getURI());var safeResponse=text.substring(offset+shieldlen);try{var response=eval('('+safeResponse+')');}catch(exception){return {transportError:sprintf('Evaluation failed for <a href="javascript:aiert(%e);">'+'response from %q</a>: %x.',this.transport.responseText,this.getURI(),exception)};}return interpretResponse(response);});var interpretResponse=bind(this,function(_L0){if(_L0.redirect)return {redirect:_L0.redirect};var r=new AsyncResponse();if(typeof(_L0.payload)=='undefined'||typeof(_L0.error)=='undefined'||typeof(_L0.errorDescription)=='undefined'||typeof(_L0.errorSummary)=='undefined'||typeof(_L0.errorIsWarning)=='undefined'){Util.warn('AsyncRequest to endpoint %q returned a JSON response, but it '+'is not properly formatted. The endpoint needs to provide a '+'response including both error and payload information; use '+'the AsyncResponse PHP class to do this easily.',this.getURI());r.payload=_L0;}else copy_properties(r,_L0);return {asyncResponse:r};});var invokeResponseHandler=bind(this,function(_L0){if(typeof(_L0.redirect)!='undefined'){(function(){this.setURI(_L0.redirect).send();}).bind(this).defer();return;}if(this.handler||this.errorHandler||this.transportErrorHandler){var r=_L0.asyncResponse;if(r.instrument&&(r.is_first===undefined||r.is_first))this.t_start=(new Date()).getTime();if(r.getError()&&!r.getErrorIsWarning()){var fn=dispatchErrorResponse;}else var fn=dispatchResponse;if(r.bootloadable)Bootloader.enableBootload(r.bootloadable);fn=fn.shield(null,r);fn=fn.defer.bind(fn);var _L3=false;if(this.preBootloadHandler)_L3=this.preBootloadHandler(r);if(r.bootload){Bootloader.loadResources(r.bootload,fn,_L3);}else fn();}});var invokeErrorHandler=bind(this,function(_L0){try{if(!window.loaded)return;}catch(ex){return;}var r=new AsyncResponse();var err;try{err=_L0||this.transport.status||1001;}catch(ex){err=1001;}try{if(this.responseText=='')err=1002;}catch(ignore){}if(this.transportErrorHandler){var _L3,_L4;if(Util.isDevelopmentEnvironment()){_L3=sprintf('Transport error (#%d) while retrieving data from endpoint %q: %s',err,this.getURI(),AsyncRequest.getHTTPErrorDescription(err));_L4=AsyncRequest.getHTTPErrorSummary(err);}else{_L3=_tx("Terjadi kesalahan. Kami akan segera memperbaikinya. Silahkan mencoba kembali.");_L4=_tx("Aduhh");}if(!this.getOption('suppressErrorAlerts'))Util.error(_L3);copy_properties(r,{error:err,errorSummary:_L4,errorDescription:_L3});dispatchErrorResponse(r,true);}else Util.error('Async request to %q failed with a %d error, but there was no error '+'handler available to deal with it.',this.getURI(),err);});var handleResponse=function(_L0){var _L1=this.interpretResponse(_L0);this.invokeResponseHandler(_L1);};var onStateChange=function(){try{if(this.transport.readyState==4){if(this.transport.status>=200&&this.transport.status<300){invokeResponseHandler(_interpretTransportResponse());}else if(ua.safari()&&(typeof(this.transport.status)=='undefined')){invokeErrorHandler(1002);}else invokeErrorHandler();if(this.getOption('asynchronous')!==false)delete this.transport;}}catch(exception){try{if(!window.loaded)return;}catch(ex){return;}delete this.transport;if(this.remainingRetries){--this.remainingRetries;this.send(true);}else{if(!this.getOption('suppressErrorAlerts'))Util.error('AsyncRequest exception when attempting to handle a state change: %x.',exception);invokeErrorHandler(1001);}}};copy_properties(this,{onstatechange:onStateChange,replayResponse:replayResponse,invokeResponseHandler:invokeResponseHandler,interpretResponse:interpretResponse,handleResponse:handleResponse,transport:null,method:'POST',uri:'',initialHandler:bagofholding,handler:null,errorHandler:null,transportErrorHandler:null,finallyHandler:bagofholding,statusElement:null,data:{},context:{},readOnly:false,writeRequiredParams:['post_form_id'],remainingRetries:0,option:{asynchronous:true,suppressErrorHandlerWarning:false,suppressEvaluation:false,suppressErrorAlerts:false,retries:1,jsonp:false,bundle:false,useIframeTransport:false,tfbEndpoint:true},_replayable:undefined,_replayKey:''});if(typeof ErrorDialog!="undefined"){this.errorHandler=ErrorDialog.showAsyncError;this.transportErrorHandler=ErrorDialog.showAsyncError;}if(uri!=undefined)this.setURI(uri);return this;}copy_properties(AsyncRequest,{getHTTPErrorSummary:function(_L0){return AsyncRequest._getHTTPError(_L0).summary;},getHTTPErrorDescription:function(_L0){return AsyncRequest._getHTTPError(_L0).description;},pingURI:function(uri,_L1,_L2){_L1=_L1||{};return new AsyncRequest().setURI(uri).setData(_L1).setOption('asynchronous',!_L2).setOption('suppressErrorHandlerWarning',true).setErrorHandler(bagofholding).setTransportErrorHandler(bagofholding).send();},receiveJSONPResponse:function(_L0,_L1,_L2){if(this._JSONPReceivers[_L0]){var _L3=(this._JSONPReceivers[_L0].is_first===undefined);this._JSONPReceivers[_L0].is_first=_L3;for(var ii=0;ii<this._JSONPReceivers[_L0].length;ii++){var _L5=this._JSONPReceivers[_L0][ii];if(_L5.transportIframe&&!_L2)(function(x){DOMScroll.getScrollRoot().removeChild(x);}).bind(null,_L5.transportIframe).defer();var r=_L5.interpretResponse(_L1);r.asyncResponse.is_first=_L3;r.asyncResponse.is_last=!_L2;_L5.invokeResponseHandler(r);}if(!_L2)delete this._JSONPReceivers[_L0];}},_hasBundledRequest:function(){return !is_empty(AsyncRequest._allBundledRequests);},stashBundledRequest:function(){var ret=AsyncRequest._allBundledRequests;AsyncRequest._allBundledRequests={};return ret;},setBundledRequestProperties:function(_L0){if(_L0.stashedRequests)copy_properties(AsyncRequest._allBundledRequests,_L0.stashedRequests);if(!AsyncRequest._hasBundledRequest()){var _L1=_L0.callback;_L1&&_L1();}else{copy_properties(AsyncRequest._bundledRequestProperties,_L0);if(_L0.start_immediately)AsyncRequest._sendBundledRequests();}},_bundleRequest:function(_L0){if(_L0.getOption('jsonp')||_L0.getOption('useIframeTransport')){Util.error('You cannot bundle AsyncRequest that uses jsonp or iframe transport.');_L0.setOption('bundle',false);return false;}else if(!_L0.uri.isFacebookURI()){Util.error('You can not bundle AsyncRequest sent to non-facebook URIs');_L0.setOption('bundle',false);return false;}else if(!_L0.getOption('asynchronous')){Util.error('We cannot bundle synchronous AsyncRequests');_L0.setOption('bundle',false);return false;}var _L1=_L0.uri.getPath();if(_L1 in AsyncRequest._allBundledRequests){Util.warn('Bundling multiple AsyncRequests to the same endpoint is not '+'supported. They will still be sent seqentially. Only the last '+'AsyncRequest to a unique endpoint is included in the bundle.');var _L2=AsyncRequest._allBundledRequests[_L1];_L2.setOption('bundle',false).send();}if(is_empty(AsyncRequest._allBundledRequests))AsyncRequest._bundleTimer=setTimeout(function(){AsyncRequest._sendBundledRequests();},0);AsyncRequest._allBundledRequests[_L1]=_L0;return true;},_sendBundledRequests:function(){clearTimeout(AsyncRequest._bundleTimer);AsyncRequest._bundleTimer=null;var _L0=AsyncRequest._allBundledRequests;AsyncRequest._allBundledRequests={};var _L1={};copy_properties(_L1,AsyncRequest._bundledRequestProperties);AsyncRequest._bundledRequestProperties={};if(is_empty(_L1)&&count(_L0)==1){for(var _L2 in _L0)_L0[_L2].setOption('bundle',false).send();return;}var _L3=function(){_L1.callback&&_L1.callback();};if(is_empty(_L0)){_L3();return;}var _L4={};for(var _L2 in _L0){var _L5=_L0[_L2];_L4[_L2]=URI.implodeQuery(_L5.data);}var _L6={data:_L4};if(_L1.extra_data)copy_properties(_L6,_L1.extra_data);new AsyncRequest().setURI('/ajax/proxy.php').setData(_L6).setMethod('POST').setInitialHandler(_L1.onInitialResponse||bagof(true)).setHandler(function(r){var _L8=r.getPayload();var _L9=_L8.responses;for(var _L2 in _L0){var _L5=_L0[_L2];if(_L2 in _L9){var _La=_L5.interpretResponse(_L9[_L2]);_L5.invokeResponseHandler(_La);}else{var _Lb={transportError:sprintf('An error occurred when making an AsyncRequest to %q '+' in a bundled request.',_L2)};_L5.invokeResponseHandler(_Lb);}}}).setTransportErrorHandler(function(_L7){var _L8=[];var _L9={transportError:_L7.errorDescription};for(var _L2 in _L0){_L8.push(_L2);var _L5=_L0[_L2];_L5.invokeResponseHandler(_L9);}Util.error('Transport error occured for bundled requests to '+_L8.join(', '));}).setFinallyHandler(function(r){_L3();}).send();},responseOpsHandler:function(_L0,_L1){if(_L1.dom_ops)_L1.dom_ops.forEach(function(i){var _L3=_L0.find(i.where);if(_L3){var _L4=i.raw?i.what:HTML(i.what);DOM[i.how](_L3,_L4);}});invoke_callbacks(_L1.relative_ops,_L0);},bootstrap:function(_L0,_L1){var _L2='GET';var _L3=true;var _L4={};var _L0=URI(_L0);if(_L1&&_L1.rel=='async-post'){_L2='POST';_L3=false;_L4=_L0.getQueryData();_L0.setQueryData({});}new AsyncRequest(_L0).setReadOnly(_L3).setMethod(_L2).setData(_L4).setStatusElement(_L1).setHandler(AsyncRequest.responseOpsHandler.bind(null,_L1)).send();return false;},_getHTTPError:function(_L0){var e=AsyncRequest._HTTPErrors[_L0]||AsyncRequest._HTTPErrors[_L0-(_L0%100)]||{summary:'HTTP Error',description:'Unknown HTTP error #'+_L0};return e;},_HTTPErrors:{400:{summary:'Bad Request',description:'Bad HTTP request.'},401:{summary:'Unauthorized',description:'Not authorized.'},403:{summary:'Forbidden',description:'Access forbidden.'},404:{summary:'Not Found',description:'Web address does not exist.'},1000:{summary:'Bad Response',description:'Invalid response.'},1001:{summary:'No Network',description:'A network error occurred. Check that you are connected to the '+'internet.'},1002:{summary:'No Data',description:'The server did not return a response.'},1003:{summary:'Eval Error',description:'Exception thrown during JSON evaluation.'}},_JSONPReceivers:{},_allBundledRequests:{},_bundledRequestProperties:{},_bundleTimer:null});copy_properties(AsyncRequest.prototype,{setMethod:function(m){this.method=m.toString().toUpperCase();return this;},getMethod:function(){return this.method;},setData:function(obj){this.data=obj;return this;},getData:function(){return this.data;},setContextData:function(key,_L1,_L2){_L2=_L2===undefined?true:_L2;if(_L2)this.context['_log_'+key]=_L1;return this;},setURI:function(uri){var _L1=URI(uri);if(this.getOption('useIframeTransport')&&!_L1.isFacebookURI()){Util.error('IframeTransport requests should only be used when going between '+'different Facebook subdomains.  This probably won\'t do what you want '+'if you\'re going to a non-Facebook URI.  Check out JSONP for that, '+'but that\'s also a bad idea to use.');return this;}if(!this.getOption('jsonp')&&!this.getOption('useIframeTransport')&&!_L1.isSameOrigin()){Util.error('Asynchronous requests must specify relative URIs (like %q); this '+'ensures they conform to the Same Origin Policy (see %q). The '+'provided absolute URI (%q) is invalid, use a relative URI instead. '+'If you need to dispatch cross-domain requests, you can use JSONP, '+'but consider this decision carefully because there are tradeoffs and '+'JSONP is completely insecure.','/path/to/endpoint.php','http://www.mozilla.org/projects/security/components/same-origin.html',_L1.toString());return this;}this.uri=_L1;return this;},getURI:function(){return this.uri.toString();},setInitialHandler:function(fn){this.initialHandler=fn;return this;},setHandler:function(fn){if(typeof(fn)!='function'){Util.error('AsyncRequest response handlers must be functions. Pass a function, '+'or use bind() to build one.');}else this.handler=fn;return this;},getHandler:function(){return this.handler;},setErrorHandler:function(fn){if(typeof(fn)!='function'){Util.error('AsyncRequest error handlers must be functions. Pass a function, or '+'use bind() to build one.');}else this.errorHandler=fn;return this;},setTransportErrorHandler:function(fn){this.transportErrorHandler=fn;return this;},getErrorHandler:function(){return this.errorHandler;},getTransportErrorHandler:function(){return this.transportErrorHandler;},setFinallyHandler:function(fn){this.finallyHandler=fn;return this;},setPreBootloadHandler:function(fn){this.preBootloadHandler=fn;return this;},setReadOnly:function(_L0){if(typeof(_L0)!='boolean'){Util.error('AsyncRequest readOnly value must be a boolean.');}else this.readOnly=_L0;return this;},setFBMLForm:function(){this.writeRequiredParams=["fb_sig"];return this;},getReadOnly:function(){return this.readOnly;},setStatusElement:function(_L0){this.statusElement=_L0;return this;},getStatusElement:function(){return this.statusElement;},clearStatusIndicator:function(){if(this.getStatusElement())CSS.removeClass($(this.getStatusElement()),'async_saving');},addStatusIndicator:function(){if(this.getStatusElement())CSS.addClass($(this.getStatusElement()),'async_saving');},specifiesWriteRequiredParams:function(){return this.writeRequiredParams.every(function(_L0){this.data[_L0]=this.data[_L0]||Env[_L0]||(ge(_L0)||{}).value;if(this.data[_L0]!==undefined)return true;},this);},setReplayable:function(_L0,key){this._replayable=_L0;this._replayKey=key||'';return this;},setOption:function(opt,v){if(typeof(this.option[opt])!='undefined'){this.option[opt]=v;}else Util.warn('AsyncRequest option %q does not exist; request to set it was ignored.',opt);return this;},getOption:function(opt){if(typeof(this.option[opt])=='undefined')Util.warn('AsyncRequest option %q does not exist, get request failed.',opt);return this.option[opt];},abort:function(){if(this.transport){var _L0=this.getTransportErrorHandler();this.setOption('suppressErrorAlerts',true);this.setTransportErrorHandler(bagofholding);this.transport.abort();this.setTransportErrorHandler(_L0);}},setNectarActionData:function(_L0){if(this.data.nctr===undefined)this.data.nctr={};this.data.nctr._ia=1;if(_L0){if(this.data.nctr._as===undefined)this.data.nctr._as={};copy_properties(this.data.nctr._as,_L0);}return this;},setNectarData:function(_L0){if(_L0){if(this.data.nctr===undefined)this.data.nctr={};copy_properties(this.data.nctr,_L0);}return this;},send:function(_L0){_L0=_L0||false;if(!this.uri){Util.error('Attempt to dispatch an AsyncRequest without an endpoint URI! This is '+'all sorts of silly and impossible, so the request failed.');return false;}if(!this.errorHandler&&!this.getOption('suppressErrorHandlerWarning'))Util.warn('Dispatching an AsyncRequest that does not have an error handler. '+'You SHOULD supply one, or use AsyncRequest.pingURI(). If this '+'omission is intentional and well-considered, set the %q option to '+'suppress this warning.','suppressErrorHandlerWarning');if(this.getOption('jsonp')&&this.method!='GET')this.setMethod('GET');if(this.getOption('useIframeTransport')&&this.method!='GET'){Util.warn('Iframe transport currently works only with GET.');this.setMethod('GET');}if(!this.getReadOnly()){if(!this.specifiesWriteRequiredParams()){Util.error('You are making a POST request to %s without one or more of the '+'required parameters: %s. Requests which modify data and do not '+'verify the request origin through parameter validation are '+'vulnerable to CSRF attacks. You should either specify values for '+'these parameters explicitly by using setData(), put them in the '+'page as inputs, or mark this request as safe and idempotent by '+'using setReadOnly(). Consult the setReadOnly() documentation for '+'more information.',this.uri.toString(),this.writeRequiredParams.join(','));return false;}if(this.method!='POST'){Util.error('You are making a GET request which modifies data; this violates '+'the HTTP spec and is generally a bad idea. Either change this '+'request to use POST or use setReadOnly() to mark the request as '+'idempotent and appropriate for HTTP GET. Consult the setReadOnly() '+'documentation for more information.');return false;}}if(this.method=='POST'&&this.getOption('tfbEndpoint'))this.data.fb_dtsg=Env.fb_dtsg;if((!this.getReadOnly()&&this._replayable!==false)||this._replayable)Arbiter.inform(Arbiter.REPLAYABLE_AJAX,this);if(!is_empty(this.context)&&this.getOption('tfbEndpoint')){copy_properties(this.data,this.context);this.data['ajax_log']=1;}if(!this.getReadOnly()&&this.getOption('tfbEndpoint')&&this.method=='POST'&&this.data['post_form_id_source']===undefined)this.data['post_form_id_source']='AsyncRequest';if(this.getOption('tfbEndpoint')){this.data['__a']=1;if(Env.nectar_ct)this.setNectarData({'_ct':new Date().getTime()});}if(this.getOption('bundle')&&AsyncRequest._bundleRequest(this))return true;var _L1,_L2;if(this.method=='GET'){_L1=this.uri.addQueryData(this.data).toString();_L2='';}else{_L1=this.uri.toString();_L2=URI.implodeQuery(this.data);}if(this.getOption('jsonp')||this.getOption('useIframeTransport')){var _L3=this.uri.getPath();if(!AsyncRequest._JSONPReceivers[_L3])AsyncRequest._JSONPReceivers[_L3]=[];AsyncRequest._JSONPReceivers[_L3].push(this);if(this.getOption('jsonp')){(function(){DOMScroll.getScrollRoot().appendChild($N('script',{src:_L1,type:"text/javascript"}));}).bind(this).defer();}else{var _L4={position:'absolute',top:'-1000px',left:'-1000px',width:'80px',height:'80px'};_L1=this.uri.addQueryData({'_fb_iframe_path':_L3});this.transportIframe=$N('iframe',{src:_L1,style:_L4});DOMScroll.getScrollRoot().appendChild(this.transportIframe);}return true;}if(this.transport){Util.error('You must wait for an AsyncRequest to complete before sending another '+'request with the same object. To send two simultaneous requests, '+'create a second AsyncRequest object.');return false;}var _L5=null;try{_L5=new XMLHttpRequest();}catch(ignored){}if(!_L5)try{_L5=new ActiveXObject("Msxml2.XMLHTTP");}catch(ignored){}if(!_L5)try{_L5=new ActiveXObject("Microsoft.XMLHTTP");}catch(ignored){}if(!_L5){Util.error('Unable to build XMLHTTPRequest transport.');return false;}_L5.onreadystatechange=bind(this,'onstatechange');if(!_L0){this.remainingRetries=0;if(this.getReadOnly())this.remainingRetries=this.getOption('retries');}this.transport=_L5;try{this.transport.open(this.method,_L1,this.getOption('asynchronous'));}catch(ex){Util.error('Exception when opening Async transport to %q: %x',_L1,ex);return false;}var _L6=env_get('svn_rev');if(_L6)this.transport.setRequestHeader('X-SVN-Rev',String(_L6));if(this.method=='POST')this.transport.setRequestHeader('Content-Type','application/x-www-form-urlencoded');this.addStatusIndicator();this.transport.send(_L2);return true;},_displayServerDialog:function(_L0,_L1){var _L2=new Dialog(_L0);if(_L1)_L2.setHandler(this._displayConfirmationHandler.bind(this,_L2));_L2.setCloseHandler(this.finallyHandler.bind(this)).show();},_displayConfirmationHandler:function(_L0){this.data.confirmed=1;copy_properties(this.data,_L0.getFormData());this.send();}});function AsyncResponse(_L0){copy_properties(this,{error:0,errorSummary:null,errorDescription:null,onload:null,replay:false,relative_ops:[],payload:_L0||null});return this;}copy_properties(AsyncResponse.prototype,{getPayload:function(){return this.payload;},getError:function(){return this.error;},getErrorSummary:function(){return this.errorSummary;},getErrorDescription:function(){return this.errorDescription;},getErrorIsWarning:function(){return this.errorIsWarning;},setReplay:function(_L0){_L0=(_L0===undefined?true:_L0);this.replay=!!_L0;return this;},isReplay:function(){return this.replay;}});
function UISelectList(){this._callback=bagofholding;this.container=$N('div',{className:'UISelectList clearfix'});this._mode=UISelectList.MULTI_SELECT_MODE;this._inputName='UISelectList_name_'+(+new Date());this._items={};}copy_properties(UISelectList,{MULTI_SELECT_MODE:1,SINGLE_SELECT_MODE:2,MULTI_SELECT_MODE_CHECKED_CLASS_NAME:'UISelectList_check_Checked',SINGLE_SELECT_MODE_CHECKED_CLASS_NAME:'UISelectList_radio_Checked'});UISelectList.prototype={setMode:function(_L0){if(_L0!=UISelectList.MULTI_SELECT_MODE&&_L0!=UISelectList.SINGLE_SELECT_MODE){Util.error('invalid mode %s passed to UISelectList.selectMode',_L0);return this;}if(!is_empty(this._items)){Util.error("You have to set `mode' before adding any items to "+"UISelectList");return this;}this._mode=_L0;return this;},setCallback:function(fn){this._callback=fn;return this;},addItem:function(_L0,_L1,key){var _L3={label:_L0,checked:_L1,key:key};this._renderItem(_L3);return this;},addItems:function(_L0){for(var i=0;i<_L0.length;i++)this.addItem(_L0[i].label,_L0[i].checked,_L0[i].key);return this;},clearItems:function(){this._items={};DOM.empty(this.container);return this;},setSelected:function(key,_L1){if(this._items[key]){var _L2=this._items[key].input;_L2.checked=!_L1;_L2.click();}return this;},getElement:function(){return this.container;},reset:function(){for(var key in this._items){var _L1=this._items[key].input;var _L2=this._items[key].label;_L1.checked=_L1.defaultChecked;CSS.conditionClass(_L2,this._getCheckedClass(),_L1.checked);}},_renderItem:function(_L0){var _L1=$N('input',{type:this._getInputType(),name:this._inputName});_L1.checked=_L0.checked;_L1.defaultChecked=_L0.checked;var _L2=$N('a',{className:'UISelectList_Label',href:'#'},_L0.label);if(_L0.checked)_L2.addClass(this._getCheckedClass());_L2.listen('click',Event.kill);_L2.listen('mouseup',this._linkClicked.bind(this,_L1));_L1.listen('click',this._clicked.bind(this,_L1,_L2,_L0.key));this.container.appendContent($N('div',{className:'UISelectList_Item'},[_L1,_L2]));_L0.input=_L1;_L0.label=_L2;this._items[_L0.key]=_L0;},_getInputType:function(){if(this._mode==UISelectList.MULTI_SELECT_MODE)return 'checkbox';return 'radio';},_getCheckedClass:function(){if(this._mode==UISelectList.MULTI_SELECT_MODE)return UISelectList.MULTI_SELECT_MODE_CHECKED_CLASS_NAME;return UISelectList.SINGLE_SELECT_MODE_CHECKED_CLASS_NAME;},_linkClicked:function(_L0,e){_L0.click();},_clicked:function(_L0,_L1,key,e){var _L4;if(this._mode==UISelectList.SINGLE_SELECT_MODE){for(var k in this._items){var _L6=_L0==this._items[k].input;CSS.conditionClass(this._items[k].label,this._getCheckedClass(),_L6);}_L4=true;}else{_L4=_L0.checked;CSS.conditionClass(_L1,this._getCheckedClass(),_L0.checked);}this._callback(_L4,key);$E(e).stop();}};
var HistoryManager={_IFRAME_BASE_URI:'http://static.ak.facebook.com/common/history_manager.html',history:null,current:0,fragment:null,_setIframeSrcFragment:function(src){src=src.toString();var _L1=HistoryManager.history.length-1;HistoryManager.iframe.src=HistoryManager._IFRAME_BASE_URI+'?|index='+_L1+'#'+encodeURIComponent(src);return HistoryManager;},getIframeSrcFragment:function(){return decodeURIComponent(URI(HistoryManager.iframe.contentWindow.document.location.href).getFragment());},nextframe:function(_L0,_L1){if(_L1){HistoryManager._setIframeSrcFragment(_L0);return;}if(_L0!==undefined){HistoryManager.iframeQueue.push(_L0);}else{HistoryManager.iframeQueue.splice(0,1);HistoryManager.iframeTimeout=null;HistoryManager.checkURI();}if(HistoryManager.iframeQueue.length&&!HistoryManager.iframeTimeout){var src=HistoryManager.iframeQueue[0];HistoryManager.iframeTimeout=setTimeout(function(){HistoryManager._setIframeSrcFragment(src);},100,false);}},isInitialized:function(){return !!HistoryManager._initialized;},init:function(){if(URI.getRequestURI(false).getProtocol().toLowerCase()=='https')return;if(!env_get('ALLOW_TRANSITION_IN_IFRAME')&&window!=window.top)return;if(HistoryManager._initialized)return HistoryManager;var uri=URI();var _L1=uri.getFragment()||'';copy_properties(HistoryManager,{_initialized:true,fragment:_L1,orig_fragment:_L1,history:[uri],callbacks:[],lastChanged:new Date().getTime(),canonical:URI('#'),fragmentTimeout:null,user:0,iframeTimeout:null,iframeQueue:[],enabled:true,debug:bagofholding});if(ua.safari()<500||ua.firefox()<2){HistoryManager.enabled=false;return HistoryManager;}if(ua.ie()<8){HistoryManager.iframe=document.createElement('iframe');copy_properties(HistoryManager.iframe.style,{width:'0',height:'0',frameborder:'0',left:'0',top:'0',position:'absolute'});onloadRegister(function(){HistoryManager._setIframeSrcFragment(_L1);document.body.insertBefore(HistoryManager.iframe,document.body.firstChild);});}else setInterval(HistoryManager.checkURI,42,false);HistoryManager._updateRefererURI(URI.getRequestURI(false));return HistoryManager;},registerURIHandler:function(_L0){HistoryManager.callbacks.push(_L0);return HistoryManager;},setCanonicalLocation:function(loc){HistoryManager.canonical=URI(loc);return HistoryManager;},notify:function(uri){if(uri==HistoryManager.orig_fragment)uri=HistoryManager.canonical.getFragment();for(var ii=0;ii<HistoryManager.callbacks.length;ii++)try{if(HistoryManager.callbacks[ii](uri))return true;}catch(ex){Util.error('Uncaught exception in HistoryManager URI handler callback: %x',ex);}return false;},checkURI:function(){if(new Date().getTime()-HistoryManager.lastChanged<400)return;if(ua.ie()<8&&HistoryManager.iframeQueue.length)return;if(ua.safari()&&window.history.length==200){if(!HistoryManager.warned){HistoryManager.warned=true;Util.error('Your history length is over 200 and you are in Safari; things will '+'start behaving oddly now. This is a known bug.');}return;}var _L0=URI().getFragment();if(ua.ie()<8)_L0=HistoryManager.getIframeSrcFragment();if(_L0!=HistoryManager.fragment){HistoryManager.debug([_L0,' vs ',HistoryManager.fragment,'whl: ',window.history.length,'QHL: ',HistoryManager.history.length].join(' '));for(var ii=HistoryManager.history.length-1;ii>=0;--ii)if(HistoryManager.history[ii].getFragment()==_L0)break;++HistoryManager.user;if(ii>=0){HistoryManager.go(ii-HistoryManager.current);}else HistoryManager.go('#'+_L0);--HistoryManager.user;}delete _L0;},_updateRefererURI:function(uri){uri=uri.toString();if(uri.charAt(0)!='/'&&uri.indexOf('//')==-1)return;setCookie('x-referer',URI(uri).getQualifiedURI().setFragment('').toString());},go:function(_L0,now,_L2){HistoryManager.debug('go: '+_L0);if(now===undefined)now=true;if(!HistoryManager.enabled)if(!now)return false;if(typeof(_L0)=='number'){if(!_L0)return false;var dst=_L0+HistoryManager.current;var loc=Math.max(0,Math.min(HistoryManager.history.length-1,dst));HistoryManager.current=loc;dst=HistoryManager.history[loc].getFragment()||HistoryManager.orig_fragment;HistoryManager.fragment=dst;HistoryManager.lastChanged=new Date().getTime();if(ua.ie()<8){if(HistoryManager.fragmentTimeout)clearTimeout(HistoryManager.fragmentTimeout);HistoryManager._temporary_fragment=dst;HistoryManager.fragmentTimeout=setTimeout(function(){window.location.hash='#'+dst;delete HistoryManager._temporary_fragment;},750,false);if(!HistoryManager.user)HistoryManager.nextframe(dst,_L2);}else if(!HistoryManager.user)go_or_replace(window.location,window.location.href.split('#')[0]+'#'+dst,_L2);if(now)HistoryManager.notify(dst);HistoryManager._updateRefererURI(dst);return false;}_L0=URI(_L0);if(_L0.getDomain()==URI().getDomain())_L0=URI('#'+_L0.getUnqualifiedURI());var cur=HistoryManager.history[HistoryManager.current].getFragment();var tgt=_L0.getFragment();if(tgt==cur||(cur==HistoryManager.orig_fragment&&tgt==HistoryManager.canonical.getFragment())){if(now)HistoryManager.notify(tgt);HistoryManager._updateRefererURI(tgt);return false;}if(_L2)HistoryManager.current--;var _L7=(HistoryManager.history.length-HistoryManager.current)-1;HistoryManager.history.splice(HistoryManager.current+1,_L7);HistoryManager.history.push(URI(_L0));return HistoryManager.go(1,now,_L2);},getCurrentFragment:function(){var _L0=HistoryManager._temporary_fragment!==undefined?HistoryManager._temporary_fragment:URI.getRequestURI(false).getFragment();return _L0==HistoryManager.orig_fragment?HistoryManager.canonical.getFragment():_L0;}};var PageTransitions={_transition_handlers:[],_scroll_positions:{},isInitialized:function(){return !!PageTransitions._initialized;},_init:function(){if(URI.getRequestURI(false).getProtocol().toLowerCase()=='https')return;if(!env_get('ALLOW_TRANSITION_IN_IFRAME')&&window!=window.top)return;if(PageTransitions._initialized)return PageTransitions;PageTransitions._initialized=true;var _L0=URI.getRequestURI(false);var _L1=_L0.getUnqualifiedURI();var _L2=URI(_L1).setFragment(null);if(_L2.toString()===_L1.getFragment())_L1=_L2;copy_properties(PageTransitions,{_current_uri:_L1,_most_recent_uri:_L1,_next_uri:_L1});var _L3;if(_L0.getFragment().startsWith('/')){_L3=_L0.getFragment();}else _L3=_L1;HistoryManager.init().setCanonicalLocation('#'+_L3).registerURIHandler(PageTransitions._historyManagerHandler);LinkController.registerFallbackHandler(PageTransitions._rewriteHref,LinkController.TARGETS|LinkController.MODIFIERS);LinkController.registerFallbackHandler(PageTransitions._onlinkclick);FormController.registerFallbackHandler(PageTransitions._onformsubmit);window.onscroll=chain(window.onscroll,function(){var _L4=HistoryManager.getCurrentFragment();if(PageTransitions._current_uri==_L4)PageTransitions._scroll_positions[_L4]=Vector2.getScrollPosition();});return PageTransitions;},registerHandler:function(_L0,_L1){PageTransitions._init();if(PageTransitions._transition_handlers.contains(_L0))Util.warn('Registering a transition handler that\'s already been '+'registered.  Ur probably doin it wrong.');if(_L1){PageTransitions._transition_handlers.unshift(_L0);}else PageTransitions._transition_handlers.push(_L0);},getCurrentURI:function(_L0){if(!PageTransitions._current_uri&&!_L0){Util.warn('You\'ve requested the current URI, but there is no "current" '+'URI.  This is probably because you\'re in the middle of a '+'page transition.  That\'s an awkward time to ask for the '+'current URI, and you should probably avoid this situation.  '+'For now, I\'m just gonna return the most recent page URI, '+'since that\'s better than returning null.');return new URI(PageTransitions._most_recent_uri);}return new URI(PageTransitions._current_uri);},getMostRecentURI:function(){return new URI(PageTransitions._most_recent_uri);},getNextURI:function(){return new URI(PageTransitions._next_uri);},_rewriteHref:function(_L0){var _L1=_L0.getAttribute('href');var _L2=_computeRelativeURI(PageTransitions._most_recent_uri.getQualifiedURI(),_L1).toString();if(_L1!=_L2)_L0.setAttribute('href',_L2);},_onlinkclick:function(_L0){_BusyUIManager.lookBusy(_L0);PageTransitions.go(_L0.getAttribute('href'));return false;},_onformsubmit:function(_L0){var _L1=new URI(_L0.getAttribute('action')||''),_L2=_computeRelativeURI(PageTransitions._most_recent_uri,_L1);_L0.setAttribute('action',_L2.toString());if(!_L0.method||_L0.method.toUpperCase()=='GET'){PageTransitions.go(_L2.addQueryData(serialize_form(_L0)));return false;}},_rewriteSubDomain:function(uri){uri=URI(uri);var _L1=uri.getDomain();if(_L1.indexOf('apps.')===0){var _L2=URI.getRequestURI().getDomain();uri.addQueryData({_fb_qsub:_L1}).setDomain(_L2);}return uri;},_revertSubDomain:function(uri){uri=URI(uri);var _L1=uri.getQueryData();if('_fb_qsub' in _L1){var _L2=_L1._fb_qsub;uri.removeQueryData('_fb_qsub').setDomain(_L2).setProtocol(URI().getProtocol());}return uri;},go:function(uri,_L1){var _L2=new URI(uri).removeQueryData('quickling').getQualifiedURI();_L2=PageTransitions._rewriteSubDomain(_L2);var _L3=_L2.getUnqualifiedURI();delete PageTransitions._scroll_positions[_L3];_BusyUIManager.lookBusy();PageTransitions._loadPage(_L2,function(_L4){if(_L4){HistoryManager.go(_L2.toString(),false,_L1);}else{_L2=PageTransitions._revertSubDomain(_L2);go_or_replace(window.location,_L2,_L1);}});},_historyManagerHandler:function(_L0){if(_L0.charAt(0)!='/')return false;PageTransitions._loadPage(new URI(_L0),function(_L1){if(!_L1){_L0=PageTransitions._revertSubDomain(_L0);go_or_replace(window.location,_L0,true);}});return true;},_loadPage:function(uri,_L1){if(uri.getFragment()&&are_equal(URI(uri).setFragment(null).getQualifiedURI(),URI(PageTransitions._current_uri).setFragment(null).getQualifiedURI())){PageTransitions._current_uri=PageTransitions._most_recent_uri=uri;PageTransitions.restoreScrollPosition();_BusyUIManager.stopLookingBusy();return;}var _L2=PageTransitions._scroll_positions[PageTransitions._current_uri];PageTransitions._current_uri=null;PageTransitions._next_uri=uri;if(_L2)DOMScroll.scrollTo(_L2,false);var _L3=function(){var _L5=PageTransitions._handleTransition(uri);_L1&&_L1(_L5);};var _L4=_runHooks('onbeforeleavehooks');if(_L4){_BusyUIManager.stopLookingBusy();PageTransitions._warnBeforeLeaving(_L4,_L3);}else _L3();},_handleTransition:function(uri){window.onbeforeleavehooks=undefined;_BusyUIManager.lookBusy();for(var i=PageTransitions._transition_handlers.length-1;i>=0;--i)if(PageTransitions._transition_handlers[i](uri)===true){var _L2={sender:this,uri:uri};Arbiter.inform(Arbiter.PAGE_TRANSITION,_L2);return true;}else PageTransitions._transition_handlers.splice(i,1);return false;},transitionComplete:function(){_BusyUIManager.stopLookingBusy();PageTransitions._current_uri=PageTransitions._most_recent_uri=PageTransitions._next_uri;PageTransitions.restoreScrollPosition();},_warnBeforeLeaving:function(_L0,_L1){new Dialog().setTitle(_tx("Anda yakin ingin meninggalkan halaman ini?")).setSummary(_tx("Tekan {ok} untuk melanjutkan, atau {cancel} untuk tetap di  halaman ini.",{ok:_tx("Oke"),cancel:_tx("Batalkan")})).setBody(htmlize(_L0)).setButtons(Dialog.OK_AND_CANCEL).setHandler(_L1).setModal().show();},restoreScrollPosition:function(){var _L0=PageTransitions._current_uri;var _L1=PageTransitions._scroll_positions[_L0];if(_L1){DOMScroll.scrollTo(_L1,false);return;}function _L2(_L5){return (_L5||null)&&(DOM.find(document,sprintf('a[name=%e]',_L5))||ge(_L5));}var _L3=_L2(_L0.getFragment());if(_L3){var _L4=Vector2.getElementPosition(_L3);_L4.x=0;DOMScroll.scrollTo(_L4);}}};function _computeRelativeURI(_L0,_L1){var ret=new URI(),_L3=_L1;_L0=new URI(_L0);_L1=new URI(_L1);if(!_L1.isFacebookURI())return _L3;var _L4=_L0;var _L5=['Protocol','Domain','Port','Path','QueryData','Fragment'];_L5.forEach(function(_L6){var _L7=_L6=='Path'&&_L4===_L0;if(_L7)ret.setPath(_computeRelativePath(_L0.getPath(),_L1.getPath()));if(!is_empty(_L1['get'+_L6]()))_L4=_L1;if(!_L7)ret['set'+_L6](_L4['get'+_L6]());});return ret;}function _computeRelativePath(_L0,_L1){if(!_L1)return _L0;if(_L1.charAt(0)=='/')return _L1;var _L2=_L0.split('/').slice(0,-1);if(_L2[0]!=='')Util.warn('Original path is not absolute.');_L1.split('/').forEach(function(_L3){if(_L3=='.'){}else if(_L3=='..'){if(_L2.length>1)_L2=_L2.slice(0,-1);}else _L2.push(_L3);});return _L2.join('/');}function go_or_replace(_L0,_L1,_L2){var uri=new URI(_L1);if(_L0.pathname=='/'&&uri.getPath()!='/'&&uri.isQuicklingEnabled()){var _L4=_L0.search?{}:{q:''};uri=new URI().setPath('/').setQueryData(_L4).setFragment(uri.getUnqualifiedURI()).toString();_L1=uri.toString();}if(_L2&&!(ua.ie()<8)){_L0.replace(_L1);}else if(_L0.href==_L1){_L0.reload();}else _L0.href=_L1;}var _BusyUIManager={_looking_busy:false,_original_cursors:[],lookBusy:function(_L0){if(_L0)_BusyUIManager._giveProgressCursor(_L0);if(_BusyUIManager._looking_busy)return;_BusyUIManager._looking_busy=true;_BusyUIManager._giveProgressCursor(document.body);},stopLookingBusy:function(){if(!_BusyUIManager._looking_busy)return;_BusyUIManager._looking_busy=false;while(_BusyUIManager._original_cursors.length){var _L0=_BusyUIManager._original_cursors.pop();var _L1=_L0[0];var _L2=_L0[1];if(_L1.style)_L1.style.cursor=_L2||'';}},_giveProgressCursor:function(_L0){if(!ua.safari()){_BusyUIManager._original_cursors.push([_L0,_L0.style.cursor]);_L0.style.cursor='progress';}}};
PresenceMessage={STARTED:'presence/started',SHUTDOWN:'presence/shutdown',RESTARTED:'presence/restarted',WINDOW_RESIZED:'presence/window-resized',TAB_CLOSED:'presence/tab-closed',TAB_OPENED:'presence/tab-opened',PRESENCE_UPDATER_READY:'presence/updater-ready',getAppMessageType:function(_L0,_L1){return 'presence/app_message:'+_L0+':'+_L1;},getArbiterMessageType:function(_L0){return 'presence/message:'+_L0;}};

if (window.Bootloader) { Bootloader.done(["js\/ettfh4b1ey0okc04.pkg.js"]); }