/*    HTTP Host:  b.static.ak.fbcdn.net                                        */
/*    Generated:  February 8th 2010 3:09:57 AM PST                             */
/*      Machine:  10.16.139.110                                                */
/*       Source:  Backing Store                                                */
/*     Location:  js/50h1guto78kkgooo.pkg.js h:9uatfjil                        */
/*       Locale:  nu_ll                                                        */
/*         Path:  js/50h1guto78kkgooo.pkg.js                                   */

if (window.CavalryLogger) { CavalryLogger.start_js(["js\/50h1guto78kkgooo.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)elem.parentNode.innerHTML=_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 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();}};
function typeaheadpro(obj,_L1,_L2){if(!typeaheadpro.hacks){typeaheadpro.should_check_missing_events=ua.safari()<500;typeaheadpro.should_simulate_keypress=(ua.ie()<8)||(ua.safari()>500&&ua.safari()<523||ua.safari()>=525);if(typeaheadpro.should_use_iframe==undefined)typeaheadpro.should_use_iframe=typeaheadpro.should_simulate_keypress;typeaheadpro.should_use_overflow=ua.opera()<9.5||ua.safari()<500;if(ua.firefox())this.activate_poll_on_focus_events=true;typeaheadpro.hacks=true;}typeaheadpro.instances=(typeaheadpro.instances||[]);typeaheadpro.instances.push(this);this.instance=typeaheadpro.instances.length-1;copy_properties(this,_L2||{});this.obj=obj;this.obj.typeahead=this;this.obj.onfocus=this._onfocus.bind(this);this.obj.onblur=chain(this.obj.onblur,this._onblur.bind(this));this.obj.onchange=this._onchange.bind(this);this.obj.onkeyup=function(_L3){return this._onkeyup(_L3||window.event);}.bind(this);this.obj.onkeydown=function(_L3){return this._onkeydown(_L3||window.event);}.bind(this);this.obj.onkeypress=function(_L3){return this._onkeypress(_L3||window.event);}.bind(this);this.want_icon_list=false;this.showing_icon_list=false;this.stop_suggestion_select=false;if(this.typeahead_icon_class&&this.typeahead_icon_get_return){this.typeahead_icon=document.createElement('div');CSS.addClass(this.typeahead_icon,'typeahead_list_icon');CSS.addClass(this.typeahead_icon,this.typeahead_icon_class);this.typeahead_icon.innerHTML='&nbsp;';this.setup_typeahead_icon();setTimeout(function(){this.focus();}.bind(this),50);this.typeahead_icon.onmousedown=function(_L3){return this.typeahead_icon_onclick(_L3||window.event);}.bind(this);}this.focused=this.focused||this.obj.offsetWidth?true:false;this.anchor=this.setup_anchor();this.dropdown=document.createElement('div');CSS.addClass(this.dropdown,'typeahead_list');if(!this.focused)this.dropdown.style.display='none';this.anchor_block=this.anchor_block||this.anchor.tagName.toLowerCase()=='div';DOMScroll.getScrollRoot().appendChild(this.dropdown);this.dropdown.className+=' typeahead_list_absolute';this.list=$N('div');this.dropdown.appendChild(this.list);this.dropdown.onmousedown=function(_L3){return this.dropdown_onmousedown(_L3||window.event);}.bind(this);if(typeaheadpro.should_use_iframe&&!typeaheadpro.iframe){typeaheadpro.iframe=document.createElement('iframe');typeaheadpro.iframe.src="/common/blank.html";CSS.setClass(typeaheadpro.iframe,'typeahead_iframe');typeaheadpro.iframe.style.display='none';typeaheadpro.iframe.frameBorder=0;DOMScroll.getScrollRoot().appendChild(typeaheadpro.iframe);}if(typeaheadpro.should_use_iframe&&typeaheadpro.iframe)typeaheadpro.iframe.style.zIndex=parseInt(CSS.getStyle(this.dropdown,'zIndex'))-1;this.log_data={'kt':0,'kp':0,'sm':null,'ty':0,'f':1};this.results_text='';this.last_key_suggestion=0;this.status=typeaheadpro.STATUS_BLOCK_ON_SOURCE_BOOTSTRAP;this.clear_placeholder();if(_L1)this.set_source(_L1);if(this.source){this.selectedindex=-1;if(this.focused){this._onfocus();this.show();this._onkeyup();this.set_class('');this.capture_submit();}}else this.hide();onunloadRegister(this._onunload.bind(this),true);}typeaheadpro.prototype.enumerate=false;typeaheadpro.prototype.interactive=false;typeaheadpro.prototype.changed=false;typeaheadpro.prototype.render_block_size=50;typeaheadpro.prototype.typeahead_icon_class=false;typeaheadpro.prototype.typeahead_icon_get_return=false;typeaheadpro.prototype.old_value=null;typeaheadpro.prototype.poll_handle=null;typeaheadpro.prototype.activate_poll_on_focus_events=false;typeaheadpro.prototype.suggestion_count=0;typeaheadpro.STATUS_IDLE=0;typeaheadpro.STATUS_WAITING_ON_SOURCE=1;typeaheadpro.STATUS_BLOCK_ON_SOURCE_BOOTSTRAP=2;typeaheadpro.prototype.clear_value_on_blur=true;typeaheadpro.prototype.max_results=0;typeaheadpro.prototype.max_display=10;typeaheadpro.prototype.allow_placeholders=false;typeaheadpro.prototype.auto_select=true;typeaheadpro.dirty_instances=function(){if(typeaheadpro.instances)typeaheadpro.instances.forEach(function(_L0){_L0.update_status(typeaheadpro.STATUS_BLOCK_ON_SOURCE_BOOTSTRAP);if(_L0.source)_L0.source.is_ready=false;});};typeaheadpro.prototype.set_source=function(_L0){this.source=_L0;this.source.set_owner(this);this.status=typeaheadpro.STATUS_IDLE;this.cache={};this.last_search=0;this.suggestions=[];};typeaheadpro.prototype.setup_anchor=function(){return this.obj;};typeaheadpro.prototype.destroy=function(){if(this.typeahead_icon){DOM.remove(this.typeahead_icon);this.toggle_icon_list=function(){};}this.clear_render_timeouts();if(!this.anchor_block&&this.anchor.nextSibling.tagName.toLowerCase()=='br')DOM.remove(this.anchor.nextSibling);if(this.dropdown)DOM.remove(this.dropdown);if(this.obj){this.obj.onfocus=this.obj.onblur=this.obj.onkeyup=this.obj.onkeydown=this.obj.onkeypress=this.obj.typeahead=null;DOM.remove(this.obj);}this.anchor=this.obj=this.dropdown=null;delete typeaheadpro.instances[this.instance];};typeaheadpro.prototype.check_value=function(){if(this.obj){var _L0=this.obj.value;if(_L0!=this.old_value){this.dirty_results();this.old_value=_L0;if(this.old_value==='')this._onselect(false);}}};typeaheadpro.prototype._onkeyup=function(e){e=$E(e);this.last_key=e?e.keyCode:-1;if(this.key_down==this.last_key)this.key_down=0;var _L1=true;switch(this.last_key){case KEYS.ESC:this.selectedindex=-1;this._onselect(false);this.hide();e.stop();_L1=false;break;}return _L1;};typeaheadpro.prototype._onkeydown=function(e){e=$E(e);this.key_down=this.last_key=e?e.keyCode:-1;this.interactive=true;switch(this.last_key){case 33:case 34:case KEYS.UP:case KEYS.DOWN:this.log_data.kt+=1;if(typeaheadpro.should_simulate_keypress)this._onkeypress({keyCode:this.last_key});return false;case KEYS.TAB:this.log_data.kt+=1;this.select_suggestion(this.selectedindex);if(e.shiftKey){this.reverse_focus();}else this.advance_focus();break;case KEYS.RETURN:this.log_data.sm='key_ret';if(this.select_suggestion(this.selectedindex))this.hide();if(typeof(this.submit_keydown_return)!='undefined')this.submit_keydown_return=this._onsubmit(this.get_current_selection());return this.submit_keydown_return;case 229:if(!this.poll_handle)this.poll_handle=setInterval(this.check_value.bind(this),100);break;default:this.log_data.kp+=1;setTimeout(bind(this,'check_value'),this.source.check_limit);}};typeaheadpro.prototype._onkeypress=function(e){e=$E(e);var _L1=1;this.last_key=e?Event.getKeyCode(e):-1;this.interactive=true;switch(this.last_key){case 33:_L1=this.max_display;case KEYS.UP:this.set_suggestion(_L1>1&&this.selectedindex>0&&this.selectedindex<_L1?0:this.selectedindex-_L1);this.last_key_suggestion=(new Date()).getTime();return false;case 34:_L1=this.max_display;case KEYS.DOWN:if(trim(this.get_value())==''&&!this.enumerate){this.enumerate=true;this.results_text=null;this.dirty_results();}else{this.set_suggestion(this.suggestions.length<=this.selectedindex+_L1?this.suggestions.length-1:this.selectedindex+_L1);this.last_key_suggestion=(new Date()).getTime();}return false;case KEYS.RETURN:var ret=null;if(typeof(this.submit_keydown_return)=='undefined'){ret=this.submit_keydown_return=this._onsubmit(this.get_current_selection());}else{ret=this.submit_keydown_return;delete this.submit_keydown_return;}return ret;default:setTimeout(bind(this,'check_value'),this.source.check_limit);break;}return true;};typeaheadpro.prototype._onchange=function(){this.changed=true;};typeaheadpro.prototype._onfound=function(obj){return this.onfound?this.onfound.call(this,obj):true;};typeaheadpro.prototype._onsubmit=function(obj){if(this.onsubmit){var ret=this.onsubmit.call(this,obj);if(ret&&this.obj.form){if(!this.obj.form.onsubmit||this.obj.form.onsubmit())this.obj.form.submit();return false;}return ret;}else{this.advance_focus();return false;}};typeaheadpro.prototype._onselect=function(obj){var _L1=(function(){if(this.onselect)this.onselect.call(this,obj);}).bind(this);if(obj.no_email){var _L2=new AsyncRequest().setData({action:'require',require_field:'email',uid:obj.i}).setMethod('GET').setReadOnly(true).setURI('/friends/ajax/external.php');new Dialog().setCloseHandler(function(_L3){var _L4=this.getUserData();if(_L4){_L1();}else _L3.set_value('');}.bind(null,this)).setAsync(_L2).show();}else _L1();};typeaheadpro.prototype._onfocus=function(){if(!this.poll_handle&&this.activate_poll_on_focus_events)this.poll_handle=setInterval(this.check_value.bind(this),100);if(this.source)this.source.bootstrap();if(this.last_dropdown_mouse>(new Date()).getTime()-10||this.focused)return;if(this.changed)this.dirty_results();this.focused=true;this.changed=false;this.clear_placeholder();this.results_text='';this.set_class('');this.show();this.capture_submit();if(this.typeahead_icon)show(this.typeahead_icon);};typeaheadpro.prototype._onblur=function(_L0){if(this.last_dropdown_mouse&&this.last_dropdown_mouse>(new Date()).getTime()-10&&this.is_showing_suggestions()){Event.kill(_L0);setTimeout(function(){this.focus();}.bind(this),0);return false;}if(!this.stop_hiding){if(this.showing_icon_list)this.toggle_icon_list(true);}else{this.focus();return false;}this.focused=false;if(this.changed&&!this.interactive){this.dirty_results();this.changed=false;return;}if(!this.suggestions){this._onselect(false);}else if(this.selectedindex>=0&&this.auto_select)this.select_suggestion(this.selectedindex);this.hide();this.update_class();if(this.clear_value_on_blur&&!this.get_value()){var _L1=this.allow_placeholders?this.source.gen_noinput():'';this.set_value(_L1?_L1:'');this.set_class('DOMControl_placeholder');}if(this.poll_handle){clearInterval(this.poll_handle);this.poll_handle=null;}};typeaheadpro.prototype._onunload=function(){if(typeaheadpro.instances[this.instance])this.hide();};typeaheadpro.prototype.typeahead_icon_onclick=function(_L0){this.stop_hiding=true;this.focus();setTimeout(function(){this.toggle_icon_list();}.bind(this),50);Event.kill(_L0);return false;};typeaheadpro.prototype.dropdown_onmousedown=function(_L0){this.last_dropdown_mouse=(new Date()).getTime();};typeaheadpro.prototype.setup_typeahead_icon=function(){this.typeahead_parent=document.createElement('div');CSS.addClass(this.typeahead_parent,'typeahead_parent');this.typeahead_parent.appendChild(this.typeahead_icon);this.obj.parentNode.insertBefore(this.typeahead_parent,this.obj);};typeaheadpro.prototype.mouse_set_suggestion=function(_L0){if(!this.visible)return;if((new Date()).getTime()-this.last_key_suggestion>50)this.set_suggestion(_L0);};typeaheadpro.prototype.capture_submit=function(){if(!typeaheadpro.should_check_missing_events)return;if((!this.captured_form||this.captured_substitute!=this.captured_form.onsubmit)&&this.obj.form){this.captured_form=this.obj.form;this.captured_event=this.obj.form.onsubmit;this.captured_substitute=this.obj.form.onsubmit=function(){return ((this.key_down&&this.key_down!=KEYS.RETURN&&this.key_down!=KEYS.TAB)?this.submit_keydown_return:(this.captured_event?this.captured_event.apply(arguments,this.captured_form):true))?true:false;}.bind(this);}};typeaheadpro.prototype.set_suggestion=function(_L0){this.stop_suggestion_select=false;if(!this.suggestions||this.suggestions.length<=_L0)return;var _L1=this.get_suggestion_node(this.selectedindex);this.selectedindex=(_L0<=-1)?-1:_L0;var _L2=this.get_suggestion_node(this.selectedindex);if(_L1){CSS.removeClass(_L1,'typeahead_selected');CSS.addClass(_L1,'typeahead_not_selected');}if(_L2){CSS.removeClass(_L2,'typeahead_not_selected');CSS.addClass(_L2,'typeahead_selected');}this.recalc_scroll();this._onfound(this.get_current_selection());};typeaheadpro.prototype.get_suggestion_node=function(_L0){var _L1=this.list.childNodes;return _L0==-1?null:_L1[Math.floor(_L0/this.render_block_size)].childNodes[_L0%this.render_block_size];};typeaheadpro.prototype.get_current_selection=function(){return this.selectedindex==-1?false:this.suggestions[this.selectedindex];};typeaheadpro.prototype.update_class=function(){if(this.suggestions&&this.selectedindex!=-1&&typeahead_source.flatten_string(this.get_current_selection().t)==typeahead_source.flatten_string(this.get_value())){this.set_class('typeahead_found');}else this.set_class('');};typeaheadpro.prototype.select_suggestion=function(_L0){if(!this.stop_suggestion_select&&this.current_selecting!=_L0)this.current_selecting=_L0;var _L1=true;if(!this.suggestions||_L0==undefined||_L0===false||this.suggestions.length<=_L0||_L0<0){this._onfound(false);this._onselect(false);this.selectedindex=-1;this.set_class('');_L1=false;}else{this.selectedindex=_L0;var _L2=this.suggestions[_L0].ty;if(_L2!='web'&&_L2!='search')this.set_value(this.suggestions[_L0].t);this.set_class('typeahead_found');this._onfound(this.suggestions[this.selectedindex]);this._onselect(this.suggestions[this.selectedindex]);}if(!this.interactive){this.hide();this.blur();}this.current_selecting=null;if(!_L1&&this.ignore_invalid_suggestion)return false;return true;};typeaheadpro.prototype.is_showing_suggestions=function(){return (this.suggestions)&&(this.suggestions.length>0);};typeaheadpro.prototype.set_value=function(_L0){this.obj.value=_L0;};typeaheadpro.prototype.get_value=function(){if(this.showing_icon_list&&this.old_typeahead_value!=this.obj.value)this.toggle_icon_list();if(this.want_icon_list){return this.typeahead_icon_get_return;}else if(this.showing_icon_list)this.toggle_icon_list();return this.obj.value;};typeaheadpro.prototype.found_suggestions=function(_L0,_L1,_L2){if(!_L0)_L0=[];this.suggestion_count=_L0.length;if(!_L2){this.status=typeaheadpro.STATUS_IDLE;this.add_cache(_L1,_L0);}this.clear_render_timeouts();if(this.get_value()==this.results_text){return;}else if(!_L2){this.results_text=typeahead_source.flatten_string(_L1);if(this.enumerate&&trim(this.results_text)!='')this.enumerate=false;}var _L3=-1;if(this.selectedindex!=-1){var _L4=this.suggestions[this.selectedindex].i;for(var i=0,l=_L0.length;i<l;i++)if(_L0[i].i==_L4){_L3=i;break;}}if(_L3==-1&&this.auto_select&&_L0.length){_L3=0;this._onfound(_L0[0]);}this.selectedindex=_L3;this.suggestions=_L0;if(!_L2)this.real_suggestions=_L0;if(_L0.length){var _L7=[],_L8=Math.ceil(_L0.length/this.render_block_size),_L9={},_La,_Lb=null;DOM.empty(this.list);for(var i=0;i<_L8;i++)this.list.appendChild(document.createElement('div'));if(_L3>-1){_La=Math.floor(_L3/this.render_block_size);_L9[_La]=true;if(_L3%this.render_block_size>this.render_block_size/2){_L9[_La+1]=true;}else if(_La!=0)_L9[_La-1]=true;}else _L9[0]=true;for(var _Lc in _L9){this.render_block(_Lc);sample=this.list.childNodes[_Lc].firstChild;}this.show();if(_L8){var _Ld=sample.offsetHeight;this.render_timeouts=[];for(var i=1;i<_L8;i++)if(!_L9[i]){this.list.childNodes[i].style.height=_Ld*Math.min(this.render_block_size,_L0.length-i*this.render_block_size)+'px';this.render_timeouts.push(setTimeout(this.render_block.bind(this,i),700+i*50));}}}else{this.selectedindex=-1;this.set_message(this.status==typeaheadpro.STATUS_IDLE?this.source.gen_nomatch():this.source.gen_loading());this._onfound(false);}this.recalc_scroll();if(!_L2&&this.results_text!=typeahead_source.flatten_string(this.get_value()))this.dirty_results();};typeaheadpro.prototype.render_block=function(_L0,_L1){var _L2=this.suggestions,_L3=this.selectedindex,_L4=this.get_value(),_L5=this.instance,_L6=[],_L7=this.list.childNodes[_L0];for(var i=_L0*this.render_block_size,l=Math.min(_L2.length,(_L0+1)*this.render_block_size);i<l;i++){_L6.push('<div class="');if(_L3==i){_L6.push('typeahead_suggestion typeahead_selected');}else _L6.push('typeahead_suggestion typeahead_not_selected');if(i>0&&_L2[i-1].o<0&&_L2[i].o>=0)_L6.push(' typeahead_delimiter');_L6.push('" onmouseover="typeaheadpro.instances[',_L5,'].mouse_set_suggestion(',i,')" ','onmousedown="var instance=typeaheadpro.instances[',_L5,']; instance.select_suggestion(',i,');instance.hide();Event.kill(event);">',this.source.gen_html(_L2[i],_L4),'</div>');}_L7.innerHTML=_L6.join('');_L7.style.height='auto';CSS.addClass(_L7,'typeahead_suggestions');};typeaheadpro.prototype.clear_render_timeouts=function(){if(this.render_timeouts){for(var i=0;i<this.render_timeouts.length;i++)clearTimeout(this.render_timeouts[i]);this.render_timeouts=null;}};typeaheadpro.prototype.recalc_scroll=function(){var cn=this.list.firstChild;if(!cn)return;if(cn.childNodes.length>this.max_display){var _L1=cn.childNodes[this.max_display-1];var _L2=_L1.offsetTop+_L1.offsetHeight;this.dropdown.style.height=_L2+'px';var _L3=this.get_suggestion_node(this.selectedindex);if(_L3){var _L4=this.dropdown.scrollTop;if(_L3.offsetTop<_L4){this.dropdown.scrollTop=_L3.offsetTop;}else if(_L3.offsetTop+_L3.offsetHeight>_L2+_L4)this.dropdown.scrollTop=_L3.offsetTop+_L3.offsetHeight-_L2;}if(!typeaheadpro.should_use_overflow){this.dropdown.style.overflowY='scroll';this.dropdown.style.overflowX='hidden';}}else{this.dropdown.style.height='auto';if(!typeaheadpro.should_use_overflow)this.dropdown.style.overflowY='hidden';}};typeaheadpro.prototype.search_cache=function(_L0){return this.cache[typeahead_source.flatten_string(_L0)];};typeaheadpro.prototype.add_cache=function(_L0,_L1){if(this.source.cache_results)this.cache[typeahead_source.flatten_string(_L0)]=_L1;};typeaheadpro.prototype.update_status=function(_L0){this.status=_L0;this.dirty_results();};typeaheadpro.prototype.set_class=function(_L0){CSS.setClass(this.obj,(this.obj.className.replace(/typeahead_[^\s]+/g,'')+' '+_L0).replace(/ {2,}/g,' '));};typeaheadpro.prototype.dirty_results=function(){if(!this.enumerate&&this.get_value().trim()==''){DOM.empty(this.list);this.results_text='';this.set_message(this.source.gen_placeholder());this.suggestions=[];this.selectedindex=-1;return;}else if(this.results_text==typeahead_source.flatten_string(this.get_value())){return;}else if(this.status==typeaheadpro.STATUS_BLOCK_ON_SOURCE_BOOTSTRAP){this.set_message(this.source.gen_loading());return;}var _L0=(new Date()).getTime();var _L1=false;if(this.last_search<=(_L0-this.source.search_limit)&&this.status==typeaheadpro.STATUS_IDLE){_L1=this.perform_search();}else if(this.status==typeaheadpro.STATUS_IDLE)if(!this.search_timeout)this.search_timeout=setTimeout(function(){this.search_timeout=false;if(this.status==typeaheadpro.STATUS_IDLE)this.dirty_results();}.bind(this),this.source.search_limit-(_L0-this.last_search));if(this.source.allow_fake_results&&this.real_suggestions&&!_L1){var _L2=typeahead_source.tokenize(this.get_value()).sort(typeahead_source._sort);var _L3=[];for(var i=0;i<this.real_suggestions.length;i++)if(typeahead_source.check_match(_L2,this.real_suggestions[i].t+' '+this.real_suggestions[i].n))_L3.push(this.real_suggestions[i]);if(_L3.length){this.found_suggestions(_L3,this.get_value(),true);}else{this.selectedindex=-1;this.set_message(this.source.gen_loading());}}};typeaheadpro.prototype.perform_search=function(){if(this.get_value()==this.results_text)return true;var _L0;if((_L0=this.search_cache(this.get_value()))===undefined&&!(_L0=this.source.search_value(this.get_value()))){this.status=typeaheadpro.STATUS_WAITING_ON_SOURCE;this.last_search=(new Date()).getTime();return false;}this.found_suggestions(_L0,this.get_value(),false);return true;};typeaheadpro.prototype.set_message=function(_L0){this.clear_render_timeouts();if(_L0){this.list.innerHTML='<div class="typeahead_message">'+_L0+'</div>';this.reset_iframe();}else this.hide();this.recalc_scroll();};typeaheadpro.prototype.reset_iframe=function(){if(!typeaheadpro.should_use_iframe)return;typeaheadpro.iframe.style.top=this.dropdown.style.top;typeaheadpro.iframe.style.left=this.dropdown.style.left;typeaheadpro.iframe.style.width=this.dropdown.offsetWidth+'px';typeaheadpro.iframe.style.height=this.dropdown.offsetHeight+'px';typeaheadpro.iframe.style.display='';};typeaheadpro.prototype.advance_focus=function(){return this._move_focus(true);};typeaheadpro.prototype.reverse_focus=function(){return this._move_focus(false);};typeaheadpro.prototype._move_focus=function(_L0){var _L1=this.obj.form?get_all_form_inputs(this.obj.form):get_all_form_inputs();var _L2=[];_L2._insert=_L0?_L2.push:_L2.unshift;var _L3=!_L0;for(var i=0;i<_L1.length;i++)if(!_L0&&_L1[i]==this.obj){_L3=false;}else if(_L3&&_L1[i].type!='hidden'&&_L1[i].tabIndex!=-1&&_L1[i].offsetParent){_L2._insert(_L1[i]);}else if(_L1[i]==this.obj)_L3=true;setTimeout(function(){for(var i=0;i<this.length;i++)try{if(this[i].offsetParent){this[i].focus();setTimeout(function(){try{this.focus();}catch(e){}}.bind(this[i]),0);return;}}catch(e){}}.bind(_L2?_L2:[]),0);this.blur();this.hide();};typeaheadpro.prototype.clear_placeholder=function(){if(this.obj.className.indexOf('DOMControl_placeholder')!=-1){this.set_value('');this.set_class('');}};typeaheadpro.prototype.clear=function(){this.set_value('');this.set_class('');this.selectedindex=-1;this.enumerate=false;this.dirty_results();};typeaheadpro.prototype.hide=function(){if(this.stop_hiding)return;this.visible=false;this.dropdown.style.display='none';this.clear_render_timeouts();if(typeaheadpro.should_use_iframe)typeaheadpro.iframe.style.display='none';};typeaheadpro.prototype.show=function(){this.visible=true;if(this.focused){this.dropdown.style.top=elementY(this.anchor)+this.anchor.offsetHeight+'px';this.dropdown.style.left=elementX(this.anchor)+'px';this.dropdown.style.width=(this.anchor.offsetWidth-2)+'px';this.dropdown.style.display='';if(typeaheadpro.should_use_iframe){typeaheadpro.iframe.style.display='';this.reset_iframe();}}};typeaheadpro.prototype.toggle_icon_list=function(_L0){if(this.showing_icon_list){this.showing_icon_list=false;this.source.showing_icon_list=false;if(!_L0)this.focus();CSS.removeClass(this.typeahead_icon,'on_selected');this.want_icon_list=false;this.showing_icon_list=false;this.stop_suggestion_select=true;if(this.obj)this.dirty_results();}else{this.source.showing_icon_list=true;this.old_typeahead_value=this.obj.value;this.stop_suggestion_select=true;this.want_icon_list=true;this.dirty_results();this.focus();CSS.addClass(this.typeahead_icon,'on_selected');this.show();this.set_suggestion(-1);this.showing_icon_list=true;}setTimeout(function(){this.stop_hiding=false;}.bind(this),100);};typeaheadpro.prototype.focus=function(){this.obj.focus();};typeaheadpro.prototype.blur=function(e){if(this.obj)this.obj.blur(e);};typeaheadpro.kill_typeahead=function(obj){if(obj.typeahead){if(!this.anchor_block)obj.parentNode.removeChild(obj.nextSibling);obj.parentNode.removeChild(obj.nextSibling);if(obj.typeahead.source)obj.typeahead.source=obj.typeahead.source.owner=null;obj.onfocus=obj.onblur=obj.onkeypress=obj.onkeyup=obj.onkeydown=obj.typeahead=null;}};
function typeahead_source(){}typeahead_source.prototype.cache_results=false;typeahead_source.prototype.enumerable=false;typeahead_source.prototype.allow_fake_results=false;typeahead_source.prototype.search_limit=10;typeahead_source.prototype.check_limit=10;typeahead_source.prototype.bootstrap=bagofholding;typeahead_source.check_match=function(_L0,_L1){_L1=typeahead_source.tokenize(_L1);for(var i=0,il=_L0.length;i<il;i++)if(_L0[i].length){var _L4=false;for(var j=0,jl=_L1.length;j<jl;j++)if(_L1[j].length>=_L0[i].length&&_L1[j].substring(0,_L0[i].length)==_L0[i]){_L4=true;_L1[j]='';break;}if(!_L4)return false;}return true;};typeahead_source.tokenize=function(_L0,_L1,_L2){return (_L2?_L0:typeahead_source.flatten_string(_L0)).split(_L1?typeahead_source.normalizer_regex_capture:typeahead_source.normalizer_regex);};typeahead_source.normalizer_regex_str='(?:(?:^| +)["\'.\\-]+ *)|(?: *[\'".\\-]+(?: +|$)|[@_]| +)';typeahead_source.normalizer_regex=new RegExp(typeahead_source.normalizer_regex_str,'g');typeahead_source.normalizer_regex_capture=new RegExp('('+typeahead_source.normalizer_regex_str+')','g');typeahead_source.flatten_string=function(_L0){if(!typeahead_source.accents)typeahead_source.accents={a:/\u0430|\u00e0|\u00e1|\u00e2|\u00e3|\u00e4|\u00e5/g,b:/\u0431/g,c:/\u0446|\u00e7/g,d:/\u0434|\u00f0/g,e:/\u044d|\u0435|\u00e8|\u00e9|\u00ea|\u00eb/g,f:/\u0444/g,g:/\u0433/g,h:/\u0445/g,i:/\u0438|\u00ec|\u00ed|\u00ee|\u00ef/g,j:/\u0439/g,k:/\u043a/g,l:/\u043b/g,m:/\u043c/g,n:/\u043d|\u00f1/g,o:/\u043e|\u00f8|\u00f6|\u00f5|\u00f4|\u00f3|\u00f2/g,p:/\u043f/g,r:/\u0440/g,s:/\u0441/g,t:/\u0442/g,u:/\u0443|\u044e|\u00fc|\u00fb|\u00fa|\u00f9/g,v:/\u0432/g,y:/\u044b|\u00ff|\u00fd/g,z:/\u0437/g,ae:/\u00e6/g,oe:/\u0153/g,ts:/\u0446/g,ch:/\u0447/g,sh:/\u0448/g,ya:/\u044f/g};_L0=_L0.toLowerCase();for(var i in typeahead_source.accents)_L0=_L0.replace(typeahead_source.accents[i],i);return _L0;};typeahead_source.prototype.set_owner=function(obj){this.owner=obj;if(this.is_ready)this.owner.update_status(typeaheadpro.STATUS_IDLE);};typeahead_source.prototype.ready=function(){if(this.owner&&!this.is_ready){this.is_ready=true;this.owner.update_status(typeaheadpro.STATUS_IDLE);}else this.is_ready=true;};typeahead_source.highlight_found=function(_L0,_L1){var _L2=[];resultv=typeahead_source.tokenize(_L0,true,true);_L0=typeahead_source.tokenize(_L0,true);_L1=typeahead_source.tokenize(_L1);_L1.sort(typeahead_source._sort);for(var i=0,il=resultv.length;i<il;i++){var _L5=false;for(var j=0,jl=_L1.length;j<jl;j++)if(_L1[j]&&_L0[i].lastIndexOf(_L1[j],0)!=-1){_L2.push('<em>',htmlspecialchars(resultv[i].substring(0,_L1[j].length)),'</em>',htmlspecialchars(resultv[i].substring(_L1[j].length,resultv[i].length)));_L5=true;break;}if(!_L5)_L2.push(htmlspecialchars(resultv[i]));}return _L2.join('');};typeahead_source._sort=function(a,b){return b.length-a.length;};typeahead_source.prototype.gen_nomatch=function(){return this.text_nomatch!=null?this.text_nomatch:_tx("No matches found");};typeahead_source.prototype.gen_loading=function(){return this.text_loading!=null?this.text_loading:_tx("Loading...");};typeahead_source.prototype.gen_placeholder=function(){return this.text_placeholder!=null?this.text_placeholder:_tx("Start typing...");};typeahead_source.prototype.gen_noinput=function(){return this.text_noinput!=null?this.text_noinput:_tx("Start typing...");};typeahead_source.prototype.onselect_not_found=function(){if(typeof this.tokenizer._ontokennotfound!='undefined')this.tokenizer._ontokennotfound(this.obj.value);if(typeof this.tokenizer.onselect!='undefined')return this.tokenizer.onselect();};
function static_source(){this.values=null;this.index=null;this.index_includes_hints=false;this.exclude_ids={};this.parent.construct(this);}static_source.extend('typeahead_source');static_source.prototype.enumerable=true;static_source.prototype.filter_excluded=function(_L0){return _L0.filter((function(_L1){return !this.exclude_ids[_L1.i];}).bind(this));};static_source.prototype.build_index=function(){var _L0=[];var _L1=this.values;var _L2=_L1.length&&typeof _L1[0].i=='undefined';for(var i=0,il=_L1.length;i<il;i++){var _L5=typeahead_source.tokenize(_L1[i].t);for(var j=0,jl=_L5.length;j<jl;j++)_L0.push({t:_L5[j],o:_L1[i]});if(this.index_includes_hints&&_L1[i].s){var _L5=typeahead_source.tokenize(_L1[i].s);for(var j=0,jl=_L5.length;j<jl;j++)_L0.push({t:_L5[j],o:_L1[i]});}if(_L2)_L1[i].i=i;}_L0.sort(function(a,b){return (a.t==b.t)?0:(a.t<b.t?-1:1);});this.index=_L0;this.ready();};static_source.prototype._sort_text_obj=function(a,b){if(a.e&&!b.e)return 1;if(!a.e&&b.e)return -1;return a.t.localeCompare(b.t);};static_source.prototype.search_value=function(_L0){if(!this.is_ready)return;var _L1;if(_L0==''){_L1=this.values;}else{var _L2=typeahead_source.tokenize(_L0).sort(typeahead_source._sort);var _L3=this.index;var lo=0;var hi=this.index.length-1;var p=Math.floor(hi/2);while(lo<=hi){if(_L3[p].t>=_L2[0]){hi=p-1;}else lo=p+1;p=Math.floor(lo+((hi-lo)/2));}var _L1=[];var _L7={};var _L8=typeof _ignoreList!='undefined';for(var i=lo;i<_L3.length&&_L3[i].t.lastIndexOf(_L2[0],0)!=-1;i++){var _La=_L3[i].o.flid?_L3[i].o.flid:_L3[i].o.i;if(typeof _L7[_La]!='undefined'){continue;}else _L7[_La]=true;if((!_L8||!_ignoreList[_La])&&!this.exclude_ids[_La]&&(_L2.length==1||typeahead_source.check_match(_L2,_L3[i].o.t)))_L1.push(_L3[i].o);}}_L1.sort(this._sort_text_obj.bind(this));if(this.owner&&this.owner.max_results)_L1=_L1.slice(0,this.owner.max_results);return _L1;};static_source.prototype.set_exclude_ids=function(ids){this.exclude_ids=ids;};
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);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;},_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("Are you sure you want to navigate away from this page?")).setSummary(_tx("Press {ok} to continue, or {cancel} to stay on the current page.",{ok:_tx("Okay"),cancel:_tx("Cancel")})).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\/50h1guto78kkgooo.pkg.js"]); }