/*
HTTP Host: static.ak.fbcdn.net
Generated: March 18th 2010 3:46:46 PM PDT
Machine: 10.16.140.106
Locale: nu_ll
Path: js/e1vxyn8zdi0cgoo8.pkg.js
*/

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

Book&&Book.at('eval');JX.$A=function(_L0){var r=[];for(var ii=0;ii<_L0.length;ii++)r.push(_L0[ii]);return r;};JX.$AX=function(_L0){return (_L0 instanceof Array)?_L0:[_L0];};JX.copy=function(_L0,_L1){for(var k in _L1)_L0[k]=_L1[k];return _L0;};JX.bind=function(_L0,_L1){var _L2=JX.$A(arguments).slice(2);return function(){return _L1.apply(_L0||window,_L2.concat(JX.$A(arguments)));};};JX.bag=function(){};JX.keys=function(obj){var r=[];for(var k in obj)r.push(k);return r;};JX.defer=function(fn,_L1){return setTimeout(fn,_L1||0);};JX.occur=function(fn){return fn.apply(window);};JX.go=function(uri){(uri&&(window.location=uri))||window.location.reload(true);};
JX.install=function(_L0,_L1){if(typeof JX.install._nextObjectID=='undefined')JX.install._nextObjectID=0;if(_L0 in JX)return;var _L2=[];_L2.push([_L0,_L1]);do{var _L3;var _L4=null;for(var ii=0;ii<_L2.length;++ii){_L3=_L2[ii][1];if(_L3.extend&&!JX[_L3.extend])continue;_L4=_L2[ii][0];_L2.splice(ii,1);--ii;JX[_L4]=function(){this.__id__='__obj__'+(++JX.install._nextObjectID);return (_L3.construct||JX.bag).apply(this,arguments);};JX.copy(JX[_L4],_L3.statics);var _L6;if(_L3.extend){_L6=JX[_L4].prototype=new JX[_L3.extend]();}else _L6=JX[_L4].prototype={};_L6.__class__=JX[_L4];for(var k in (_L3.properties||{})){var _L8=k.charAt(0).toUpperCase()+k.substr(1);var _L9='__auto__'+k;_L6[_L9]=_L3.properties[k];_L6['set'+_L8]=(function(_L9){return function(v){this[_L9]=v;return this;};})(_L9);_L6['get'+_L8]=(function(_L9){return function(){return this[_L9];};})(_L9);}JX.copy(_L6,_L3.members);if(_L3.events&&_L3.events.length){var _La=JX[_L3.extend]||{};JX[_L4].__name__='class:'+_L4;var _Lb=_La.__path__||[];JX[_L4].__path__=_Lb.concat([JX[_L4].__name__]);_L6.invoke=function(_Lc){return JX.Stratcom.invoke('obj:'+_Lc,this.__class__.__path__.concat([this.__id__]),{args:JX.$A(arguments).slice(1)});};_L6.listen=function(_Lc,_Ld){return JX.Stratcom.listen('obj:'+_Lc,this.__id__,JX.bind(this,function(e){return _Ld.apply(this,e.getData().args);}));};JX[_L4].listen=function(_Lc,_Ld){return JX.Stratcom.listen('obj:'+_Lc,this.__name__,JX.bind(this,function(e){return _Ld.apply(this,e.getData().args);}));};}(_L3.initialize||JX.bag)();}}while(_L4);};
JX.install('Event',{members:{stop:function(){var r=this.getRawEvent();if(r){r.cancelBubble=true;r.stopPropagation&&r.stopPropagation();}this.setStopped(true);return this;},prevent:function(){var r=this.getRawEvent();if(r){r.returnValue=false;r.preventDefault&&r.preventDefault();}this.setPrevented(true);return this;},kill:function(){this.prevent();this.stop();return this;},getSpecialKey:function(){var r=this.getRawEvent();if(!r||r.shiftKey)return null;var c=r.keyCode;do{c=JX.Event._keymap[c]||null;}while(c&&JX.Event._keymap[c]);return c;}},statics:{_keymap:{8:'delete',9:'tab',13:'return',27:'esc',37:'left',38:'up',39:'right',40:'down',63232:38,63233:40,62234:37,62235:39}},properties:{rawEvent:null,type:null,target:null,data:null,path:[],stopped:false,prevented:false,persistent:false,nodes:{}},initialize:function(){}});
JX.install('Stratcom',{statics:{ready:false,_targets:{},_handlers:[],_need:{},_matchName:/\bFN_([^ ]+)/,_matchData:/\bFD_([^ ]+)/,_auto:'*',_data:{},_execContext:[],_persistent:[],_dataref:9000,invoke:function(_L0,_L1,_L2,_L3){var _L4=new JX.Event().setType(_L0).setData(_L2||{}).setPath(_L1||[]);if(!!_L3)this._persist(_L4);return this._dispatchProxy(_L4);},listen:function(_L0,_L1,_L2){var ids=[];_L0=JX.$AX(_L0);if(!_L1)_L1=this._auto;if(!(_L1 instanceof Array))_L1=[[_L1]];if(!(_L1[0] instanceof Array))_L1=[_L1];for(var ii=0;ii<_L0.length;++ii){var _L5=_L0[ii];if(!(_L5 in this._targets))this._targets[_L5]={};var _L6=this._targets[_L5];for(var jj=0;jj<_L1.length;++jj){var _L8=_L1[jj];var id=this._handlers.length;this._handlers.push(_L2);this._need[id]=_L8.length;ids.push(id);for(var kk=0;kk<_L8.length;++kk){if(!_L6[_L8[kk]])_L6[_L8[kk]]=[];_L6[_L8[kk]].push(id);}}}var _Lb=this._persistent;for(var ii=0;ii<_Lb.length;ii++)_Lb[ii]&&JX.Stratcom._dispatchProxy(_Lb[ii]);return {remove:function(){for(var ii=0;ii<ids.length;ii++)delete JX.Stratcom._handlers[ids[ii]];}};},dispatch:function(_L0){try{var _L1=_L0.srcElement||_L0.target;if(_L1===window||(!_L1||_L1.nodeName=='#document'))_L1={nodeName:'window'};}catch(x){var _L1=null;}var _L2=[];var _L3=[];var _L4={};var _L5=_L1;while(_L5){var _L6=_L5.className||'';var _L7;if(_L7=(_L6.match(this._matchName)||[])[1]){_L4[_L7]=this.getData(_L5);_L3[_L7]=_L5;_L2.push(_L7);}if(_L5.id){_L7='id:'+_L5.id;_L4[_L7]=_L5;_L2.push(_L7);}_L5=_L5.parentNode;}if(_L1){var _L8='tag:'+_L1.nodeName.toLowerCase();_L2.push(_L8);_L4[_L8]=null;}var _L9=_L0.type;var _La={focusin:'focus',focusout:'blur'};if(_L9 in _La)_L9=_La[_L9];var _Lb=new JX.Event().setRawEvent(_L0).setType(_L9).setTarget(_L1).setData(_L4).setNodes(_L3).setPath(_L2.reverse());if(_L0.persistent)this._persist(_Lb);return this._dispatchProxy(_Lb);},_dispatchProxy:function(_L0){var _L1=this._targets[_L0.getType()];if(!_L1)return _L0;var _L2=_L0.getPath();var len=_L2.length;var _L4={};var _L5;for(var _L6=-1;_L6<len;++_L6){if(_L6==-1){_L5=_L1[this._auto];}else _L5=_L1[_L2[_L6]];if(!_L5)continue;for(var ii=0;ii<_L5.length;++ii)_L4[_L5[ii]]=(_L4[_L5[ii]]||0)+1;}var _L8=[];for(var k in _L4)if(_L4[k]==this._need[k]){var _La=this._handlers[k];if(!_La)continue;_L8.push(_La);}this._execContext.push({handlers:_L8,event:_L0,cursor:0});if(this.pass()&&(_L0.getPersistent()!==false))delete this._persistent[_L0.getPersistent()];this._execContext.pop();return _L0;},_persist:function(_L0){for(var ii=0;true;ii++)if(!this._persistent[ii]){this._persistent[ii]=_L0;_L0.setPersistent(ii);break;}},pass:function(){var _L0=this._execContext[this._execContext.length-1];while(_L0.cursor<_L0.handlers.length){var _L1=_L0.cursor;++_L0.cursor;(_L0.handlers[_L1]||JX.bag)(_L0.event);if(_L0.event.getStopped())break;}return _L0.event.getStopped()||_L0.event.getPrevented();},context:function(){if(!this._execContext.length)return null;return this._execContext[this._execContext.length-1].event;},mergeData:function(_L0){JX.copy(this._data,_L0);JX.Stratcom.ready=true;JX.__rawEventQueue({type:'start-queue'});},sigilize:function(_L0,_L1,_L2){var _L3=[_L0.className];if(_L2){this._data[this._dataref]=_L2;_L3.push('FD_'+(this._dataref++));}_L3.push('FN_'+_L1);_L0.className=_L3.reverse().join(' ');},hasSigil:function(_L0,_L1){return (_L0.className.match(this._matchName)||[])[1]==_L1;},getData:function(_L0){var idx=((_L0.className||'').match(this._matchData)||[])[1];return (idx&&this._data[idx])||{};}},initialize:function(){JX.Stratcom.listen('click','tag:a',function(e){window.name='z:'+(new Date().getTime());});}});
JX.install('Boot',{statics:{_hardpoint:null,_call:[],_need:{},_wait:{},_have:{},load:function(_L0,_L1){var id=this._call.length;this._call.push(_L1);var _L3=0;for(var k in _L0){if(k in this._have)continue;if(_L0[k].type=='js'){if(!this._wait[_L0[k].name])this._wait[_L0[k].name]={};this._wait[_L0[k].name][id]=true;_L3++;}}this._need[id]=_L3;if(!this._need[id])this._invoke(id);for(var k in _L0){if(k in this._have)continue;this.loadRawResource(_L0[k].type,_L0[k].name);}},loadRawResource:function(_L0,src){var _L2;switch(_L0){case 'js':_L2=document.createElement('script');_L2.type='text/javascript';_L2.src=src;break;case 'css':_L2=document.createElement('link');_L2.rel="stylesheet";_L2.type="text/css";_L2.media="all";_L2.href=src;break;}this._getHardpoint().appendChild(_L2);},done:function(_L0){for(var id in (this._wait[_L0]||{}))if(!--this._wait[_L0][k]){delete this._wait[_L0][k];this._invoke(id);}},_invoke:function(id){setTimeout(this._call[id],0);delete this._need[id];delete this._call[id];},_getHardpoint:function(){if(!this._hardpoint){var n,_L1=document.getElementsByTagName('head');if(_L1.length){n=_L1[0];}else n=document.body;this._hardpoint=n;}return this._hardpoint;}}});
JX.install('$V',{construct:function(x,y){if(this==JX||this==window)return new JX.$V(x,y);if(typeof y=='undefined')return JX.$V.getPos(x);this.x=parseFloat(x);this.y=parseFloat(y);},members:{x:null,y:null,setPos:function(n){n.style.left=(this.x===null)?'':(parseInt(this.x,10)+'px');n.style.top=(this.y===null)?'':(parseInt(this.y,10)+'px');return this;},setDim:function(n){n.style.width=(this.x===null)?'':(parseInt(this.x,10)+'px');n.style.height=(this.y===null)?'':(parseInt(this.y,10)+'px');return this;},add:function(x,y){if(x instanceof JX.$V)return this.add(x.x,x.y);return JX.$V(this.x+parseFloat(x),this.y+parseFloat(y));}},statics:{_viewport:null,getPos:function(n){JX.Event&&(n instanceof JX.Event)&&(n=n.getRawEvent());if(('pageX' in n)||('clientX' in n)){var c=JX.$V._viewport;return JX.$V(n.pageX||(n.clientX+c.scrollLeft),n.pageY||(n.clientY+c.scrollTop));}var x=n.offsetLeft;var y=n.offsetTop;while(n.offsetParent&&(n.offsetParent!=document.body)){n=n.offsetParent;x+=n.offsetLeft;y+=n.offsetTop;}return JX.$V(x,y);},getDim:function(n){return JX.$V(n.offsetWidth,n.offsetHeight);},getScroll:function(){var b=document.body;var e=document.documentElement;return JX.$V(b.scrollLeft||e.scrollLeft,b.scrollTop||e.scrollTop);},getViewport:function(){var c=JX.$V._viewport;var w=window;return JX.$V(w.innerWidth||c.clientWidth||0,w.innerHeight||c.clientHeight||0);},getDocument:function(){var c=JX.$V._viewport;return JX.$V(c.scrollWidth||0,c.scrollHeight||0);}},initialize:function(){var c=((c=document)&&(c=c.documentElement))||((c=document)&&(c=c.body));JX.$V._viewport=c;}});
JX.install('HTML',{construct:function(str){if(this==JX||this==window)return new JX.HTML(str);this._content=str;},members:{_content:null,getFragment:function(){var _L0=JX.$N('div');_L0.innerHTML=this._content;var _L1=document.createDocumentFragment();while(_L0.firstChild)_L1.appendChild(_L0.removeChild(_L0.firstChild));return _L1;}}});JX.install('$',{construct:function(id){var _L1=document.getElementById(id);if(!_L1||(_L1.id!=id))throw JX.$.NotFound;return _L1;},statics:{NotFound:{}},initialize:function(){}});JX.install('$N',{construct:function(tag,_L1,_L2){if(typeof _L2=='undefined'&&(typeof _L1!='object'||_L1 instanceof JX.HTML)){_L2=_L1;_L1={};}var _L3=document.createElement(tag);if(_L1.style){JX.copy(_L3.style,_L1.style);delete _L1.style;}if(_L1.sigil){JX.Stratcom.sigilize(_L3,_L1.sigil,_L1.meta);delete _L1.sigil;delete _L1.meta;}JX.copy(_L3,_L1);if(_L2)JX.DOM.setContent(_L3,_L2);return _L3;}});JX.install('DOM',{statics:{_autoid:0,_metrics:{},_bound:{},setContent:function(_L0,_L1){while(_L0.firstChild)JX.DOM.remove(_L0.firstChild);JX.DOM.appendContent(_L0,_L1);},prependContent:function(_L0,_L1){this._insertContent(_L0,_L1,this._mechanismPrepend);},appendContent:function(_L0,_L1){this._insertContent(_L0,_L1,this._mechanismAppend);},_mechanismPrepend:function(_L0,_L1){_L0.insertBefore(_L1,_L0.firstChild);},_mechanismAppend:function(_L0,_L1){_L0.appendChild(_L1);},_insertContent:function(_L0,_L1,_L2){if(_L1===null||typeof _L1=='undefined')return;if(_L1 instanceof JX.HTML)_L1=_L1.getFragment();if(_L1 instanceof Array){for(var ii=0;ii<_L1.length;ii++){var _L4=(typeof _L1[ii]=='string')?document.createTextNode(_L1[ii]):_L1[ii];_L2(_L0,_L4);}}else if(_L1.nodeType){_L2(_L0,_L1);}else _L2(_L0,document.createTextNode(_L1));},remove:function(_L0){_L0.parentNode&&JX.DOM.replace(_L0,null);return _L0;},replace:function(_L0,_L1){var _L2;if(_L0.nextSibling){_L2=JX.bind(_L0.nextSibling,function(_L3,_L4){_L3.insertBefore(_L4,this);});}else _L2=this._mechanismAppend;var _L3=_L0.parentNode;_L0.parentNode.removeChild(_L0);this._insertContent(_L3,_L1,_L2);return _L0;},serialize:function(_L0){var _L1=_L0.elements;var _L2={};for(var ii=0;ii<_L1.length;++ii){if(!_L1[ii].name)continue;var _L4=_L1[ii].type;var tag=_L1[ii].tagName;if((_L4 in {radio:1,checkbox:1}&&_L1[ii].checked)||_L4 in {text:1,hidden:1,password:1}||tag in {TEXTAREA:1,SELECT:1})_L2[_L1[ii].name]=_L1[ii].value;}return _L2;},isNode:function(_L0){return !!(_L0&&_L0.nodeName&&(_L0!==window));},isType:function(_L0,_L1){_L0=(''+_L0.nodeName||'').toUpperCase();_L1=JX.$AX(_L1);for(var ii=0;ii<_L1.length;++ii)if(_L1[ii].toUpperCase()==_L0)return true;return false;},listen:function(_L0,_L1,_L2,_L3){return JX.Stratcom.listen(_L1,['id:'+JX.DOM.uniqID(_L0)].concat(JX.$AX(_L2||[])),_L3);},uniqID:function(_L0){if(!_L0.id)_L0.id='autoid_'+(++JX.DOM._autoid);return _L0.id;},alterClass:function(_L0,_L1,add){var has=((' '+_L0.className+' ').indexOf(' '+_L1+' ')>-1);if(add&&!has){_L0.className+=' '+_L1;}else if(has&&!add)_L0.className=_L0.className.replace(new RegExp('(^|\\s)'+_L1+'(?:\\s|$)','g'),' ');},htmlize:function(str){return (''+str).replace(/&/g,'&amp;').replace(/"/g,'&quot;').replace(/</g,'&lt;').replace(/>/g,'&gt;');},show:function(){for(var ii=0;ii<arguments.length;++ii)arguments[ii].style.display='';},hide:function(){for(var ii=0;ii<arguments.length;++ii)arguments[ii].style.display='none';},textMetrics:function(_L0,_L1,x){if(!this._metrics[_L1]){var n=JX.$N('var',{className:_L1});this._metrics[_L1]=n;}var _L4=this._metrics[_L1];document.body.appendChild(_L4);_L4.style.width=x?(x+'px'):'';JX.DOM.setContent(_L4,JX.HTML(JX.DOM.htmlize(_L0.value).replace(/\n/g,'<br />')));var _L5=JX.$V.getDim(_L4);document.body.removeChild(_L4);return _L5;},scry:function(_L0,_L1,_L2){var _L3=_L0.getElementsByTagName(_L1);if(!_L2)return JX.$A(_L3);var _L4=[];for(var ii=0;ii<_L3.length;ii++)if(JX.Stratcom.hasSigil(_L3[ii],_L2))_L4.push(_L3[ii]);return _L4;},find:function(_L0,_L1,_L2){var _L3=JX.DOM.scry(_L0,_L1,_L2);if(!_L3.length)throw JX.$.NotFound;return _L3[0];},bindController:function(_L0,_L1,_L2){var id=JX.DOM.uniqID(_L0);var map=(this._bound[_L1]=(this._bound[_L1]||{}));return (map[id]=(map[id]||(_L2())));},focus:function(_L0){try{_L0.focus();}catch(lol_ie){}}}});
JX.install('FX',{statics:{_blindDepth:0,_blind:null,showBlind:function(){if(!this._blindDepth){this._blind=JX.$N('div',{className:'LFXBlind'});document.body.appendChild(this._blind);JX.$V.getDim(document.body).setDim(this._blind);}++this._blindDepth;},hideBlind:function(){--this._blindDepth;if(!this._blindDepth){JX.DOM.remove(this._blind);this._blind=null;}}}});JX.install('Progressbar',{construct:function(_L0,bar,_L2,_L3){this._hardpointNode=_L0;this._barNode=bar;this._barNode.style.width='0';this._total=_L2;this._cancelCallback=_L3;this._listener=JX.DOM.listen(this._hardpointNode,'click',['cancel','tag:button'],JX.bind(this,this._cancel));JX.DOM.show(this._hardpointNode);},members:{_progress:0,_total:0,_barNode:null,_hardpointNode:null,_listener:null,_cancelCallback:null,update:function(){++this._progress;this._draw();},set:function(n){this._progress=n;this._total=1;this._draw();},end:function(){if(this._total===null)return;JX.DOM.hide(this._hardpointNode);},_draw:function(){if(this._total===null)return;var _L0=parseInt(100*this._progress/this._total);this._barNode.style.width=_L0+'%';},_cancel:function(){this._listener.remove();this.end();this._total=null;(this._cancelCallback||JX.bag)();}}});
JX.install('Flash',{construct:function(src,_L1,id){JX.copy(this,{_attrs:{},_params:{wmode:'transparent'},_vars:{},_container:JX.$(_L1)});var v=JX.$V.getDim(this._container);this.setAttributes({classid:'clsid:D27CDB6E-AE6D-11cf-96B8-444553540000',type:JX.Flash._MIMETYPE,data:src,width:v.x,height:v.y,id:id});},statics:{_MIMETYPE:'application/x-shockwave-flash'},members:{setAttributes:function(_L0){JX.copy(this._attrs,_L0);return this;},setVariables:function(_L0){JX.copy(this._vars,_L0);return this;},setParameters:function(_L0){JX.copy(this._params,_L0);return this;},_getParameters:function(){var _L0=[];for(var k in this._vars)_L0.push(encodeURIComponent(k)+'='+encodeURIComponent(this._vars[k]));if(_L0.length)this._params['flashvars']=_L0.join('&');return this._params;},_renderAsMarkup:function(){var _L0=this._attrs;var _L1=this._getParameters();_L1.movie=_L0.data;delete _L0.data;delete _L0.type;var _L2=[];for(var k in _L0)_L2.push(JX.DOM.htmlize(k)+'="'+JX.DOM.htmlize(_L0[k])+'"');_L2=_L2.join(' ');var _L4=[];for(var k in _L1)_L4.push('<param name="'+JX.DOM.htmlize(k)+'" value="'+JX.DOM.htmlize(_L1[k])+'" />');_L4=_L4.join("\n");return '<object '+_L2+'>'+_L4+'</object>';},_renderAsNode:function(){var obj=JX.$N('object',this._attrs);var _L1=this._getParameters();for(var k in _L1)obj.appendChild(JX.$N('param',{name:k,value:_L1[k]}));return obj;},render:function(){if(document.attachEvent){this._container.innerHTML=this._renderAsMarkup();}else JX.DOM.setContent(this._container,this._renderAsNode());}}});
JX.install('JSON',{statics:{serialize:function(obj){return JX.JSON._val(obj);},_val:function(val){var out=[];if(val.push&&val.pop){for(var ii=0;ii<val.length;ii++)out.push(JX.JSON._val(val[ii]));return '['+out.join(',')+']';}else if(val===null){return 'null';}else if(val===true){return 'true';}else if(val===false){return 'false';}else if(typeof val=='string'){return JX.JSON._esc(val);}else if(typeof val=='number'){return val;}else{for(var k in val)out.push(JX.JSON._esc(k)+':'+JX.JSON._val(val[k]));return '{'+out.join(',')+'}';}},_esc:function(str){return '"'+str.replace(/\\/g,'\\\\').replace(/"/g,'\\"')+'"';}}});
JX.install('Request',{construct:function(uri,_L1){this.setURI(uri);if(_L1)this.listen('done',_L1);},events:['done','error','finally'],members:{_xhrkey:null,_transport:null,_aborted:false,send:function(){var _L0=null;try{try{_L0=new XMLHttpRequest();}catch(x){_L0=new ActiveXObject("Msxml2.XMLHTTP");}}catch(x){_L0=new ActiveXObject("Microsoft.XMLHTTP");}this._transport=_L0;this._xhrkey=JX.Request._xhr.length;JX.Request._xhr.push(this);_L0.onreadystatechange=JX.bind(this,this._onreadystatechange);var q=[];var _L2=this.getData()||{};_L2.__async__=true;for(var k in _L2)q.push(encodeURIComponent(k)+'='+encodeURIComponent(_L2[k]));q=q.join('&');var uri=this.getURI();if(this.getMethod()=='GET')uri+=((uri.indexOf('?')===-1)?'?':'&')+q;_L0.open(this.getMethod(),uri,true);if(this.getMethod()=='POST'){_L0.setRequestHeader('Content-Type','application/x-www-form-urlencoded');_L0.send(q);}else _L0.send(null);},abort:function(){this._aborted=true;this._transport.abort();delete JX.Request._xhr[this._xhrkey];},_onreadystatechange:function(){var xport=this._transport;try{if(this._aborted)return;if(xport.readyState!=4)return;if(xport.status<200&&xport.status>=300){this._fail();return;}var text=xport.responseText.substring('for (;;);'.length);var response=eval('('+text+')');}catch(exception){this._fail();return;}try{if(response.error){this._fail(response.error);}else{JX.Stratcom.mergeData(response.javelin_metadata||{});JX.initBehaviors(response.javelin_behaviors||{});this._done(response);}}catch(exception){JX.defer(function(){throw exception;});}},_fail:function(_L0){this.invoke('error',_L0);delete JX.Request._xhr[this._xhrkey];this.invoke('finally');},_done:function(_L0){if(_L0.onload)for(var ii=0;ii<_L0.onload.length;ii++)(new Function(_L0.onload[ii]))();this.invoke('done',this.getRaw()?_L0:_L0.payload);delete JX.Request._xhr[this._xhrkey];this.invoke('finally');}},statics:{_xhr:[],shutdown:function(){for(var ii=0;ii<JX.Request._xhr.length;ii++)try{JX.Request._xhr[ii]&&JX.Request._xhr[ii].abort();}catch(x){}JX.Request._xhr=[];}},properties:{URI:null,data:null,method:'POST',raw:false},initialize:function(){JX.Stratcom.listen('unload','tag:window',JX.Request.shutdown);}});
JX.install('Pipeline',{statics:{_count:0,_requests:{},_active:null,_paused:false,start:function(_L0){JX.Stratcom.listen('focus','tag:window',JX.Pipeline.resume);JX.Stratcom.listen('blur','tag:window',JX.Pipeline.pause);JX.Pipeline._requests=_L0||{};JX.defer(JX.Pipeline._connect,10000);},addRequest:function(_L0,_L1){JX.Pipeline._requests[_L0]=_L1;},_connect:function(){if(JX.Pipeline._paused)return;JX.Pipeline._count++;var _L0={requests:JX.JSON.serialize(JX.Pipeline._requests),count:JX.Pipeline._count};JX.Pipeline._active=new JX.Request('/@/',JX.Pipeline._onresponse).setData(_L0);JX.Pipeline._active.send();},_onresponse:function(r){JX.Pipeline._active=null;var _L1=r.events;var _L2=Math.max(1000,r.interval*1000);for(var ii=0;ii<_L1.length;ii++)JX.Stratcom.invoke(_L1[ii].event,_L1[ii].path,_L1[ii].data);JX.defer(JX.Pipeline._connect,_L2);},resume:function(e){if(!JX.Pipeline._active)JX.Pipeline._connect();JX.Pipeline._paused=false;},pause:function(e){if(JX.Pipeline._active){JX.Pipeline._active.abort();JX.Pipeline._active=null;}JX.Pipeline._paused=true;}}});
JX.install('Workflow',{construct:function(uri,_L1){this.setURI(uri);this.setData(_L1||{});},events:['error','finally'],statics:{_stack:[],newFromForm:function(_L0,_L1){var _L2=[].concat(JX.DOM.scry(_L0,'input'),JX.DOM.scry(_L0,'button'),JX.DOM.scry(_L0,'textarea'));for(var ii=0;ii<_L2.length;ii++)if(_L2[ii].disabled){delete _L2[ii];}else _L2[ii].disabled=true;var _L4=new JX.Workflow(_L0.getAttribute('action'),JX.copy(_L1||{},JX.DOM.serialize(_L0)));_L4.listen('finally',function(){for(var ii=0;ii<_L2.length;ii++)_L2[ii]&&(_L2[ii].disabled=false);});return _L4;},newFromLink:function(_L0){return new JX.Workflow(_L0.href);},_push:function(_L0){JX.FX.showBlind();JX.Workflow._stack.push(_L0);},_pop:function(){JX.Workflow._stack.pop()._destroy();JX.FX.hideBlind();},disable:function(){JX.Workflow._disabled=true;},_onbutton:function(_L0){if(JX.Workflow._disabled)return;var t=_L0.getTarget();if(t.name=='__cancel__'||t.name=='__close__'){JX.Workflow._pop();}else{var _L2=JX.Workflow._stack[JX.Workflow._stack.length-1];_L2._destroy();var _L3=_L0.getNodes().LDialog;var _L4=JX.DOM.serialize(_L3);_L4[t.name]=true;_L2.setURI(_L3.getAttribute('action')||_L2.getURI()).setData(_L4).start();}_L0.prevent();}},members:{_root:null,_pushed:false,_onload:function(r){if(r.redirect){JX.go(r.redirect,true);}else if(r.dialog){this._push();this._root=JX.$N('div',{className:'LJSDialog'},JX.HTML(r.dialog));JX.DOM.listen(this._root,'click','tag:button',JX.Workflow._onbutton);document.body.appendChild(this._root);var d=JX.$V.getDim(this._root);var v=JX.$V.getViewport();var s=JX.$V.getScroll();JX.$V((v.x-d.x)/2,s.y+100).setPos(this._root);try{JX.DOM.focus(JX.DOM.find(this._root,'button','__default__'));var _L4=JX.DOM.scry(this._root,'input');for(var ii=0;ii<_L4.length;++ii)if(_L4[ii].type!='hidden'){JX.DOM.focus(_L4[ii]);break;}}catch(_ignored){}}else if(this.getHandler()){this.getHandler()(r);this._pop();}else ;},_push:function(){if(!this._pushed){this._pushed=true;JX.Workflow._push(this);}},_pop:function(){if(this._pushed){this._pushed=false;JX.Workflow._pop();}},_destroy:function(){if(this._root){JX.DOM.remove(this._root);this._root=null;}},start:function(){var uri=this.getURI();var r=new JX.Request(uri,JX.bind(this,this._onload));r.setData(this.getData());r.listen('finally',JX.bind(this,this.invoke,'finally'));r.listen('error',JX.bind(this,function(_L2){this.invoke('error',_L2);if(!JX.Stratcom.pass())JX.go(uri.match(/^(https?:\/\/[^\/]+)?\/?w\//)?'/error/':uri,true);}));r.send();}},properties:{handler:null,data:null,URI:null},initialize:function(){JX.Stratcom.listen('keydown',null,function(e){if(e.getSpecialKey()!='esc'||JX.Workflow._disabled||JX.Stratcom.pass())return;var _L1=JX.Workflow._stack[JX.Workflow._stack.length-1];if(!_L1)return;var _L2=[];var _L3=JX.DOM.scry(_L1._root,'button');for(var ii=0;ii<_L3.length;ii++)if(JX.Stratcom.hasSigil(_L3[ii],'__cancel__')||_L3[ii].name&&_L3[ii].name=='__close__')_L2.push(_L2[ii]);if(_L2.length){JX.Workflow._pop();e.prevent();}});}});
(function(JX){var _L1={};var _L2={};JX.behavior=function(_L3,_L4){_L1[_L3]=_L4;};JX.initBehaviors=function(map){for(var _L4 in map){var _L5=map[_L4];if(!_L5.length)if(_L4 in _L2){continue;}else _L5=[null];for(var ii=0;ii<_L5.length;ii++)_L1[_L4](_L5[ii]);_L2[_L4]=true;}};})(JX);
JX.behavior('attach-photo',function(_L0){JX.Stratcom.listen('submit','attach-photo',function(e){var _L2=e.getTarget();if(_L2.id!=_L0.form)return;var _L3,_L4=JX.DOM.uniqID(JX.$N('a'));try{_L3=document.createElement('<iframe name="'+_L4+'">');}catch(x){_L3=JX.$N('iframe');_L3.name=_L4;}_L3.style.position='absolute';_L3.style.left='-50000px';_L3.src='about:blank';document.body.appendChild(_L3);_L2.target=_L4;var _L5=JX.$N('input',{type:'hidden',name:'__jsonp__',value:_L3.name});_L2.appendChild(_L5);var _L6=JX.Stratcom.listen('jsonp-response',null,function(e){var _L7=e.getData();if(_L7.jsonp!=_L3.name)return;_L6.remove();e.kill();JX.DOM.remove(_L3);_L2.reset();var img=JX.$N('img');img.onload=function(){JX.FX.hideBlind();};img.src=_L7.uri;JX.$(_L0.image).src=_L7.uri;});JX.defer(function(){JX.FX.showBlind();_L2.submit();JX.DOM.remove(_L5);});e.prevent();});});
JX.behavior('chat-popout',function(_L0){JX.Stratcom.listen('click','quack',function(e){var _L2='fbChatWindow';var _L3='status=0,toolbar=0,location=0,menubar=0,directories=0,'+'resizable=1,scrollbars=0,width=560,height=330,left=30,'+'top=30';var _L4=window.open('',_L2,_L3);if(_L4.location.href.indexOf(_L0.uri)==-1)_L4.location=_L0.uri;_L4.focus();e.prevent();JX.Stratcom.invoke('channel-popout');});});
JX.behavior('ci-add-contact',function(_L0){function _L1(_L2,_L3){for(var i=0;i<_L2.length;i++)if(_L2[i].type=='checkbox')_L2[i].checked=_L3;}JX.Stratcom.listen('click','friend-select',function(e){var _L3=e.getNodes()['friend-select'].checked;var _L4=JX.DOM.scry(e.getNodes()['friend-form'],'input','ci-friendable');_L1(_L4,_L3);});JX.Stratcom.listen('click','invite-select',function(e){var _L3=e.getNodes()['invite-select'].checked;var _L4=JX.DOM.scry(e.getNodes()['invite-form'],'input','ci-invitable');_L1(_L4,_L3);});JX.Stratcom.listen('click','friend-skip',function(e){if(!_L0)return;e.prevent();var _L3=e.getNodes()['friend-form'];var _L4=JX.DOM.find(_L3.parentNode,'form','invite-form');JX.DOM.hide(_L3);JX.DOM.show(_L4);});JX.Stratcom.listen('submit','friend-form',function(e){if(!_L0)return;e.prevent();var _L3=e.getNodes()['friend-form'];console.log(_L3);var _L4=JX.DOM.find(_L3.parentNode,'form','invite-form');JX.DOM.hide(_L3);JX.DOM.show(_L4);JX.Workflow.newFromForm(_L3).setHandler(function(r){}).start();});JX.Stratcom.listen('submit','invite-form',function(e){e.prevent();var _L3=e.getNodes()['invite-form'];JX.Workflow.newFromForm(_L3).start();});});
JX.behavior('ci-check-api',function(_L0){var _L1=null;var _L2=null;function _L3(_Lb){var _Lc=_Lb+"=";var ca=document.cookie.split(';');for(i=0;i<ca.length;i++){var c=ca[i];while(c.charAt(0)==' ')c=c.substring(1,c.length);if(c.indexOf(_Lc)==0)return decodeURIComponent(c.substring(_Lc.length,c.length));}return null;}function _L4(_Lb,_Lc){document.cookie=_Lb+"="+encodeURIComponent(_Lc)+"; path=/; domain=."+window.location.hostname.replace(/^.*(facebook\..*)$/i,'$1');}function _L5(_Lb,_Lc){var _Ld=null;var val=_L3('fb_api_auth_token');if(val&&val.substr(0,1)==_Lb)_Ld=val.substr(2);if(_Ld){_Lc.api_instance.value=_Lb;_Lc.auth_token.value=_Ld;_Lc.submit();}else this.cookieTimer=setTimeout(JX.bind(this,_L5,_Lb,_Lc),500);}function _L6(_Lb,_Lc){if(_L3('fb_api_auth_token'))_L4('fb_api_auth_token','');if(this.cookieTimer)clearTimeout(this.cookieTimer);_L5(_Lb,_Lc);}function _L7(_Lb){if(this.keypressTimer)clearTimeout(this.keypressTimer);this.keypressTimer=setTimeout(JX.bind(this,_L8,_Lb),300);}function _L8(_Lb){if(this.keypressTimer)clearTimeout(this.keypressTimer);_L9(_Lb);this.keypressTimer=setTimeout(JX.bind(this,_L8,_Lb),1000);}function _L9(_Lb){var _Lc=_Lb.email.value;var _Ld=_Lc.split('@')[1];if(_L0[_Ld]){JX.DOM.hide(JX.DOM.find(_Lb,'tr','ci-password'));}else JX.DOM.show(JX.DOM.find(_Lb,'tr','ci-password'));}function _La(_Lb,_Lc){var _Ld=_Lc.email.value;var _Le=600;var _Lf=400;if(_Lb==2){_Lf=500;}else if(_Lb==3)_Lf=450;var _L10=((screen.width-_Le)/2);var _L11=((screen.height-_Lf)/2);var _L12='status=0,toolbar=0,location=1,resizable=1,scrollbars=1,alwaysRaised=1,'+'width='+_Le+',height='+_Lf+',left='+_L10+',top='+_L11;var url='/find-friends/api/auth/?api_instance='+_Lb+'&email='+encodeURIComponent(_Ld);window.open(url,'api_import',_L12);_L6(_Lb,_Lc);}JX.Stratcom.listen('click','ci-api-auth',function(e){e.prevent();var _Lc=e.getData()['ci-api-auth']['api_instance'];var _Ld=e.getNodes()['ci-form'];_La(_Lc,_Ld);});JX.Stratcom.listen('keydown','ci-login',function(e){var _Lc=e.getNodes()['ci-form'];_L7(_Lc);});JX.Stratcom.listen('blur','ci-login',function(e){var _Lc=e.getNodes()['ci-form'];_L9(_Lc);});JX.Stratcom.listen('submit','ci-form',function(e){var _Lc=e.getNodes()['ci-form'];var _Ld=_Lc.email.value;var _Le=_Ld.split('@')[1];var _Lf=_L0[_Le];if(_Lf&&!_Lc.auth_token.value){e.prevent();_La(_Lf,_Lc);}});});
JX.behavior('event-create',function(){var _L0={};function _L1(_L2,_L3,_L4){var _L5=_L2['start_'+_L3].value;if(_L4)_L5=(parseInt(_L5)+_L4)+"";if(typeof(_L0[_L3])=='undefined'){_L0[_L3]=_L5;JX.enableDispatch(_L2['start_'+_L3],'change');JX.DOM.listen(_L2['start_'+_L3],'change',null,JX.bind(this,_L1,_L2,_L3,_L4));return;}var end=_L2['end_'+_L3].value;if(_L0[_L3]!=_L5&&_L0[_L3]==end){_L2['end_'+_L3].value=_L5;_L0[_L3]=_L5;}}JX.Stratcom.listen(['click','keypress','focus'],'event-start',function(e){var _L3=e.getNodes()['event-edit'];JX.defer(function(){_L1(_L3,'month');_L1(_L3,'day');_L1(_L3,'year');_L1(_L3,'time',60);});});});
(function(){JX.Stratcom.listen(['focus','blur'],[['ufi_container','tag:textarea'],['fancy-text-area','tag:textarea']],function(e){var _L1=e.getTarget();if(e.getType()=='focus'){_L1.style.height='6em';}else if(!_L1.value.match(/\S/))_L1.style.height='';});})();
JX.behavior('feed-update',function(){JX.Stratcom.listen('pipeline-feed',null,function(e){var _L1=e.getData();JX.Pipeline.addRequest('pipeline-feed',{newest:_L1.newest});JX.DOM.prependContent(JX.$('home_stream'),JX.HTML(_L1.content));});});
JX.behavior('friend-requests',function(_L0){JX.Stratcom.listen('click',['friend-requests','confirm-ignore-request'],function(e){e.prevent();var li=e.getNodes()['friend-requests'];li.parentNode.removeChild(li);var _L3=e.getNodes()['confirm-ignore-request'];JX.Workflow.newFromLink(_L3).start();});});
JX.install('Typeahead',{construct:function(_L0,_L1){if(_L1){this._hardpoint=_L1.hardpoint;this._control=_L1.control;}else{var _L2=JX.$(_L0.root);this._hardpoint=JX.DOM.find(_L2,'div','typeahead-hardpoint');this._control=JX.DOM.find(_L2,'input');}this._root=JX.$N('div',{className:'LTypeaheadResults'});JX.DOM.listen(this._control,['focus','blur','keypress','keydown'],null,JX.bind(this,this.handleEvent));JX.DOM.listen(this._root,['mouseover','mouseout'],null,JX.bind(this,this._onmouse));JX.DOM.listen(this._root,'mousedown','tag:a',JX.bind(this,function(e){this._choose(e.getTarget());e.prevent();}));var r=new JX.Request(_L0.src,JX.bind(this,this._onfill));r.setMethod('GET');r.send();},events:['reveal','choose','query'],properties:{allowNullSelection:true,ignoreBlur:false},members:{_root:null,_control:null,_hardpoint:null,_value:null,_ready:false,_stop:false,_focus:-1,_lookup:null,_raw:null,_display:[],show:function(){if(!this.invoke('reveal',this._root).getPrevented()){var d=JX.$V.getDim(this._hardpoint);d.x=0;d.setPos(this._root);this._hardpoint.appendChild(this._root);}},hide:function(){this._changeFocus(Number.NEGATIVE_INFINITY);this._display=[];JX.DOM.setContent(this._root,'');JX.DOM.remove(this._root);},_onmouse:function(_L0){this._moused=(_L0.getType()=='mouseover');this._drawFocus();},_changeFocus:function(d){var n=Math.min(Math.max(-1,this._focus+d),this._display.length-1);if(!this.getAllowNullSelection())n=Math.max(0,n);if(this._focus>=0&&this._focus<this._display.length)JX.DOM.alterClass(this._display[this._focus],'focused',0);this._focus=n;this._drawFocus();return true;},_drawFocus:function(){var f=this._display[this._focus];if(f)JX.DOM.alterClass(f,'focused',!this._moused);},_choose:function(_L0){var _L1=this.invoke('choose',_L0);if(_L1.getPrevented())return;this._stop=true;this._control.value=_L0.name;this._control.disabled=true;this._control.blur();this.hide();},clear:function(){this._control.value='';this.hide();},submit:function(){if(this._focus>=0&&this._display[this._focus]){this._choose(this._display[this._focus]);return true;}else{result=this.invoke('query',this._control.value);if(result.getPrevented())return true;}return false;},update:function(_L0){var k=_L0&&_L0.getSpecialKey();if(k&&_L0.getType()=='keydown')switch(k){case 'up':if(this._display.length&&this._changeFocus(-1))_L0.prevent();break;case 'down':if(this._display.length&&this._changeFocus(1))_L0.prevent();break;case 'return':if(this.submit())_L0.prevent();break;case 'esc':if(this._display.length&&this.getAllowNullSelection()){this.hide();_L0.prevent();}break;}setTimeout(JX.bind(this,this.redraw),0);},redraw:function(){if(!this._ready||this._stop)return;var v=JX.Typeahead.normalize(this._control.value);if(this._value==v)return;this._value=v;var _L1={};var _L2={};var _L3={};var _L4={};var t=JX.Typeahead.tokenize(this._value);t.sort(function(u,v){return v.length-u.length;});for(var ii=0;ii<t.length;++ii){if(t[ii] in _L4){t.splice(ii--,1);continue;}_L4[t[ii]]=true;var _L7=new RegExp('^'+t[ii]);for(var _L8 in this._lookup)if(_L8.match(_L7)){if(!(_L8 in _L3)){_L3[_L8]=true;}else continue;var l=this._lookup[_L8];for(var jj=0;jj<l.length;++jj){var _Lb=l[jj];if(!_L2[_Lb])_L2[_Lb]={};if(!(_L7 in _L2[_Lb])){_L2[_Lb][_L7]=true;_L1[_Lb]=(_L1[_Lb]||0)+1;}}}}var _Lc=[];for(var k in _L1)if(_L1[k]==t.length)_Lc.push(k);_Lc.sort(function(u,v){return u-v;});var n=Math.min(5,_Lc.length);var _Lf=[];for(var kk=0;kk<n;kk++){var data=this._raw[_Lc[kk]];_Lf.push(JX.$N('a',{href:data[1],name:data[0],rel:data[2]},data[0]));}this._display=_Lf;if(_Lf.length){JX.DOM.setContent(this._root,_Lf);this._changeFocus(Number.NEGATIVE_INFINITY);this.show();}else this.hide();},_onfill:function(r){this._raw=r;this._lookup={};for(var ii=0;ii<r.length;++ii){var t=JX.Typeahead.tokenize(r[ii][0]);for(var jj=0;jj<t.length;++jj){this._lookup[t[jj]]=this._lookup[t[jj]]||[];this._lookup[t[jj]].push(ii);}}this._ready=true;this.update();},handleEvent:function(e){if(this._stop||e.getPrevented())return;var _L1=e.getType();if(_L1=='blur'){if(!this.getIgnoreBlur())this.hide();}else this.update(e);}},statics:{_charmap:{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},_map:{},normalize:function(str){str=(''+str).toLowerCase();for(var k in JX.Typeahead._charmap)str=str.replace(JX.Typeahead._charmap[k],k);return str.replace(/[^a-z ]/g,'').replace(/ +/g,' ');},tokenize:function(str){var str=JX.Typeahead.normalize(str).replace(/^\s*|\s*$/g,'');if(!str.length)return [];return str.split(/ +/g);}}});
JX.install('Tokenizer',{construct:function(_L0){var _L1=JX.$(_L0.root);this._orig=JX.DOM.find(_L1,'input','tokenizer');this._tokens=[];this._tokenMap={};this._next=_L0.next&&JX.$(_L0.next);var _L2=JX.$N('input',{className:'LTokenizerInput',type:'text',value:this._orig.value});this._focus=_L2;JX.DOM.listen(_L2,['click','focus','blur','keydown'],null,JX.bind(this,this.handleEvent));JX.DOM.listen(_L1,['click'],null,JX.bind(this,function(e){if(e.getNodes().remove){this._remove(e.getData().token);}else if(e.getTarget()==_L1)this.focus();}));var _L1=JX.$N('div');_L1.id=this._orig.id;JX.DOM.alterClass(_L1,'LTokenizer',true);this._root=_L1;_L1.appendChild(_L2);this._typeahead=new JX.Typeahead(_L0,{hardpoint:this._root,control:this._focus});this._typeahead.setAllowNullSelection(false);this._typeahead.listen('choose',JX.bind(this,function(_L3){JX.Stratcom.context().prevent();if(this.addToken(_L3.rel,_L3.name)){this._typeahead.hide();this._focus.value='';this._redraw();this.focus();}}));this._typeahead.listen('query',JX.bind(this,function(_L3){var _L4=_L3.split(/[,; ]/);var _L5=false;for(var ii=0;ii<_L4.length;++ii){_L4[ii]=_L4[ii].replace(/^\s+|\s+$/g,'');if(_L4[ii].match(/.*@.*\.[a-z]+$/))_L5=_L5||this.addToken(_L4[ii],_L4[ii]);}if(_L5){this._focus.value='';this._redraw();this.focus();JX.Stratcom.context().prevent();}}));JX.defer(JX.bind(this,function(){JX.DOM.setContent(this._orig.parentNode,_L1);var map=_L0.value||{};for(var k in map)this.addToken(k,map[k]);this._redraw();}));},members:{_root:null,_focus:null,_orig:null,_typeahead:null,_tokenid:0,_tokens:null,_tokenMap:null,_seq:0,_next:null,handleEvent:function(e){this._typeahead.handleEvent(e);if(e.getPrevented())return;if(e.getType()=='click'){if(e.getTarget()==this._root){this.focus();e.prevent();return;}}else if(e.getType()=='keydown'){this._onkeydown(e);}else if(e.getType()=='blur')this._redraw();},_redraw:function(){var _L0=this._focus;var _L1=this._root;var _L2=JX.DOM.textMetrics(this._focus,'LTokenizerMetrics');_L2.y=null;_L2.x+=24;_L2.setDim(_L0);_L0.value=_L0.value;var h=JX.$V(_L0).add(JX.$V.getDim(_L0)).y-JX.$V(_L1).y;_L1.style.height=h+'px';},addToken:function(key,_L1){if(key in this._tokenMap)return false;var _L2=this._focus;var _L3=this._root;var _L4=JX.$N('a',{className:'LTokenizerToken'},_L1);var _L5=JX.$N('input',{type:'hidden',value:key,name:this._orig.name+'['+(this._seq++)+']'});var _L6=JX.$N('a',{className:'LTokenizerX'},JX.HTML('&times;'));this._tokenMap[key]={value:_L1,key:key,node:_L4};this._tokens.push(key);JX.Stratcom.sigilize(_L4,'token',key);JX.Stratcom.sigilize(_L6,'remove');_L4.appendChild(_L5);_L4.appendChild(_L6);_L3.insertBefore(_L4,_L2);return true;},_onkeydown:function(e){var _L1=this._focus;var _L2=this._root;switch(e.getSpecialKey()){case 'return':e.prevent();break;case 'tab':var _L3=this._typeahead.submit();if(this._next){if(!_L3)this._focus.value='';JX.defer(JX.bind(this,function(){this._next.focus();}));}break;case 'delete':if(!this._focus.value.length){var tok;while(tok=this._tokens.pop())if(this._remove(tok))break;}break;default:JX.defer(JX.bind(this,this._redraw));break;}},_remove:function(_L0){if(!this._tokenMap[_L0])return false;JX.DOM.remove(this._tokenMap[_L0].node);delete this._tokenMap[_L0];this._redraw();this.focus();return true;},focus:function(){var _L0=this._focus;JX.DOM.show(_L0);JX.defer(function(){JX.DOM.focus(_L0);});}}});
JX.behavior('inbox-compose',function(_L0){var _L1=new JX.Tokenizer(_L0);if(_L0.value){JX.$(_L0.next).focus();}else _L1.focus();});
JX.behavior('inbox-reply',function(){JX.Stratcom.listen('submit','inbox-reply',function(e){e.prevent();var _L1=e.getTarget();var _L2=JX.DOM.find(_L1,'textarea');var _L3=e.getNodes();var _L4=_L3['stream-container'];var _L5=_L3['reply-form-container'];JX.Workflow.newFromForm(_L1).setHandler(function(r){_L4.removeChild(_L5);JX.DOM.appendContent(_L4,JX.HTML(r));_L4.appendChild(_L5);_L2.value='';JX.defer(function(){_L2.focus();});}).start();});});
JX.behavior('inbox-search',function(_L0){var _L1=new JX.Typeahead(_L0);_L1.listen('choose',function(_L2){JX.go(_L0.action+'?'+_L0.param+'='+_L2.rel);});});
JX.behavior('mobile-subscribers',function(_L0){var _L1=new JX.Typeahead(_L0);var _L2=JX.DOM.find(document,'table','subscribers');var _L3=0;_L1.listen('choose',function(_L5){JX.Stratcom.context().prevent();_L1.clear();try{var row=JX.$('remove-'+_L5.rel);try{var _L7=JX.DOM.find(row,'input');JX.DOM.remove(_L7);JX.DOM.show(row);}catch(e){}return;}catch(e){}try{JX.$('cancel-'+_L5.rel);return;}catch(e){}var _L7=JX.$N('input',{type:'hidden',value:_L5.rel,name:'add['+(_L3++)+']'});var tr=JX.$N('tr',{id:'cancel-'+_L5.rel});var th=JX.$N('th');var _La=JX.$N('a',{href:_L5.href});JX.DOM.appendContent(_La,_L5.name);JX.DOM.appendContent(th,_La);var td=JX.$N('td');var _Lc=JX.$N('a',{href:'#',className:'remove'});JX.Stratcom.sigilize(_Lc,'cancel-add',_L5.rel);JX.DOM.appendContent(_Lc,JX.HTML('&times;'));JX.DOM.appendContent(td,[_Lc,_L7]);JX.DOM.appendContent(tr,[th,td]);_L2.appendChild(tr);});var _L4=0;JX.Stratcom.listen('click','remove-subscriber',function(e){e.prevent();var _L6=e.getData()['remove-subscriber'];var row=JX.$('remove-'+_L6);var _L8=JX.$N('input',{type:'hidden',value:_L6,name:'rem['+(_L4++)+']'});JX.DOM.appendContent(row,_L8);JX.DOM.hide(row);});JX.Stratcom.listen('click','cancel-add',function(e){e.prevent();var _L6=e.getData()['cancel-add'];var row=JX.$('cancel-'+_L6);JX.DOM.remove(row);});});
JX.behavior('photo-legacy-upload',function(uri){document.domain='facebook.com';JX.Stratcom.listen('photo-legacy-upload-complete',null,function(_L1){JX.go(uri);});});
JX.behavior('publisher-write',function(){function _L0(e){var _L2=e.getNodes().publisher;if(!_L2)return;var _L3=JX.DOM.find(_L2,'div','write-view');var _L4=JX.DOM.find(_L2,'div','button-view');JX.DOM.hide(_L3);JX.DOM.show(_L4);}JX.Stratcom.listen('click','write-button',function(e){e.prevent();var _L2=e.getNodes().publisher;var _L3=JX.DOM.find(_L2,'div','write-view');var _L4=JX.DOM.find(_L2,'div','button-view');JX.DOM.show(_L3);JX.DOM.hide(_L4);JX.DOM.focus(JX.DOM.find(_L3,'textarea'));});JX.Stratcom.listen('submit','write-form',function(e){e.prevent();var _L2=e.getTarget();var _L3=JX.DOM.find(_L2,'textarea');if(!_L3.value.match(/\S/))return;new JX.Workflow.newFromForm(_L2).setHandler(function(r){JX.DOM.prependContent(JX.$('yonder_stream'),JX.HTML(r));_L3.value='';_L0(e);}).start();});JX.Stratcom.listen('blur','write-view',function(e){if(!JX.DOM.isType(e.getTarget(),'textarea'))return;if(!e.getTarget().value.match(/\S/))_L0(e);});});
JX.behavior('real-time-alerts',function(){JX.Stratcom.listen('pipeline-real-time-alerts',null,function(_L0){var _L1=JX.$('alertsContent');JX.DOM.setContent(_L1,JX.HTML(_L0.getData().content));JX.DOM.show(_L1.parentNode);});JX.Stratcom.listen('click',['alerts-close'],function(e){e.prevent();var _L1=JX.$('alertsContent');JX.DOM.hide(_L1.parentNode);new JX.Workflow('/rtalerts/close/').setHandler(function(){}).start();});});
JX.behavior('pymk-reject',function(){JX.Stratcom.listen('click',['pymk','reject'],function(e){e.prevent();var n=e.getNodes();var d=e.getData();delete d.pymk[d.reject];var _L3={visible:JX.keys(d.pymk).join(',')};new JX.Workflow(e.getTarget().href,_L3).setHandler(function(r){if(!JX.keys(r).length){JX.DOM.remove(n.suggestion);if(!JX.keys(d.pymk).length)JX.DOM.remove(n.pymk);}else for(var k in r){JX.DOM.replace(n.suggestion,JX.HTML(r[k]));d.pymk[k]=true;break;}JX.DOM.alterClass(n.pymkList.lastChild,'last',true);}).start();});});
JX.behavior('search-typeahead',function(_L0){var _L1=new JX.Typeahead(_L0);_L1.listen('choose',function(_L2){JX.go(_L2.href);});});
JX.behavior('settings-profile',function(_L0){JX.Stratcom.listen('click','profile_privacy',function(e){if(e.getTarget().value=='public'){JX.DOM.show(JX.$(_L0.contactID));}else JX.DOM.hide(JX.$(_L0.contactID));});JX.Stratcom.listen('click','custom_privacy',function(e){JX.$(e.getData().custom_privacy.radioID).checked='checked';JX.DOM.hide(JX.$(_L0.contactID));});});
JX.behavior('stream-story-delete',function(){JX.Stratcom.listen('click','story_remove',function(e){e.prevent();var _L1=e.getTarget();new JX.Workflow(e.getTarget().href).setHandler(function(){JX.DOM.remove(_L1.parentNode);}).start();});});
JX.install('Tagger',{construct:function(e){var _L1=e.getNodes().phideoroot;this._button=JX.DOM.find(_L1,'button','tag-action');this._control=JX.DOM.find(_L1,'div','tag-control');this._list=JX.DOM.find(_L1,'div','tag-list');this._input=JX.DOM.find(_L1,'input','tag-input');JX.Stratcom.listen('keydown',null,JX.bind(this,function(e){if(e.getSpecialKey()=='esc'&&this._enabled){this._setEnabled(false);e.kill();}}));var _L2=new JX.Typeahead(e.getData()['tag-action']);this._typeahead=_L2;_L2.setAllowNullSelection(false);_L2.setIgnoreBlur(true);_L2.listen('choose',JX.bind(this,function(_L4){JX.Stratcom.context().prevent();this._addTag(_L4.rel,null);this._clear();}));_L2.listen('query',JX.bind(this,function(_L4){JX.Stratcom.context().prevent();if(this._allowText){this._addTag(null,_L4);this._clear();}}));this._confirm=JX.DOM.find(_L1,'button','tag-confirm');JX.DOM.listen(this._confirm,'click',null,function(e){_L2.submit();e.prevent();});var _L3=e.getData().phideoroot;this._endpoint=_L3.uri;this._allowText=_L3.text;this._data={};},events:['enable','disable','clear','didRedraw','didHitCanvas'],members:{_enabled:false,_button:null,_control:null,_list:null,_done:null,_canvas:null,_endpoint:null,_data:null,setCanvas:function(c){this._canvas=c;JX.DOM.listen(this._canvas,['mousedown','click'],null,JX.bind(this,function(e){if(this._enabled){this.invoke('didHitCanvas',e,this._canvas);e.prevent();}}));return this;},addData:function(m){JX.copy(this._data,m);return this;},handleEvent:function(e){this._typeahead.handleEvent(e);if(e.getPrevented())return;var _L1=e.getNodes();var _L2=e.getData();var _L3=e.getType();if(_L1['tag-action'])if(_L3=='click'){this._setEnabled(!this._enabled);e.prevent();}},_setEnabled:function(_L0){if(this._enabled==_L0)return;this._enabled=_L0;JX.DOM.alterClass(this._button,'grey_active',_L0);if(this._enabled){JX.DOM.show(this._control);this.invoke('enable');JX.defer(JX.bind(this,function(){JX.DOM.focus(this._input);}));}else{this._input.blur();this._clear();this.invoke('disable');JX.DOM.hide(this._control);}},_clear:function(){this._input.value='';this._typeahead.redraw();this.invoke('clear');},_addTag:function(id,_L1){var _L2=JX.copy(this._data,{subject:id,name:_L1});new JX.Workflow(this._endpoint,_L2).setHandler(JX.bind(this,function(r){JX.DOM.setContent(this._list,JX.HTML(r));this.invoke('didRedraw');this._data={};})).start();}}});
JX.behavior('tag-photos',function(){JX.Stratcom.listen('click','tag-action',function(e){var _L1=e.getNodes().phideoroot;JX.DOM.bindController(_L1,'Tagger',function(){var _L2=new JX.Tagger(e);var _L3=JX.DOM.find(_L1,'div','tag-control');var _L4=JX.DOM.find(_L1,'div','tag-explain');var _L5=JX.DOM.find(_L1,'img','tag-canvas');document.body.appendChild(JX.DOM.remove(_L3));_L2.setCanvas(_L5);_L2.listen('enable',function(){JX.DOM.hide(JX.DOM.find(_L1,'div','tag-overlay'));JX.DOM.hide(_L3);JX.DOM.show(_L4);JX.DOM.alterClass(_L5,'tag-canvas',true);});_L2.listen('disable',function(){JX.DOM.hide(JX.DOM.find(_L1,'div','tag-overlay'));JX.DOM.hide(_L4);JX.DOM.alterClass(_L5,'tag-canvas',false);});_L2.listen('clear',function(){JX.DOM.hide(_L3);});_L2.listen('didRedraw',function(){JX.DOM.hide(JX.DOM.find(_L1,'div','tag-overlay'));});_L2.listen('didHitCanvas',function(e,_L5){var p=JX.$V(e);var q=p;q.x-=110;q.y+=20;q.setPos(_L3);var i=JX.$V(_L5);p.x-=i.x;p.y-=i.y;var d=JX.$V.getDim(_L5);_L2.addData({x:100*(p.x/d.x),y:100*(p.y/d.y)});JX.DOM.show(_L3);JX.defer(function(){JX.DOM.focus(JX.DOM.find(_L3,'input','tag-input'));});});return _L2;}).handleEvent(e);});});
JX.behavior('tag-video',function(){JX.Stratcom.listen('click','tag-action',function(e){JX.DOM.bindController(e.getNodes().phideoroot,'Tagger',function(){return new JX.Tagger(e);}).handleEvent(e);});});
JX.behavior('theme-collage',function(_L0){var n=_L0.length;var v=[];for(var ii=0;ii<_L0.length;ii++){img=new Image();img.onload=function(){--n;if(!n)_L4();};img.src=_L0[ii];v.push(img);}function _L4(){var p=JX.$V.getViewport();var c=0;var x=0;var y=0;var min=Number.POSITIVE_INFINITY;for(var ii=0;ii<v.length;ii++)if(!v[ii].height){v=v.splice(ii--,1);continue;}else min=Math.min(min,v[ii].height);while(x<p.x||y<p.y){var div=JX.$N('div');div.style.background='url('+v[c].src+')';div.style.width=v[c].width+'px';div.style.height=v[c].height+'px';div.style.position='fixed';div.style.left=x+'px';div.style.top=y+'px';document.body.insertBefore(div,document.body.firstChild);y+=v[c].height;if(y>p.y&&x<p.x){y=0;x+=v[c].width;v.sort(function(){return .5-Math.random();});}c=(c+1)%v.length;}var _Lb=JX.$N('div');p.setDim(_Lb);_Lb.style.position='fixed';_Lb.style.background='#ffffff';_Lb.style.top='0px';_Lb.style.opacity='0.75';document.body.appendChild(_Lb);}});
JX.behavior('ufi-read-more',function(){JX.Stratcom.listen('click','read_more_snipped',function(e){e.prevent();var _L1=e.getNodes().read_more_snipped;JX.DOM.show(_L1.nextSibling);JX.DOM.hide(_L1);});});
JX.behavior('ufi',function(){function _L0(_L5){var _L6=_L5.getNodes();var _L7=_L5.getData().ufi_container;var _L8=_L7.args;var _L9;var _La=null;if(_L6.comment_form){_L9='add_comment';_La=_L5.getTarget();}else if(_L6.like){_L9='like';}else if(_L6.unlike){_L9='unlike';}else if(_L6.del_comment){_L9='del_comment';_L8.comment_id=_L5.getData().del_comment.comment_id;}else if(_L6.comment_link){_L3(_L7,_L6);JX.DOM.focus(JX.$(_L7.textarea));_L5.prevent();return;}else if(_L6.more_comments){_L9='more_comments';}else if(_L6.all_likes){_L9='all_likes';}else return;var uri='/'+_L9+'/';if(!(_L9 in {more_comments:1,all_likes:1}))uri='/w/'+_L7.token+uri;if(_L9 in {like:1,unlike:1})_L2(_L9,_L6,_L7);var _Lc;if(_La){_La.action=uri;_Lc=JX.Workflow.newFromForm(_La,_L8);}else _Lc=new JX.Workflow(uri,_L8);_Lc.setHandler(JX.bind(null,_L1,_L9,_L6)).start();_L5.prevent();}function _L1(_L5,_L6,r){var ufi=_L6.ufi_container;var _L9=JX.DOM.find(ufi,'div','all_comments');if(_L5 in {add_comment:1,more_comments:1}){if(r.last_comment){JX.DOM.appendContent(_L9,JX.HTML(r.last_comment));}else if(r.all_comments)JX.DOM.setContent(_L9,JX.HTML(r.all_comments));var _La=JX.DOM.find(ufi,'textarea');_La.value='';_La.style.height='';}else if(_L5=='del_comment')JX.DOM.remove(_L6.del_comment.parentNode);}function _L2(_L5,_L6,_L7){var ufi=_L6.ufi_container;var _L9=JX.DOM.find(ufi,'div','does_like');var _La=JX.DOM.find(ufi,'div','does_not_like');var _Lb=JX.DOM.find(ufi,'a','like');var _Lc=JX.DOM.find(ufi,'a','unlike');var _Ld=JX.DOM.find(ufi,'div','feedbackview');if(_L5=='like'){JX.DOM.show(_L9,_Lc);JX.DOM.hide(_La,_Lb);_L3(_L7,_L6);}else{JX.DOM.hide(_L9,_Lc);JX.DOM.show(_Lb);if(_L7.other_likes_exist)JX.DOM.show(_La);}var _Le=(_L5=='unlike'&&!_L7.other_likes_exist&&_L7.comment_count==0);JX.DOM.alterClass(_Ld,'hide',_Le);}function _L3(_L5,_L6){if(_L4(_L5))return;var _L7='<table><tr>'+'<th><div>'+'<textarea name="comment" id="'+_L5.textarea+'"></textarea>'+'</div></th>'+'<td><button class="small" type="submit">Comment</button></td>'+'</tr></table>';var _L8=JX.$N('form',{method:'post'},JX.HTML(_L7));JX.Stratcom.sigilize(_L8,'comment_form',{});JX.DOM.alterClass(_L8,'comment',true);var _L9=JX.DOM.find(_L6.ufi_container,'div','feedbackview');_L9.appendChild(_L8);JX.DOM.alterClass(_L9,'hide',false);JX.DOM.alterClass(_L9,'noFeedback',true);}function _L4(_L5){try{t=JX.$(_L5.textarea);}catch(e){if(e==JX.$.NotFound){return false;}else throw e;}return true;}JX.Stratcom.listen('click',['ufi_container','tag:a'],_L0);JX.Stratcom.listen(['submit'],['ufi_container','comment_form','tag:form'],_L0);});
JX.install('Heavy',{statics:{load:function(_L0,_L1,_L2,bar){this._queue.push(JX.$A(arguments));if(this._initialized)this._run();},configure:function(t,_L1){this._init();this._rsrcx_uri=_L1;window.Env.post_form_id=t;this._run();},_queue:[],_initialized:false,_rsrcx_uri:null,_have:{},_init:function(){if(this._initialized)return;this._initialized=true;window.Env=window.Env||{};window.loaded=true;},_bootload:function(_L0,_L1,_L2){_L2&&_L2.update();if(!_L0.length){setTimeout(function(){_L2&&_L2.end();_L1[0]();},200);return;}var c=_L0.shift();window.Bootloader.loadComponents([c],JX.bind(JX.Heavy,JX.Heavy._bootload,_L0,_L1,_L2));},_run:function(){for(var ii=0;ii<this._queue.length;ii++)this._execute.apply(this,this._queue[ii]);this._queue=[];},_execute:function(_L0,_L1,_L2,bar){_L0=['bootloader','core'].concat(_L0);var b=bar&&bar[0]&&JX.$(bar[0]);b&&JX.DOM.hide(b);var _L5=[function(){b&&JX.DOM.show(b);setTimeout(_L1,0);}];if(bar)var _L6=new JX.Progressbar(JX.$(bar[1]),JX.$(bar[2]),_L0.length+1,function(){JX.DOM.show(b);_L5[0]=JX.bag;_L2();});var _L7=[];for(var ii=0;ii<_L0.length;++ii)if(!(_L0[ii] in this._have)){_L7.push(_L0[ii]);this._have[_L0[ii]]=true;}if(_L7.length){var _L9='enable='+_L7.join(',');if(!window.Bootloader){_L9+='&boot';}else ;JX.Boot.loadRawResource('js',this._rsrcx_uri+'?'+_L9);}var _La=setInterval(function(){if(!window.Bootloader)return;clearInterval(_La);JX.Heavy._bootload(_L0,_L5,_L6);},50);}}});
(function(){var _L0=false;var _L1=false;var _L2=false;var _L3=null;JX.Stratcom.listen('click','upload-photos',function(e){e.prevent();if(_L1){if(!_L2)_L3.startUploader();return;}if(_L0)return;_L0=true;window.Env=window.Env||{};window.Env['pc']=e.getData()['upload-photos'].config;window.env_get=function(k){return window.Env[k];};JX.Heavy.load(['dialog','photo-uploader-remote-js','fbplugin','uploader-progress','lite-uploader-progress'],function(){(_L3=_L3||new UploaderRemote());_L3.setInitHandler(function(){window.Uploader.addDialogCloseListener(function(_L5){if(_L5){new JX.Workflow('/d/createalbum/').setHandler(function(r){LiteUploaderProgress.setAlbumURI(r.albumURI);window.Uploader.setAlbumID(r.albumLegacyID).setLite(true).startUpload();}).start();}else ;_L2=false;});}).setHandler(function(){_L2=true;});_L1=true;_L3.startUploader();},function(){_L0=false;},e.getData()['upload-photos'].bar);});})();
JX.behavior('video-upload',function(_L0){document.domain='facebook.com';JX.Stratcom.listen('video-select',null,function(_L1){var _L2=_L1.getData();var sub=_L2.window;var _L4=_L2.input;var _L5=new JX.Progressbar(JX.$(_L0.rootID),JX.$(_L0.barID));var _L6=JX.$(_L0.frameID);_L6.style.position='absolute';_L6.style.left='-10000px';new JX.Workflow(_L0.createURI).setHandler(function(r){var _L8=JX.$N('iframe',{src:r.progressURI,style:{position:'absolute',left:'-10000px'}});var _L9={update_progress:function(_La,_Lb,_Lc,_Ld){_L5.set(parseInt(_La)/parseInt(_Lb));},too_big:function(){JX.log('too big omg ;o');}};window.VideoUploadProgress={getInstance:function(){return _L9;}};window.Arbiter={inform:JX.bind(JX.Stratcom,JX.Stratcom.invoke)};JX.Stratcom.listen('video_upload_done',null,function(e){_L5.set(1);JX.DOM.remove(_L8);JX.DOM.remove(_L6);var _Lb=JX.$N('form');_Lb.action=r.completeURI;_Lb.method='POST';document.body.appendChild(_Lb);_Lb.submit();});document.body.appendChild(_L8);sub.didCreateVideo(_L4,r.uploadURI);}).start();});});
JX.behavior('workflow',function(){JX.Stratcom.listen('submit',['workflow','tag:form'],function(e){if(JX.Stratcom.pass())return;if(e.getNodes().workflow!==e.getTarget())return;e.prevent();JX.Workflow.newFromForm(e.getTarget()).start();});JX.Stratcom.listen('click',['workflow','tag:a'],function(e){if(JX.Stratcom.pass())return;if(e.getNodes().workflow!==e.getTarget())return;e.prevent();JX.Workflow.newFromLink(e.getTarget()).start();});});
window.Env=window.Env||{};window.onbeforeunload=JX.bag;
JX.install('Channel',{construct:function(_L0,_L1){document.domain='facebook.com';this._csrf=_L0.csrf;this._channels=_L1;this._notify=JX.$(_L0.notify);this._viewer=_L0.viewer;this._recv={};if(_L0.playerURI){var div=JX.$N('div');var id=JX.DOM.uniqID(JX.$N('div'));document.body.appendChild(div);this._sound=document[id]||window[id];this._soundURI=_L0.soundURI;setTimeout(function(){var _L4=new JX.Flash(_L0.playerURI,JX.DOM.uniqID(div),id);_L4.render();},1500);}JX.Stratcom.listen('channel-iframe',null,JX.bind(this,this._onload));JX.Stratcom.listen('channel-raw',null,JX.bind(this,this._rawMessage));JX.Stratcom.listen('channel-popout',null,JX.bind(this,this._popout));},members:{_channels:null,_frame:null,_csrf:null,_notify:null,_viewer:null,_recv:null,_sound:null,_soundURI:null,_onload:function(e){e.kill();this._frame=e.getTarget();this._poll();},_popout:function(e){JX.DOM.alterClass(this._notify,'online',true);JX.DOM.alterClass(this._notify,'alert',false);},_poll:function(){JX.defer(JX.bind(this,function(){var uri=this._buildChannelURI();this._execChannel(function(){new this.JX.Request(uri,this.JX.bind(this,function(r){this.top.JX.Stratcom.invoke('channel-raw',null,r);})).setRaw(true).send();});}),2500);},_buildChannelURI:function(){var _L0=[];for(var k in this._channels)_L0.push(k+'='+this._channels[k]);_L0=_L0.join('&');var _L2=this.getActivity()?'true':'false';this.setActivity(false);return '/x/'+Math.random()+'/'+_L2+'/'+_L0;},_rawMessage:function(e){var _L1=e.getData();switch(_L1.t){case 'refresh':new JX.Request('/ajax/presence/reconnect.php',JX.bind(this,this._onreconnect)).setData({post_form_id:this._csrf}).send();break;case 'msg':for(var ii=0;ii<_L1.ms.length;ii++){var msg=_L1.ms[ii];this._channels[_L1.c]++;switch(msg.type){case 'msg':if(msg.from===this._viewer){JX.DOM.alterClass(this._notify,'alert',false);}else{JX.DOM.alterClass(this._notify,'alert',true);if(this._sound)this._sound.playSound(this._soundURI,true);}break;}}this._poll();break;case 'continue':this._poll();break;}},_onreconnect:function(r){this._channels[r.user_channel]=r.seq;this._poll();},_execChannel:function(fn){return this._frame.contentWindow.JX.occur(fn);}},properties:{activity:true}});

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