/*    HTTP Host:  b.static.ak.fbcdn.net                                        */
/*    Generated:  January 22nd 2010 11:06:13 AM PST                            */
/*      Machine:  10.16.140.108                                                */
/*       Source:  Backing Store                                                */
/*     Location:  js/5ude22fr2ko40o4w.pkg.js h:bmxclvzs                        */
/*       Locale:  nu_ll                                                        */
/*         Path:  js/5ude22fr2ko40o4w.pkg.js                                   */

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

function PageCacheFeedTracking(){this.data=[];}PageCacheFeedTracking.instance=null;PageCacheFeedTracking.getInstance=function(){if(!PageCacheFeedTracking.instance)PageCacheFeedTracking.instance=new PageCacheFeedTracking();return PageCacheFeedTracking.instance;};copy_properties(PageCacheFeedTracking.prototype,{register:function(_L0){var _L1={'meta':_L0};this.data.push(_L1);},dispatch:function(){var _L0=new AsyncRequest().setMethod('POST').setURI('/ajax/feed_tracking_pagecache.php').setReadOnly(true).setOption('bundle',true).setData({'data':this.data}).send();return true;}});
function InstrumentedLogger(_L0){if(this===window)return new InstrumentedLogger(_L0);if(InstrumentedLogger._instances[_L0])return InstrumentedLogger._instances[_L0];copy_properties(this,{id:_L0,_phases:{}});return InstrumentedLogger._instances[_L0]=this;}copy_properties(InstrumentedLogger,{_instances:{}});copy_properties(InstrumentedLogger.prototype,{beginPhase:function(_L0){if(this._phases[_L0]&&this._phases[_L0].start)this.endPhase(_L0);if(typeof(this._phases[_L0])=='undefined')this._phases[_L0]={start:0,count:0,duration:0};this._phases[_L0].start=new Date().getTime();return this;},endPhase:function(_L0){var _L1=this._phases[_L0];if(_L1&&_L1.start){_L1.count++;_L1.duration+=new Date().getTime()-_L1.start;_L1.start=null;}return this;},dumpAndReset:function(){this.dump();return this.reset();},dump:function(){for(var _L0 in this._phases){var p=this._phases[_L0];var _L2=(this.id?this.id+'::':'')+_L0;Util.warn(' %s %f ms [%d ms / %d]',_L2,p.duration/p.count,p.duration,p.count);}return this;},get:function(_L0){if(this._phases[_L0])return this._phases[_L0].duration/this._phases[_L0].count;return 0;},reset:function(){this._phases={};return this;}});InstrumentedLogger.prototype.b=InstrumentedLogger.prototype.beginPhase;InstrumentedLogger.prototype.e=InstrumentedLogger.prototype.endPhase;InstrumentedLogger.prototype.d=InstrumentedLogger.prototype.dump;InstrumentedLogger.prototype.D=InstrumentedLogger.prototype.dumpAndReset;InstrumentedLogger.prototype.r=InstrumentedLogger.prototype.reset;var IL=InstrumentedLogger;
function Template(_L0){copy_properties(this,{_templateSource:_L0});}copy_properties(Template,{_operatorRepeat:function(s,_L1){var _L2='';var _L3=s.match(/([^:]*):(.*)/);if(!_L3){Util.warn('Invalid template call: %s',s);}else if(!TemplateRegistry.hasTemplate(_L3[2])){Util.warn('Template not available: %s',s);}else if(_L1[_L3[1]]){var _L4=TemplateRegistry.getTemplate(_L3[2]);var _L5=arrayize(_L1[_L3[1]]);_L2+=_L5.map(function(_L4,_L1){return _L4.render(_L1);}.curry(_L4)).join(' ');}return _L2;}});copy_properties(Template.prototype,{getSource:function(){return this._templateSource;},render:function(_L0){var _L1=function(_L2,_L3,_L4,key){switch(_L4){case 'H':return _L2[key]||'';case 'R':return Template._operatorRepeat(key,_L2);default:return _L2[key]?htmlize(_L2[key]):'';}return _L2[key]?translator(_L2[key]):'';}.curry(_L0||{});return this._templateSource.replace(/\$(H|R)?{([^\}]*)\}/g,_L1);}});var TemplateRegistry={_storage:{},registerTemplate:function(_L0,_L1){if(typeof(_L1)=="string")_L1=new Template(_L1);this._storage[_L0]=_L1;return this;},unregisterTemplate:function(_L0){delete this._storage[_L0];},hasTemplate:function(_L0){return _L0 in this._storage;},getTemplate:function(_L0){if(this.hasTemplate(_L0))return this._storage[_L0];return null;},registerServerSideTemplate:function(_L0,_L1,_L2,_L3){_L1=_L1||bagofholding;_L2=!!_L2;_L3=!!_L3;if(this.hasTemplate(_L0)){_L1();return this;}var _L4=new AsyncRequest(_L0).setReadOnly(true).setMethod('GET').setOption('asynchronous',!_L2).setOption('suppressEvaluation',!_L3);if(!_L2)_L4.setErrorHandler(this._registerErrorHandler.bind(this,_L0)).setHandler(this._registerHandler.bind(this,_L0,_L3,_L1));_L4.send();if(_L2){var _L5=this._stripHasteComments(_L4.transport.responseText);this.registerTemplate(_L0,new Template(_L5));_L1();}return this;},_registerErrorHandler:function(_L0,_L1){Util.warn('Failed to register template "%s"',_L0);},_registerHandler:function(_L0,_L1,_L2,_L3){var _L4=_L3.getPayload();var _L5=null;if(_L1){if(_L4.template)_L5=_L4.template;}else _L5=this._stripHasteComments(_L4.responseText);if(_L5){this.registerTemplate(_L0,_L5);_L2();}else Util.error('No template found in response payload');},_stripHasteComments:function(_L0){return _L0.replace(/^\s*\/\*\*?(.|\n)*\*\//m,'');},_onRegisterTemplate:function(_L0,_L1){if(_L0=='template/registerTemplate'){if(!_L1||!_L1.name||!_L1.template){Util.warn('TemplateRegister: Invalid template data.');}else this.registerTemplate(_L1.name,_L1.template);return false;}Util.warn('TemplateRegister: Invalid arbiter message type: %s',_L0);return true;}};Arbiter.subscribe('template/registerTemplate',TemplateRegistry._onRegisterTemplate.bind(TemplateRegistry),Arbiter.SUBSCRIBE_ALL);
function TemplateObject(_L0,_L1){_L1=_L1||{};if(!(_L0 instanceof Template))if(TemplateRegistry.hasTemplate(_L0)){_L0=TemplateRegistry.getTemplate(_L0);}else if(_L0 instanceof URI){TemplateRegistry.registerServerSideTemplate(_L0.toString(),null,true);_L0=TemplateRegistry.getTemplate(_L0);}if(_L0==null)throw new Error("Template could not be found");var _L2=_L0.render(_L1);copy_properties(this,{_nodes:HTML(_L2).getNodes(),_template:_L0,_rendered:_L2});TemplateObject.bindNodes(this._nodes,this);}copy_properties(TemplateObject,{bindNodes:function(_L0,_L1){var _L2=[];for(var i=0;i<_L0.length;i++)if(_L0[i].nodeType==DOM.NODE_TYPES.ELEMENT){_L2.push(_L0[i]);var _L4=_L0[i].getElementsByTagName('*');_L2=_L2.concat(to_array(_L4));}for(var i=0;i<_L2.length;i++){var _L5=_L2[i].getAttribute('bindPoint');var _L6=_L2[i].getAttribute('listen');if(_L5)if(hasArrayNature(_L1[_L5])){_L1[_L5].push(_L2[i]);}else _L1[_L5]=_L2[i];if(_L6)_L6.replace(/(\w+) *: *(\w+)/g,function(_L7,_L8,_L9,_La){if(typeof(this[_La])=="function"){Event.listen(_L7,_L9,bind(this,this[_La]));}else Event.listen(_L7,_L9,bind(this,TemplateObject._eventWrapper,_La));}.bind(_L1,_L2[i]));}},_eventWrapper:function(_L0,_L1){if(typeof(this[_L0])=="function"){return this[_L0](_L1);}else{Util.warn('Event wrapper [%s] not defined for template object',_L0);return true;}}});copy_properties(TemplateObject.prototype,{getNodes:function(){return this._nodes;},getRendered:function(){return this._rendered;}});
function NewsFeedEditor(_L0){this.modified=false;this.filterKey=_L0;NewsFeedEditor.instance=this;}NewsFeedEditor.prototype.setAutoUpdate=function(_L0,_L1,_L2){this.modified=true;var _L3;if(_L0.checked){_L3=_L1;}else _L3=_L2;new AsyncRequest().setURI('/ajax/feed/filter_action.php').setData({filter_key:this.filterKey,action:'auto_update',value:_L3}).send();};NewsFeedEditor.prototype.addToNewsFeed=function(_L0){this.modified=true;new AsyncRequest().setURI('/ajax/feed/filter_action.php').setData({filter_key:this.filterKey,action:_L0.action,value:_L0.id}).setHandler(function(_L1){ObjectBrowserController.getController(_L0.element).removeItem(_L0.id);}).send();};NewsFeedEditor.show=function(_L0,_L1){if(NewsFeedEditor.instance)return false;if(!_L1)_L1=bagofholding;var _L2=new AsyncRequest().setMethod('GET').setReadOnly(true).setURI('/ajax/feed/hidden_people_settings.php').setData({filter_key:_L0});new Dialog().setAsync(_L2).setCloseHandler(function(){if(NewsFeedEditor.instance){if(NewsFeedEditor.instance.modified)_L1();delete NewsFeedEditor.instance;}}).show();return false;};
var UIIntentionalStreamMessage={SET_AUTO_INSERT:'UIIntentionalStream/setAutoInsert'};
function Tabset(id,_L1){if(!Tabset.instances)Tabset.instances={};Tabset.instances[id]=this;onunloadRegister(function(){Tabset.instances={};});this.id=id;this.selectedId=_L1;}Tabset.getInstance=function(id){if(Tabset.instances&&Tabset.instances[id])return Tabset.instances[id];return null;};Tabset.prototype.getFullTabId=function(_L0){return this.id+'_'+_L0;};Tabset.prototype.selectTab=function(_L0,_L1,_L2){if(_L2&&!_L2())return false;if(this.selectedId){this.lastSelected=this.selectedId;CSS.removeClass(ge(this.selectedId),'Tabset_selected');}this.selectedId=_L0;CSS.addClass(ge(this.selectedId),'Tabset_selected');if(_L1)return _L1();return true;};Tabset.prototype.unselect=function(){if(this.selectedId)CSS.removeClass($(this.selectedId),'Tabset_selected');};Tabset.prototype.hasTabElem=function(id){return ge(this.id+'_'+id);};Tabset.prototype.getTabElem=function(id){return $(this.id+'_'+id);};
Arbiter.inform("template\/registerTemplate", {"name":"\/templates\/UIActionMenu.tmpl","template":"\n<div class=\"UIActionMenu\" bindPoint=\"root\">\n  <a class=\"UIActionMenu_Wrap\" bindPoint=\"wrap\" href=\"#\">\n    <span class=\"UIActionMenu_Icon\" bindPoint=\"icon\"><\/span>\n    <span class=\"UIActionMenu_Text\" bindPoint=\"text\"><\/span>\n    <span class=\"UIActionMenu_Chevron\"><\/span>\n  <\/a>\n  <div class=\"UIActionMenu_Menu\" bindPoint=\"menu\"><\/div>\n<\/div>\n"}, Arbiter.BEHAVIOR_PERSISTENT);
function UIActionMenu(_L0){this.root=null;this.wrap=null;this.icon=null;this.text=null;this.menu=null;this._title=_L0;this._contentCallback=bagofholding;this._selectList=null;this.parent.construct(this,URI('/templates/UIActionMenu.tmpl'));this._initialize();}UIActionMenu.extend('TemplateObject');copy_properties(UIActionMenu,{ICONS:{LOCK:'UIActionMenu_Lock'},COLORS:{BLUE:'UIActionMenu_Blue'}});UIActionMenu.mixin('Arbiter',{_initialize:function(){var _L0=false,_L1=null;_L1=Event.listen(this.root,'mousedown',function(){this.buildMenu();_L1.remove();}.bind(this));if(ua.ie()){Event.listen(this.root,'mousedown',function(_L2){if(this.menuVisible()&&!DOM.contains(this.menu,_L2.getTarget()))document.body.focus();}.bind(this));Event.listen(this.root,{'activate':this.showMenu.bind(this),'deactivate':this.hideMenu.bind(this),'selectstart':Event.kill});}else{this.input=$N('input',{type:'button'});DOM.prependContent(this.wrap,this.input);Event.listen(this.root,'mousedown',function(_L2){var _L3=_L2.getTarget();if(DOM.contains(this.menu,_L3)){if(!DOM.isNode(_L3,'input'))setTimeout(function(){this.input.focus();}.bind(this),100);_L0=true;return;}this.toggleMenu();this.input.focus();return false;}.bind(this));Event.listen(this.input,'blur',function(_L2){if(_L0){_L0=false;return;}this.hideMenu();}.bind(this));}Event.listen(this.wrap,'click',function(_L2){_L2.kill();});},menuVisible:function(){return CSS.hasClass(this.root,'UIActionMenu_Active');},hideMenu:function(){CSS.removeClass(this.root,'UIActionMenu_Active');return this;},showMenu:function(){this.inform('menuActivated');CSS.addClass(this.root,'UIActionMenu_Active');return this;},toggleMenu:function(){if(this.menuVisible()){return this.hideMenu();}else return this.showMenu();},setAlignRight:function(_L0){CSS.conditionClass(this.root,'UIActionMenu_AlignRight',_L0);return this;},setContentCallback:function(fn){this._contentCallback=fn;return this;},setSuppressButton:function(_L0){CSS.conditionClass(this.root,'UIActionMenu_SuppressButton',_L0);return this;},setSuppressText:function(_L0){CSS.conditionClass(this.root,'UIActionMenu_SuppressText',_L0);return this;},setColor:function(_L0){switch(_L0){case UIActionMenu.COLORS.BLUE:if(this.color)CSS.removeClass(this.root,this.color);CSS.addClass(this.root,_L0);this.color=_L0;break;default:if(this.color){CSS.removeClass(this.root,this.color);this.color=null;}}return this;},setIcon:function(_L0){switch(_L0){case UIActionMenu.ICONS.LOCK:CSS.addClass(this.root,'UIActionMenu_IconIncluded');CSS.addClass(this.icon,_L0);break;default:CSS.removeClass(this.root,'UIActionMenu_IconIncluded');Util.error('invalid icon passed to `UIActionMenu.setIcon`');}return this;},_getContent:function(){var _L0=this._contentCallback();if(this.input){var _L1=DOM.scry(_L0,'input');_L1.each(function(_L2){Event.listen(_L2,'blur',function(){this.input.focus();}.bind(this));},this);}return _L0;},setTitle:function(_L0){this._title=_L0;DOM.setContent(this.text,this._title);return this;},setTooltip:function(_L0){if(this.tooltip){if(_L0){DOM.setContent(this.tooltip.firstChild,_L0);}else{DOM.remove(this.tooltip);CSS.removeClass(this.wrap,'UITooltip');this.tooltip=null;}}else{this.tooltip=$N('span',{className:'UITooltip_Wrap'},$N('span',{className:'UITooltip_Text'},_L0));CSS.addClass(this.wrap,'UITooltip');DOM.prependContent(this.wrap,this.tooltip);}return this;},getNodes:function(){DOM.setContent(this.text,this._title);return [this.root];},buildMenu:function(){DOM.setContent(this.menu,this._getContent());return this;},useSelectList:function(_L0,_L1,_L2){_L2=_L2||UISelectList.MULTI_SELECT_MODE;this.setContentCallback(function(){this._selectList=new UISelectList().setMode(_L2).setCallback(function(_L3,key){this.hideMenu();_L1&&_L1(_L3,key);}.bind(this)).addItems(_L0);return this._selectList.getElement();}.bind(this));return this;},resetSelectList:function(){this._selectList&&this._selectList.reset();},getSelectList:function(){return this._selectList;}});

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