/*    HTTP Host:  static.ak.fbcdn.net                                          */
/*    Generated:  February 9th 2010 11:03:56 PM PST                            */
/*      Machine:  10.16.140.104                                                */
/*       Source:  Backing Store                                                */
/*     Location:  js/lib/ui/typeaheadpro/sources/friend_and_email_source.js h:exx6bor7 */
/*       Locale:  nu_ll                                                        */
/*         Path:  js/lib/ui/typeaheadpro/sources/friend_and_email_source.js    */

if (window.CavalryLogger) { CavalryLogger.start_js(["js\/lib\/ui\/typeaheadpro\/sources\/friend_and_email_source.js"]); }

function friend_and_email_source(_L0){_L0=_L0?_L0+'&include_emails=1':'';this.parent.construct(this,_L0);}friend_and_email_source.extend('friend_source');friend_and_email_source.prototype.text_noinput=friend_and_email_source.prototype.text_placeholder=_tx("Type the name of a friend, list, or email address");friend_and_email_source.prototype.text_nomatch=_tx("\u041c\u043e\u0436\u0435\u0442\u0435 \u0434\u0430 \u043d\u0430\u043f\u0438\u0448\u0435\u0442\u0435 \u0430\u0434\u0440\u0435\u0441 \u043d\u0430 \u0435\u043b\u0435\u043a\u0442\u043e\u0440\u043d\u043d\u0430 \u043f\u043e\u0449\u0430...");friend_and_email_source.prototype.onselect_not_found=function(){emails=this.results_text.split(/[,; ]/);for(var i=0;i<emails.length;i++){var _L1=emails[i].replace(/^\s+|\s+$/g,'');var _L2=/.*\@.*\.[a-z]+$/;if(!_L2.test(_L1))continue;var _L3={t:_L1,e:_L1};var _L4=new token(_L3,this.tokenizer,this.element);var _L5={email:_L1,pluses:false};new AsyncRequest().setMethod('GET').setReadOnly(true).setURI('/ajax/typeahead_email.php').setData(_L5).setHandler(function(_L6){if(_L6.getPayload()){var obj=_L6.getPayload().token;this.render_obj(obj);this.tokenizer._ontokenadded(obj);}else this.tokenizer._ontokennotfound(_L1);}.bind(_L4)).setErrorHandler(function(_L6){ErrorDialog.showAsyncError(_L6);this.remove(false);}.bind(_L4)).send();}this.clear();};

if (window.Bootloader) { Bootloader.done(["js\/lib\/ui\/typeaheadpro\/sources\/friend_and_email_source.js"]); }