/*
* Zaglądasz do kodu? To świetnie! Każdy dobry webdeveloper to robi :)
* Szukasz ciekawej pracy? pisz na adres praca@gadu-gadu.pl z dopiskiem web-devel
*
* WebGadu 3
* (c) 2006-2008 Gadu-Gadu S.A.
*
*/
var nz={gy:"Zapisz",sh:"Wyślij",iM:"Numer GG",uv:"Pole wymagane",ed:"Ja",xs:"Jestem na WebGadu",tY:"Wczytywanie",so:"Profil użytkownika",ya:"Prawie gotowe",xY:"Ustaw w statusie wersję WebGadu",gv:"Możesz zamknąć okno przeglądarki.",um:"Dane użytkownika",oM:"Serwer zakończył połączenie. Czy chcesz ponownie zalogować się?",uq:"Nie można połączyć się z serwerem.",us:"Wyłącz oprogramowanie blokujące reklamy!",up:"WebGadu działa w przeglądarkach: Firefox, Internet Explorer, Opera 9.x oraz Safari 3.x",uR:"Rozmowy",dO:"Zaloguj się",mh:"Dane użytkownika",nd:"Ustawienia",mE:"Lista zablokowanych",mD:"Grupy kontaktów",uH:"O programie",xR:"Pogrubienie",xV:"Kursywa",xU:"Podkreślenie",xP:"Kolor",xQ:"Emotikony",xS:"Wyczyść",xW:"Kasuj formatowanie",yc:"Dodaj kontakt",yb:"Zablokuj kontakt",xT:"Szukaj",ua:"Zapisz",tQ:"Nazwa",ph:"Edycja kontaktu",pU:"Dodaj kontakt",dW:"Imię",dV:"Nazwisko",uN:"Nazwa wyświetlana",pW:"Telefon komórkowy",pV:"Grupa",qT:"Adres e-mail",qU:"Telefon domowy",uD:"Nazwa wyświetlana nie może być pusta!",gx:"Niepoprawny numer GG!",uF:"Średnik jest znakiem zabronionym.",uE:"Nie można dodać samego siebie",pH:"Dane kontaktowe",tu:"Dane osobowe",xL:"Kontakt o podanej nazwie istnieje już na liście kontaktów",xM:"Kontakt o podanym numerze GG istnieje już na liście kontaktów",uG:"Pseudo",nB:"Płeć",uJ:"Mężczyzna",uI:"Kobieta",ni:"Rok urodzenia",xz:"Niepoprawny rok urodzenia",nC:"Miasto",uQ:"Prowadzimy Katalog Publiczny użytkowników Gadu-Gadu. Podanie danych nie jest obowiązkowe, ale im więcej podasz tym łatwiej inni odnajdą cię w sieci Gadu-Gadu:",uK:"Możesz podać nazwisko rodowe oraz miejscowość, z której pochodzisz (jeśli są inne niż obecne). Przy wyszukiwaniu wg nazwiska lub miejscowości będą wtedy też brane pod uwagę:",nx:"Nazwisko rodowe",nF:"Miejscowość pochodzenia",nf:"Zapisz profil",pf:"Nazwa użytkownika",mK:"Domyślny status",mJ:"Domyślny opis",oG:"Importuj listę kontaktów po zalogowaniu",nL:"Grupuj wiadomości od tego samego kontaktu",oV:"Informuj w oknie rozmowy gdy kontakt zmieni status",oE:"Informuj w oknie powiadomień gdy kontakt zmieni status",ho:"Ostrzegaj przed otwarciem linku",oF:"Opcje",sG:"Dźwięki",wX:"Włącz dźwięk dostępności",sv:"Włącz dźwięk wiadomości",pS:"Włącz w trakcie rozmowy z nadawcą",uS:"Nazwa",uP:"Wersja",ro:'Copyright &copy; 2006-2009 GG Network S.A.\n<a href="http://www.gadu-gadu.pl" target="_blank">www.gadu-gadu.pl</a>\n\nExt JS - JavaScript Library\nCopyright (c) 2006-2008, Ext JS,LLC\n\nux.MediaPanel is licensed under the terms of the Open Source LGPL 3.0 license.Copyright 2007-2008, Active Group, Inc.  All rights reserved. Ext.ux.YoutubePlayer - Thorsten Suckow-Homberg\n\nA JavaScript implementation of the Secure Hash Algorithm, SHA-1 Version 2.1a Copyright Paul Johnston 2000 - 2002\n Other contributors: Greg Holt, Andrew Kepert, Ydnar, Lostinet\nDistributed under the BSD License\n\nJavaScript OAuth Library\nCopyright 2008 Netflix, Inc.',wI:"Hasło",iB:"Numer GG",uj:"Twoje konto",dT:'Zły login lub hasło. <a href="https://login.gadu-gadu.pl/account/remindpass" target="_blank">Przypomnij hasło</a>',wH:"Czy chcesz się ponownie zalogować?",uA:"Numer GG",xv:"Połączenie",xo:"Standardowe",xn:"Bezpieczne przez SSL",xl:"http://login.gadu-gadu.pl/account/register/pl/",xm:"Zarejestruj się",xu:"<b>Nie masz konta Gadu-Gadu?</b><br>Rejestracja jest prosta.",tO:"Odblokuj zaznaczone",uk:"Zablokowane kontakty",lB:"Brak zablokowanych kontaktów",iq:"Lista Kontaktów",eQ:"Dodaj",wK:"Eksportuj",ga:"Importuj",fF:"Eksport listy kontaktów zakończony",ff:"Szukaj znajomych",wM:"Nagłos",wJ:"MojaGeneracja",fg:"Radio",wL:"WWW",fx:"Edytuj",wP:"Usuń",wQ:"Zablokuj",fE:"Rozmowa",gM:"Lista zablokowanych",wN:"O programie...",fT:"Pomoc",yU:"Zakończ",fp:"Ustawienia",fw:"Mój profil",xa:"nazwa lub numer GG",xZ:"Zgłoś błąd",yd:"http://gadu-gadu.pl/kontakt",ye:"Nowe Gadu-Gadu",yf:"http://gadu-gadu.pl/pobierz",ft:"Gadu-Gadu",fu:"Kontakty",ur:"Gadu-Gadu",tW:"",ot:"Dostępny",oq:"Zaraz wracam",or:"Niewidoczny",of:"Niedostępny",uu:"Opis",nY:"Pozostałe",tR:"(nieznajomy)",uy:"Pokazuj status tylko znajomym",uz:"Nie pokazuj od nieznajomych",ob:"Brak zaznaczonych kontaktów do usunięcia.",oD:"Czy usunąć zaznaczone kontakty?",uB:"Zablokowano zaznaczone kontakty.",lE:"Czy dodać listy zablokowanych?",pg:"Brak zaznaczonych kontaktów do zablokowania!",oh:"Brak zaznaczonych kontaktów do edycji!",pa:"Zaznacz osobę lub osoby, z którymi chesz porozmawiać.",fP:"Kontakt nie ma wpisanego numeru Gadu-Gadu.",os:"Nie można rozmawiać z samym sobą.",uL:"Czy chcesz importować listę kontaktów po zalogowaniu się?",oa:"Twoja lista kontaktów zawiera więcej niż 300 wpisów. Import całej listy może powodować niestabilność działania przeglądarki internetowej. Czy mimo to chcesz zaimportować całą listę?",gd:"Użytkownik wpisał cię na listę zablokowanych. Nie możesz wysyłać do niego wiadomości",fA:"Nie masz kontaktów na serwerze. Dodaj znajomych i kliknij Kontakty->Eksportuj",bS:"Lista kontaktów jest pusta. Dodaj znajomych i kliknij Kontakty->Eksportuj",sM:"dostępny",sz:"zaraz wracam",st:"niedostępny",wO:"zmienia status na",eY:"przesyła wiadomość",eO:"dodał Cię do listy zablokowanych użytkowników",wU:"OK",wT:"Tak",wR:"Nie",wS:"Anuluj",yC:"Zamknij",mL:"Wyszukiwanie kontaktów",sV:"Imię",uC:"Nazwisko",sU:"Pseudo",un:"Płeć",rV:"mężczyzna",rT:"kobieta",xC:"nie podano",pe:"Wiek",uO:"od",mf:"do",tE:"Miejscowość",rU:"Numer GG",ng:"Tylko dostępne",nn:"Szukaj",nu:"Więcej",tX:"Gadu-Gadu",uw:"Imię, Pseudo",ut:"Wiek",uo:"Miejscowość",tF:"Podaj kryteria wyszukiwania!",oI:'Pamiętaj, że kliknięcie w link spowoduje otwarcie strony www, która może być niebezpieczna dla Twojego komputera!<br />Upewnij się, czy na pewno ufasz przesłanemu linkowi i chcesz wejść na podaną stronę www!<br /><br />Więcej o bezpiecznym korzystaniu z Internetu: <a href="http://bezpieczne.gadu-gadu.pl/" target="_blank">http://bezpieczne.gadu-gadu.pl/</a><br /><br />Czy napewno chcesz wejść na tę stronę?',xt:"Polski (zmień)",xw:"Polski",xy:"English",xp:"O WebGadu",xq:"Możliwości",xr:"Wymagania",xB:"Bezpieczeństwo",oo:"Od",op:"Data",zj:"Czy aby na pewno wyjść z tej strony?<br /><br />Naciśnij Tak, by kontynuować lub Nie, by pozostać na aktualnej stronie.",xD:"Jeśli się wylogujesz, Twoja sesja komunikatora WebGadu nie zachowa się!",xA:"Kontakt",oH:"http://www.gadu-gadu.pl/kontakt",nQ:"FAQ",xE:"http://webowe.gadu-gadu.pl/pomoc",yD:"Wiadomość dla użytkownika",yA:"Posłuchaj muzyki w OPEN.FM",uM:"zazółć gęślą jaźń ZAŻÓ?Ć G?ŚLĄ JAŹ?"};var xO={gy:"Save",sh:"Send",iM:"GG Number",uv:"Field required",ed:"Me",xs:"I am on WebGadu",so:"User ql",ya:"Almost ready",xY:"Set in the status WebGadu version",gv:"You can close browser window",um:"User data",oM:"Server was disconnected. Do you want to log in again?",uq:"Cannot gr to server",us:"Disable yk blocking software!",up:"WebGadu works in browsers: Firefox, Internet Explorer, Opera 9.x and Safari 3.x",uR:"Chats",dO:"Log in",mh:"User data",nd:"Settings",mE:"Ignore list",mD:"Contact lH",uH:"About the programme",xR:"Bold",xV:"Italic",xU:"Underline",xP:"Color",xQ:"Emoticons",xS:"Clear",xW:"Remove formatting",yc:"Add contact",yb:"Ban contact",xT:"Search",tQ:"Nick",ph:"Edit contact",pU:"Add contact",dW:"Name",dV:"Surname",uN:"Visible name",pW:"Mobile phone",pV:"Group",qT:"E-mail address",qU:"Home phone",uD:"Visible name must be filled in!",gx:"Incorrect GG number!",uF:"Semicolon is forbidden",uE:"You cannot add yourself",pH:"Contact data",tu:"Personal data",xL:"Contact with the given name already ia on the list of gK",xM:"Contact with the given number GG already ia on the list of gK",uG:"Nick",nB:"Gender",uJ:"Male",uI:"Female",ni:"Year of birth",xz:"Invalid year of birth",nC:"City",uQ:"We keep Public Catalogue of Gadu-Gadu Users. Submitting your data is not obligatory, but the oJ data you submit the easier it will be for others to find you in Gadu-Gadu network.",uK:"You can give your family name and city you come from (if they are different than current ones). They will be included when searching by name or city",nx:"Family name",nF:"City of origin",nf:"Save profile",pf:"User name",mK:"Default status",mJ:"Default description",oG:"Import contact list when logged in",nL:"Group messages from the same contact",oV:"Notify in message window when contact changes status",oE:"Notify in pop-up window when contact changes status",ho:"Warn before opening link",oF:"Options",uS:"Name",uP:"Version",wI:"Password",iB:"GG number",uj:"Your account",dT:"Bad login or password",wH:"Do you want to log in again?",uA:"GG number",xv:"Log in safely",xo:"Standard",xn:"Safe with SSL",xm:"Sign Up",xu:"<b>No Gadu-Gadu account?</b><br>Registration is easy!",xl:"https://login.gadu-gadu.pl/account/register/en/",tO:"Unblock highlighted gK",uk:"Banned gK",lB:"No blocked gK",iq:"Contact list",eQ:"Add contact",wK:"Export",ga:"Import",fF:"Contact list export complete",ff:"Search for your friends",wM:"Nagłos",wJ:"MojaGeneracja",fg:"Radio",wL:"WWW",fx:"Edit contact",wP:"Delete",wQ:"Ban",fE:"Chat",gM:"Ignore list",wN:"About",fT:"Help",yU:"Close",fp:"Settings",fw:"My profile",xa:"Name or GG number",xZ:"Send bug",ye:"New Gadu-Gadu",ft:"Gadu-Gadu",fu:"Contacts",ur:"Gadu-Gadu",ot:"Available",oq:"Be right back / Busy",or:"Invisible",of:"Not available",uu:"Description",nY:"Others",tR:"Unknown user",uy:"Show my status only to friends",uz:"Do not show messages from unknown users",ob:"No highlighted gK to delete",oD:"Do you want to delete highlighted gK?",uB:"Highlighted gK banned",lE:"Do you want to add banned lists",pg:"No highlighted gK to ban!",oh:"No highlighted gK to edit!",pa:"Highlight a person or persons you want to chat with",fP:"Contact has not entered GG number",os:"You cannot chat with yourself",uL:"Do you want to import contact list when logging in?",oa:"Your contact list contains oJ than 300 entries",gd:"User added you to blocked list. You cannot send messages to this user.",fA:"You do not have gK on the server. Add friends and hit Contacts->Export",bS:" Contact list is empty. Add friends and hit Contacts->Export",sM:"Available",sz:"Be right back / busy",st:"Unavailable",wO:"Changes status to",eY:"Sends message",eO:"Added you to blocked users list",wU:"OK.",wT:"Yes",wR:"No",wS:"Cancel",yC:"Close",mL:"Contact Search",sV:"Name",uC:"Surname",sU:"Nick",un:"Gender",rV:"Male",rT:"Female",xC:"not given",pe:"Age",uO:"From",mf:"To",tE:"City",rU:"GG number",ng:"Available Only",nn:"Search for your friends",nu:"More",tX:"Gadu-Gadu",uw:"Name, Nick",ut:"Age",uo:"City",tF:"State search criteria!",oI:'Remember that clicking the link will open a website which may be dangerous for your computer! Make sure that you trust this link and want to enter this website! More about safe use of Internet <a href="http://bezpieczne.gadu-gadu.pl/" target="_blank">http://bezpieczne.gadu-gadu.pl/</a>',xt:"English (change)",xw:"Polski",xy:"English",xp:"About WebGadu",xq:"Features",xr:"Requirements",xB:"Safety",xA:"Contact",oH:"http://www.gadu-gadu.pl/kontakt",xD:"If you leave, your WebGadu session will not be preserved! ",zj:"Are you sure you want to leave this page?<br /><br />Click Yes to continue or No to stay on the current page.",nQ:"FAQ",xE:"http://webowe.gadu-gadu.pl/pomoc",yA:"Listen to music in OPEN.FM",yD:"Message for user",wX:"Turn on the availability sound",sv:"Turn on the messages sound",pS:"Turn on during the chat",a:""};if(/default_lang%3Den%26/.test(document.cookie)||(!/default_lang/.test(document.cookie)&&/en-US;/.test(navigator.userAgent))){Object.extend(nz,xO)}var cl=function(){};if(typeof gg=="undefined"){var gg=function(){}}Object.extend(gg,{D:{fv:cl,lK:{sD:cl},protocol:{gg:cl}},fv:cl,lK:cl});gg.D.gp=function(){};Object.extend(gg.D.gp,{get:function(B){return typeof gg.D.gp.eD[B]!="undefined"?gg.D.gp.eD[B]:null},iH:function(B){if(typeof B!="object"){return }var C={};B.each(function(D){C[D]=typeof gg.D.gp.eD[D]=="undefined"?"":gg.D.gp.eD[D]});return C},set:function(C,B){gg.D.gp.eD[C]=B;return B},xF:function(){var B=[gq.tP,gq.xG,gq.ts,gq.tq,gq.tC,gq.tv,gq.tw,gq.tx,gq.lD,gq.pm,gq.pl,gq.eP,gq.yo,gq.yn,gq.ym];if(gg.D.gp.get(gq.dB)||gg.D.gp.get(gq.cT)){B.push(gq.ty)}gg.fv.sq.set("userData",gg.D.gp.iH(B))},bind:function(B){if(typeof B!="object"){return }for(cc in B){if(gg.D.gp.aY.indexOf(cc)>-1&&!(B[cc]===true||B[cc]===false)){B[cc]=Boolean(parseInt(B[cc]))}gg.D.gp.eD[cc]=B[cc]}}});gg.D.gp.gq={ox:1,ov:2,tP:"gui_visible_name",rZ:4,sa:5,rP:6,rR:7,rQ:8,ik:9,lD:"group_messages",pj:10,pk:11,pn:12,pm:"chatwnd_notify",pl:"notify_status_change",eP:"warn_open_link",yo:"notify_sound_status",yn:"notify_sound_message",ym:"notify_sound_message_chat",lC:13,rI:14,nR:17,ty:"user_login",tz:"user_password",ts:"user_default_status",tq:"user_default_desc",tC:"user_visible_for_all",tv:"user_from_all",tw:"user_import_contacts",tx:"user_import_contacts_selected",xG:"default_lang",sr:"storage_expires_time",qd:"path.root",rX:"sid_gg",fe:15,fd:16,hs:18,cq:19,qV:20,sA:21,ta:22,cH:23,cT:24,dB:25,fk:26,aR:27};var gq=gg.D.gp.gq;gg.D.gp.aY=[gq.tC,gq.tv,gq.lD,gq.pm,gq.pl,gq.tw,gq.yo,gq.yn,gq.ym];gg.D.gp.eD={};with(gg.D.gp){set(gq.fd,"WebGadu 3.1");set(gq.fe,"b9513");set(gq.qd,"./");set(gq.cq,"");set(gq.sr,365*50);set(gq.ty,"");set(gq.tz,"");set(gq.ts,4);set(gq.tq,nz.xs);set(gq.tC,true);set(gq.tw,true);set(gq.tv,true);set(gq.eP,true);set(gq.xG,"pl");set(gq.ox,true);set(gq.ov,true);set(gq.tP,nz.ed);set(gq.nR,300);set(gq.rZ,"skins/");set(gq.sa,"emoticons/");set(gq.rP,"sfx/");set(gq.rR,"status.mp3");set(gq.rQ,"message.mp3");set(gq.ik,false);set(gq.lD,false);set(gq.pj,true);set(gq.pk,true);set(gq.pn,true);set(gq.pm,true);set(gq.pl,true);set(gq.yo,true);set(gq.yn,true);set(gq.ym,false);set(gq.lC,true);set(gq.rI,true);set(gq.hs,70);set(gq.qV,{width:242,height:500,top:120,margin:10});set(gq.sA,{width:412,height:487,top:120,margin:10});set(gq.ta,true);set(gq.cH,true);set(gq.cT,false);set(gq.dB,false);set(gq.fk,false);set(gq.aR,false)}Event.observe(window,"unload",function(){gg.D.gp.xF();gg.D.protocol.gg.gi.hU.fD(fo.ly,{status:qn.jV,description:""})});gg.D.gQ=function(){};Object.extend(gg.D.gQ,{dR:{261:97,281:101,347:115,322:108,380:122,378:122.1,263:99,324:110},tM:function(D,B){var C=Math.min(D.length,B.length),G,F;D=D.toLowerCase();B=B.toLowerCase();for(var E=0;E<C;E++){G=D.charCodeAt(E);if(typeof gg.D.gQ.dR[G]!="undefined"){G=gg.D.gQ.dR[G]+0.5}F=B.charCodeAt(E);if(typeof gg.D.gQ.dR[F]!="undefined"){F=gg.D.gQ.dR[F]+0.5}if(G==F){continue}return G-F}return D.length-B.length},sn:function(B,C){switch(B){case"NOT_AVAIL":return C?qn.jW:qn.jV;case"AVAIL":return C?qn.jO:qn.jN;case"BUSY":return C?qn.jR:qn.jQ;case"INVISIBLE":return C?qn.jU:qn.jT;case"BLOCKED":return qn.jP;default:return C?qn.jW:qn.jV}}});var hexcase=0;var b64pad="";var chrsz=8;function yR(B){return yJ(hD(iv(B),B.length*chrsz))}function zF(B){return yI(hD(iv(B),B.length*chrsz))}function yV(B){return yK(hD(iv(B),B.length*chrsz))}function zI(B,C){return yJ(yG(B,C))}function zH(B,C){return yI(yG(B,C))}function zE(B,C){return yK(yG(B,C))}function zJ(){return yR("abc")=="a9993e364706816aba3e25717850c26c9cd0d89d"}function hD(O,I){O[I>>5]|=128<<(24-I%32);O[((I+64>>9)<<4)+15]=I;var P=Array(80);var N=1732584193;var M=-271733879;var L=-1732584194;var K=271733878;var J=-1009589776;for(var F=0;F<O.length;F+=16){var H=N;var G=M;var E=L;var D=K;var B=J;for(var C=0;C<80;C++){if(C<16){P[C]=O[F+C]}else{P[C]=sJ(P[C-3]^P[C-8]^P[C-14]^P[C-16],1)}var Q=fz(fz(sJ(N,5),yO(C,M,L,K)),fz(fz(J,P[C]),yQ(C)));J=K;K=L;L=sJ(M,30);M=N;N=Q}N=fz(N,H);M=fz(M,G);L=fz(L,E);K=fz(K,D);J=fz(J,B)}return Array(N,M,L,K,J)}function yO(C,B,E,D){if(C<20){return(B&E)|((~B)&D)}if(C<40){return B^E^D}if(C<60){return(B&E)|(B&D)|(E&D)}return B^E^D}function yQ(B){return(B<20)?1518500249:(B<40)?1859775393:(B<60)?-1894007588:-899497514}function yG(D,G){var F=iv(D);if(F.length>16){F=hD(F,D.length*chrsz)}var B=Array(16),E=Array(16);for(var C=0;C<16;C++){B[C]=F[C]^909522486;E[C]=F[C]^1549556828}var H=hD(B.concat(iv(G)),512+G.length*chrsz);return hD(E.concat(H),512+160)}function fz(B,E){var D=(B&65535)+(E&65535);var C=(B>>16)+(E>>16)+(D>>16);return(C<<16)|(D&65535)}function sJ(C,B){return(C<<B)|(C>>>(32-B))}function iv(E){var D=Array();var B=(1<<chrsz)-1;for(var C=0;C<E.length*chrsz;C+=chrsz){D[C>>5]|=(E.charCodeAt(C/chrsz)&B)<<(32-chrsz-C%32)}return D}function yK(E){var D="";var B=(1<<chrsz)-1;for(var C=0;C<E.length*32;C+=chrsz){D+=String.fromCharCode((E[C>>5]>>>(32-chrsz-C%32))&B)}return D}function yJ(E){var D=hexcase?"0123456789ABCDEF":"0123456789abcdef";var C="";for(var B=0;B<E.length*4;B++){C+=D.charAt((E[B>>2]>>((3-B%4)*8+4))&15)+D.charAt((E[B>>2]>>((3-B%4)*8))&15)}return C}function yI(F){var E="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";var D="";for(var C=0;C<F.length*4;C+=3){var G=(((F[C>>2]>>8*(3-C%4))&255)<<16)|(((F[C+1>>2]>>8*(3-(C+1)%4))&255)<<8)|((F[C+2>>2]>>8*(3-(C+2)%4))&255);for(var B=0;B<4;B++){if(C*8+B*6>F.length*32){D+=b64pad}else{D+=E.charAt((G>>6*(3-B))&63)}}}return D}gg.fv.sq=function(){};gg.fv.sq.gO=function(){};gg.fv.sq.gO.MAX_SIZE=4000;Object.extend(gg.fv.sq.gO.prototype,{get:function(C,B){return typeof B=="undefined"?this.bN(C):B?this.bH(C):this.bN(C)},set:function(C,F,B,G,E,D){typeof F!="object"?this.dP(C,F.toString(),B,G,E,D):this.dN(C,F,B,G,E,D)},dP:function(J,G,C,K,D,B){var I="",F="",E=0;expires=typeof expires=="undefined"?gg.D.gp.get(gq.sr):expires;if(typeof expires=="number"&&expires>=0){var H=new Date();H.setTime(H.getTime()+(expires*24*60*60*1000));expires=H.toUTCString()}while(G.length>gg.fv.sq.gO.MAX_SIZE){document.cookie=a=this.bE(J+"__"+E++,G.substring(0,gg.fv.sq.gO.MAX_SIZE),expires,K,D,B);G=G.substring(gg.fv.sq.gO.MAX_SIZE)}document.cookie=a=this.bE(J+"__"+E,G,expires,K,D,B)},bE:function(D,C,B,G,F,E){return"[["+D+"]]="+escape(C)+";"+(B!=-1?" expires="+B+";":"")+(G?"path="+G:"")+(F?"; domain="+F:"")+(E?"; ry":"")},dN:function(C,D,B,I,H,G){var F=[],E="";for(cc in D){switch(typeof D[cc]){case"string":case"number":F.push(escape(cc)+"="+escape(D[cc]));break;case"boolean":F.push(escape(cc)+"="+(D[cc]?1:0));break}}this.dP(C,F.join("&"),B,I,H,G)},bN:function(C,F){var B=0;var E="",D="";F=F||document.cookie;while((D=this.bF(C+"__"+B++,document.cookie))!==null){E+=D}return E},bF:function(E,C){var F="";E="[["+E+"]]";var D=C.indexOf(E+"=");if(D==-1){return null}var F=C.substring(D+E.length+1);var B=F.indexOf(";");if(B==-1){B=F.length}F=F.substring(0,B);F=unescape(F);return F},bH:function(D){var E=null,C=this.bN(D);if(C){E={};var G=C.split("&");for(var B=0;B<G.length;B++){var H=G[B].split("=");var F=H[1];E[unescape(H[0])]=unescape(H[1])}}return E}});Object.extend(gg.fv.sq,{ea:new gg.fv.sq.gO(),get:function(C,B){return this.ea.get(C,B)},set:function(B,C){this.ea.set(B,C)}});gg.fv.nz=function(){if(typeof this["current"]=="undefined"){}};gg.fv.nz.rs="lang";gg.fv.nz.ru=gg.D.gp.get("path.root")+"js/gg/D/lang/";Object.extend(gg.fv.nz,{dy:null,description:null,cG:{},ce:0,get:function(){return this.current},iE:function(){return this.description},set:function(D,E){if(this.get()==D){return false}this.dy=D;try{Element.remove($(gg.fv.nz.rs))}catch(C){}var B=document.createElement("script");B.type="text/javascript";B.src=gg.fv.nz.ru+D+".js";B.id=gg.fv.nz.rs;document.body.appendChild(B);if(typeof E=="undefined"){var E=null}window.setTimeout(function(){gg.fv.nz.ao(E)},500);return true},add:function(B,D,C){if(typeof B=="string"){B=$(B)}if(!B){return false}if(typeof C=="undefined"){this.cG[this.ce++]=[B,D]}else{this.cG[this.ce++]=[B,D,C]}},eZ:function(B,C){return this.add(B,C,true)},ia:function(B){return typeof nz[B]!="undefined"},ao:function(E){if(this.dy!=this.current){window.setTimeout(function(){gg.fv.nz.ao(E)},500);return }for(var B in this.cG){var D=this.cG[B];if(D.length==2){if(typeof D[0]=="undefined"){try{delete this.cG[B]}catch(C){}continue}D[0].innerHTML=nz[D[1]]||"?"}else{if(typeof D[2]=="boolean"){D[0].innerHTML=this.qb(D[1])}else{D[0].setAttribute(D[2],nz[D[1]]||"?")}}}if(E!==null){E()}},qb:function(B){B=B.replace(/\{([^}]+)\}/g,function(C,D){return nz[D]||"?"});return B}});gg.fv.hY=function(){};Object.extend(gg.fv.hY,{pY:"__",iu:"_",sp:{},ce:0,bM:function(E,D){var D=typeof D!="undefined"?D:true;var E=E=="/"?new Array(""):E.split("/");var B=null;var F=this.sp;for(var C=0;C<E.length;C++){if(typeof F[E[C]]=="undefined"){if(D){F[E[C]]=new Object();F[E[C]][this.pY]=F;F[E[C]][this.iu]={}}else{return F}}B=F;F=F[E[C]]}return F},bP:function(){return this.ce++},iL:function(B){return this.bM(B,true)},mG:function(B,E,D){var C=this.bM(B);if(typeof C[this.iu][D]=="undefined"){C[this.iu][D]=E;return 0}if(typeof C[this.iu][D]=="function"){C[this.iu][D]=[C[this.iu][D]]}C[this.iu][D].push(E);return C[this.iu][D].length},mI:function(B,E,C,D){if(typeof C[this.iu][D]=="undefined"){C[this.iu][D]=E;return 0}if(typeof C[this.iu][D]=="function"){C[this.iu][D]=[C[this.iu][D]]}C[this.iu][D].push(E);return C[this.iu][D].length},tg:function(B,E){var D=this.bM(B);if(typeof D[this.iu]=="undefined"||typeof D[this.iu][E]=="undefined"){return false}try{delete D[this.iu][E]}catch(C){D[this.iu][E]=null}},er:function(B,H,G){var C=B;var D=this.ck!="";while(1){if(D&&this.ck.test(H)){if(typeof C[this.pY]=="undefined"){break}C=C[this.pY];H=H.substring(0,H.lastIndexOf("/"));(H=="")&&(H="/");continue}if(typeof C[this.iu]!="undefined"){var I=[];for(var J in C[this.iu]){I.push(J)}for(var E=0;E<I.length;E++){var J=C[this.iu][I[E]];if(typeof J=="function"){if(J.apply(null,G)===false){return }}else{for(var E=0,F=J.length;E<F;E++){if(J[E].apply(null,G)===false){return }}}}}if(typeof C[this.pY]=="undefined"){break}C=C[this.pY];H=H.substring(0,H.lastIndexOf("/"));(H=="")&&(H="/")}},fD:function(C,B){var D=this.bM(C,false);if(D===false){return false}this.er(D,C,B)},cj:{},ck:"",mU:function(B,C){this.cj[B]=C;this.db();return true},ti:function(B){if(typeof this.cj[B]=="undefined"){return false}delete this.cj[B];this.db();return true},db:function(){this.ck="";for(var B in this.cj){if(this.cj[B]){this.ck+="("+B+")|"}else{this.ck+="("+B.replace("*",".+")+")|"}}this.ck=this.ck.substring(0,this.ck.length-1);if(this.ck!=""){this.ck=new RegExp("^"+this.ck+"$")}}});gg.fv.gz=function(){this.ce=gg.fv.hY.bP();return this};Object.extend(gg.fv.gz.prototype,{ce:null,mG:function(B,C){return gg.fv.hY.mG(B,C,this.ce)},mI:function(B,D,C){return gg.fv.hY.mI(B,D,C,this.ce)},tg:function(B){return gg.fv.hY.tg(B,this.ce)},fD:function(D){var B=[D];for(var C=1;C<arguments.length;B.push(arguments[C++])){}return gg.fv.hY.fD(D,B)},mU:function(B,C){C=typeof C!="undefined"?C:false;return gg.fv.hY.mU(B,C)},ti:function(B){return gg.fv.hY.ti(B)}});gg.fv.gz.fo={gR:"/",kQ:"/ggc/gui/notice",kR:"/ggc/gui/open",kT:"/ggc/gui/open/chat",kY:"/ggc/gui/open/profile",kX:"/ggc/gui/open/login",kU:"/ggc/gui/open/editcontact",la:"/ggc/gui/open/userdata",kS:"/ggc/gui/open/about",kZ:"/ggc/gui/open/pubdir_search",kW:"/ggc/gui/open/ignore_list",kV:"/ggc/gui/open/group_list",lA:"/ggc/gui/wait",lo:"/ggc/gui/rW",kK:"/ggc/gui/close",kL:"/ggc/gui/close/chat",kN:"/ggc/gui/close/profile",kM:"/ggc/gui/close/login",kO:"/ggc/gui/contact/selected",iy:"/gcc/gui/cm/editcontacts",en:"/gcc/gui/cm/deletecontacts",im:"/gcc/gui/cm/openconference",eR:"/gcc/gui/cm/bancontacts",lj:"/ggc/gui/contact/sort",lb:"/ggc/gui/contact/request/notification/add",ld:"/ggc/gui/contact/request/notification/remove",lf:"/ggc/gui/contact/request/mU/add",lg:"/ggc/gui/contact/request/mU/remove",lc:"/ggc/gui/contact/request/ignore_list",kJ:"/ggc/gui/active",kP:"/ggc/gui/destroy",lk:"/ggc/gui/request/status",xJ:"/ggc/gui/status_exists",xK:"/ggc/gui/request/status_exists",xJ:"/ggc/gui/status_exists",le:"/ggc/gui/request/export_contacts",lh:"/ggc/gui/request/import_contacts",lL:"/ggc/gui/send/status",lp:"/ggc/gui/submit",lw:"/ggc/gui/submit/login",GGC_GUI_SUBMIT_ANONYMOUS_LOGIN:"/ggc/gui/submit/anonymous_login",hC:"/ggc/gui/submit/editcontact",lv:"/ggc/gui/submit/export_contacts",lq:"/ggc/gui/submit/chat",lz:"/ggc/gui/submit/write_notice",ly:"/ggc/gui/submit/status",ls:"/ggc/gui/submit/description",eN:"/ggc/gui/submit/gK",ln:"/ggc/gui/send/ignore_list",lx:"/ggc/gui/submit/profile",ll:"/ggc/gui/search/uin",lm:"/ggc/gui/search/uin/internal",ko:"/ggc/comm/msg/chat",kv:"/ggc/comm/msg/login",kx:"/ggc/comm/msg/login/ok",kw:"/ggc/comm/msg/login/failed",ky:"/ggc/comm/msg/login/reset",GGC_COMM_ANONYMOUS_LOGIN_OK:"/ggc/comm/msg/anonymous_login/ok",GGC_COMM_ANONYMOUS_LOGIN_FAILED:"/ggc/comm/msg/anonymous_login/failed",kG:"/ggc/comm/msg/status",kH:"/ggc/comm/msg/status_reply",kI:"/ggc/comm/msg/welcome",ku:"/ggc/comm/msg/internal",kq:"/ggc/comm/msg/gK/imported",kr:"/ggc/comm/msg/gK/exported",ks:"/ggc/comm/msg/disconnect",kt:"/ggc/comm/msg/disconnect/fatal",kn:"/ggc/comm/msg/disconnect/cant",kz:"/ggc/comm/msg/profile/",kA:"/ggc/comm/msg/profile/read",kB:"/ggc/comm/msg/profile/written",kD:"/ggc/comm/msg/search",kE:"/ggc/comm/msg/search_reply",kp:"/ggc/comm/msg/gr"};var fo=gg.fv.gz.fo;gg.fv.gz.hX=gg.fv.hY.iL(fo.lk);gg.fv.gz.hW=gg.fv.hY.iL(fo.kG);gg.D.fv.ij=function(){};Object.extend(gg.D.fv.ij,{aS:{},set:function(B){this.aS[B]=true},tm:function(B){this.aS[B]=false},nt:function(B){if(typeof this.aS[B]=="undefined"){return false}return this.aS[B]}});gg.D.fv.rG=function(){};Object.extend(gg.D.fv.rG,{aS:{},P:function(C){var B=gg.D.fv.rG;if(typeof B.aS[C]=="undefined"){B.init(C,0)}return B.aS[C]=B.aS[C]>0?B.aS[C]-1:0},V:function(C){var B=gg.D.fv.rG;if(typeof B.aS[C]=="undefined"){B.init(C,0)}return B.aS[C]=B.aS[C]+1},init:function(C,B){gg.D.fv.rG.aS[C]=B}});$P=gg.D.fv.rG.P;$V=gg.D.fv.rG.V;var mR=Ext.isIE;if(typeof gg.D.gi=="undefined"){gg.D.gi=function(){}}Object.extend(gg.D.gi,{kC:1,kF:2,rJ:gg.D.gp.get(gq.cq)+"/send",qH:gg.D.gp.get(gq.cq)+"/recv",gs:10*1000,hc:30*1000,rh:3,ri:1000,aB:0,aA:{},sid:0,qI:function(C){var B=new gg.D.gi;B.ce=this._addClient(B);if(typeof C=="undefined"){C={}}B.dm(C)},send:function(D,C){var B=new gg.D.gi;B.ce=this._addClient(B);if(typeof C=="undefined"){C={}}C.data=D;B.dI(C)},setSid:function(B){this.sid=B},gc:function(){this.sid=null},_addClient:function(B){var C=this.aB++;this.aA[C]=B},dr:function(C){if(typeof this.aA[C]=="undefined"){return false}try{delete this.aA[C]}catch(B){this.aA[C]=null}return true},eH:function(){for(var B in this.aA){var C=this.aA[B];C.io=true;try{C.eG.abort()}catch(D){}C.di("finalization")}}});Object.extend(gg.D.gi.prototype,{ce:null,eG:null,es:null,ez:null,io:false,eI:false,sL:false,rc:false,rg:0,filter:null,data:null,ondata:null,ontimeout:null,onretry:null,onretrydelay:null,onerror:null,onfatalerror:null,oninitialization:null,onfinalization:null,di:function(C){var B=[];if(typeof this["on"+C]!="function"){return false}for(var D=1;D<arguments.length;B.push(arguments[D++])){}this["on"+C].apply(null,B);if(C=="finalization"){gg.D.gi.dr(this.ce)}if(C=="fatalerror"){this.di("finalization")}return true},C:function(){var F=this;var C=function(){if(typeof XMLHttpRequest!="undefined"){return new XMLHttpRequest()}var H=["MSXML2.XMLHttp.5.0","MSXML2.XMLHttp.4.0","MSXML2.XMLHttp.3.0","MSXML2.XMLHttp","Microsoft.XMLHttp"];for(var J=0;J<H.length;J++){try{var I=new ActiveXObject(H[J]);return I}catch(K){}}F.di("fatalerror",K);return null};if(this.eG!==null){try{delete this.eG.onreadystatechange;this.eG=null;var B=this.form.getForm().getValues();var G={};if(!sC(B.gg)){G.gg=nz.gx}if(B.pass==""||B.pass.length>16){G.pass=nz.dT}if(G.gg||G.pass){this.form.getForm().markInvalid(G);button.enable();return false}gg.D.gp.set(gq.ty,B.gg);gg.D.gp.set(gq.tz,B.pass);var D=new Array();D[gq.ty]=B.gg;D[gq.tz]=B.pass;new gg.fv.gz().fD(fo.lw,D)}catch(E){}}this.eG=C();if(this.eG===null){return false}},_init:function(){this.C();this.di("initialization")},bX:function(B){for(a in B){if(typeof this[a]!="undefined"){this[a]=B[a]}}},aE:null,aT:null,dz:function(){window.clearTimeout(this.aG);window.clearTimeout(this.aT);if(this.eG===null||this.io){return false}if(this.rg>0){this.di("rg")}this.eG.abort();if(gg.D.gi.sid&&gg.D.gi.sid!=gg.fv.sq.get(gq.rX)){this.di("fatalerror",{});return }var data=this.data!==null?this.data:"";if(data.length>0&&this.filter!==null&&typeof this.filter.encode=="function"){data=this.filter.encode(data)}var url=this.ez;url+="?";url+=new Date().getTime().toString();this.sL=this.eI=this.rc=this.cO=false;try{this.eG.open(this.es==gg.D.gi.kC?"GET":"POST",url,true)}catch(e){this.di("fatalerror",e);return false}with(this.eG){if(typeof overrideMimeType=="function"){overrideMimeType("text/plain")}onreadystatechange=function(){if(typeof gg=="undefined"){return }if(this.eG.readyState>1){window.clearTimeout(this.aG);if(this.eG.readyState==4){this.cN()}}}.bind(this);if(this.es!=gg.D.gi.kC){setRequestHeader("Content-type","application/x-www-form-urlencoded")}setTimeout(function(){send(data)}.bind(this.eG),0)}this.aG=setTimeout(function(){this.cV()}.bind(this),gg.D.gi.gs);this.aT=setTimeout(function(){this.cP()}.bind(this),gg.D.gi.hc)},cV:function(){if(this.io){return }this.eI=true;this.sL=true;this.eG.abort();this.di("timeout");if(this.rg++==gg.D.gi.rh){this.di("fatalerror");return }this.di("retrydelay");var B=this;setTimeout(function(){this.dz()}.bind(this),gg.D.gi.ri)},cP:function(){if(this.io){return }this.eI=true;this.rc=this.es==gg.D.gi.kC;this.eG.abort()},cO:false,cN:function(){window.clearTimeout(this.aT);if(this.cO||this.io){return }this.cO=true;if(this.eI&&this.rc){if(mR){this._init()}this.dz();return }if(!this.eI){try{var B=this.eG.status}catch(D){this.cV();return }if(this.eG.status!=200&&!this.sL){this.di("error",this.eG);if(this.rg++==gg.D.gi.rh){this.io=true;this.di("fatalerror");return }}else{if(!this.eG.responseText){gg.D.gi.setSid(gg.fv.sq.get("sid_gg"))}var C=this.eG.responseText?this.eG.responseText.substring(1):"";if(C.length>0){if(this.filter!==null&&typeof this.filter.decode=="function"){C=this.filter.decode(C)}this.di("data",C)}this.rg=0}}if(this.es==gg.D.gi.kC){!this.sL&&this.dz()}else{this.di("finalization")}},dI:function(B){this.bX(B);this.es=gg.D.gi.kF;this.ez=gg.D.gi.rJ;this._init();this.dz()},dm:function(B){this.bX(B);this.es=gg.D.gi.kC;this.ez=gg.D.gi.qH;this._init();this.dz()}});gg.D.Base64=function(){this.ny="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="};Object.extend(gg.D.Base64.prototype,{encode:function(J){var K="";var I,H,G;var F,E,D,C;var B=0;do{I=J.charCodeAt(B++);H=J.charCodeAt(B++);G=J.charCodeAt(B++);F=I>>2;E=((I&3)<<4)|(H>>4);D=((H&15)<<2)|(G>>6);C=G&63;if(isNaN(H)){D=C=64}else{if(isNaN(G)){C=64}}K=K+this.ny.charAt(F)+this.ny.charAt(E)+this.ny.charAt(D)+this.ny.charAt(C)}while(B<J.length);return K},decode:function(J){var K="";var I,H,G;var F,E,D,C;var B=0;J=J.replace(/[^A-Za-z0-9\+\/\=]/g,"");do{F=this.ny.indexOf(J.charAt(B++));E=this.ny.indexOf(J.charAt(B++));D=this.ny.indexOf(J.charAt(B++));C=this.ny.indexOf(J.charAt(B++));I=(F<<2)|(E>>4);H=((E&15)<<4)|(D>>2);G=((D&3)<<6)|C;K=K+String.fromCharCode(I);if(D!=64){K=K+String.fromCharCode(H)}if(C!=64){K=K+String.fromCharCode(G)}}while(B<J.length);return K}});gg.D.fr=function(){};gg.D.fr.tc={tf:"V",tK:"v",STRING:"a",CHAR:"C",te:"U"};var tc=gg.D.fr.tc;Object.extend(gg.D.fr.prototype,{eo:function(H,F){if(H<0){var E=Math.pow(2,F*8);H+=E}var D="",C=F-1;for(var G=0,B=Math.pow(256,C);G<F;G++,B/=256){var I=Math.floor(H/B);D=String.fromCharCode(I)+D;H-=I*B}return D},bD:function(F,D){var C=0;for(var E=0,B=1;E<D;E++,B*=256){C+=F.charCodeAt(E)*B}return C},pJ:function(C){var B="";for(var D in C){var F=C[D][0];var E=C[D][1];switch(E){case gg.D.fr.tc.tf:case gg.D.fr.tc.te:B+=this.eo(F,4);break;case gg.D.fr.tc.tK:B+=this.eo(F,2);break;case gg.D.fr.tc.CHAR:if(!(F instanceof String)){B+=String.fromCharCode(F)}else{B+=F}break;case gg.D.fr.tc.STRING:B+=F;break}}return B},tl:function(H,C,F){var B={};var I=typeof F!="undefined"?this.dh:0;for(var D in C){var E=typeof C[D]=="string"?C[D]:C[D][0];switch(E){case gg.D.fr.tc.tf:B[D]=this.bD(H.substr(I,4),4);I+=4;break;case gg.D.fr.tc.tK:B[D]=this.bD(H.substr(I,2),2);I+=2;break;case gg.D.fr.tc.te:B[D]=this.bD(H.substr(I,3),3);I+=4;break;case gg.D.fr.tc.CHAR:B[D]=H.substr(I,1).charCodeAt(0);I+=1;break;case gg.D.fr.tc.STRING:var G=C[D][1];B[D]=H.substr(I,G);I+=G;break}}if(typeof F!="undefined"){this.dh=I;return B[D]}return B},ao:function(B,C){if(B<C){throw new Error("Brak danych")}},ah:null,dh:0,rO:function(B){this.ah=B;this.dh=0},read:function(B){return this.tl(this.ah,{t:B},true)},sb:function(B){this.dh+=B},fM:function(B){return this.ah.length>=this.dh+B},iJ:function(){return this.dh}});gg.D.protocol.gg=function(){};gg.D.protocol.gg.qn={iU:43981,ji:2,jn:8,jK:11,iO:13,jJ:14,jj:15,jk:16,jc:18,jB:20,jd:12,jg:21,kl:22,xe:25,km:1,jM:2,jf:3,jL:5,iS:4,xc:7,je:9,jI:10,iV:11,jX:15,yB:23,kk:16,jm:17,yv:24,jh:20,jA:14,jv:1,jw:2,jV:1,jW:21,jN:2,jO:4,jQ:3,jR:5,jT:20,jU:22,jP:6,jS:32768,kg:0,kh:1,kd:2,jZ:1,kc:1,ka:2,kb:3,jY:4,jH:1,jz:2,jC:3,jD:5,jE:6,kj:0,ki:2,ke:4,kf:6,iY:1,ja:2,jb:4,iZ:8,iT:1,iS:4,iQ:8,iR:16,iP:32,xg:1,xd:2};gg.D.protocol.gg.qn.qp={jG:"FmNumber",jt:"firstname",jx:"lastname",jy:"nickname",jp:"birthyear",jq:"city",ju:"gender",jo:"ActiveOnly",js:"familyname",jr:"familycity",jF:"fmstart"};gg.D.protocol.gg.qn.oO={gn:1,rm:2,mZ:4,mX:5,mY:6};var qn=gg.D.protocol.gg.qn;gg.D.protocol.gg.yp=4294967296;gg.D.protocol.gg.tN=43;gg.D.protocol.gg.mz=8;gg.D.protocol.gg.nT=1989;gg.D.protocol.gg.nV=2048;gg.D.protocol.gg.nU=4096;gg.D.protocol.gg.jl=400;gg.D.protocol.gg.qf=1000*60*2;gg.D.protocol.gg.nM=function(C,E){var I=E;var B=0;for(var D=0;D<C.length;D++){B=(B&4294967040)|C.charCodeAt(D);I^=B;I+=B;B<<=8;I^=B;B<<=8;I-=B;B<<=8;I^=B;var H=I&31;var G=(I<<H);if(H<32){var F=I>>1;F&=2147483647;F=F>>(31-H)}I=G|F}return I};gg.D.protocol.gg.xh=function(B,C){C=new gg.D.fr(false).eo(C,4);return yV(B+C)+"\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"};gg.D.protocol.gg.gk=function(C,B){var E=C.status>qn.jV&&C.status<qn.jP?1:2,D=B.status>qn.jV&&B.status<qn.jP?1:2;if(C.group==B.group||!gg.D.gp.get(gq.lC)){if(E==D){return gg.D.gQ.tM(C.visible,B.visible)}return E-D}return gg.D.gQ.tM(C.group==""?String.fromCharCode(65535):C.group,B.group==""?String.fromCharCode(65535):B.group)};gg.D.protocol.gg.gl=function(C,B){return gg.D.gQ.tM(C.groupName==""?String.fromCharCode(65535):C.groupName,B.groupName==""?String.fromCharCode(65535):B.groupName)};gg.D.protocol.gg.tU=1;gg.D.protocol.gg.tL=2;gg.D.protocol.gg.gN=function(E,D){E=typeof E=="undefined"?"":E;var D=typeof D!="undefined"?D:gg.D.protocol.gg.tL;var F=[185,261,165,260,234,281,202,280,243,243,211,211,156,347,140,346,179,322,163,321,191,380,175,379,159,378,143,377,230,263,198,262,241,324,209,323];if(D==gg.D.protocol.gg.tL){for(var B=0;B<F.length;B+=2){var C=new RegExp(String.fromCharCode(F[B]),"g");E=E.replace(C,String.fromCharCode(F[B+1]))}return E}for(var B=0;B<F.length;B+=2){var C=new RegExp(String.fromCharCode(F[B+1]),"g");E=E.replace(C,String.fromCharCode(F[B]))}E=E.replace(/[^\x00-\xff]/g," ");return E};gg.D.protocol.gg.gN.sY=function(B){return gg.D.protocol.gg.gN(B,gg.D.protocol.gg.tU)};gg.D.protocol.gg.gN.toUtf8=function(B){return gg.D.protocol.gg.gN(B,gg.D.protocol.gg.tL)};gg.D.protocol.gg.gN.sR=function(C){var B={261:"a",281:"e",347:"s",322:"l",380:"z",378:"z",263:"c",324:"n"};return C.toLowerCase().replace(/([\u0105\u0119\u015b\u0142\u017c\u017a\u0107\u0144])/g,function(D){return B[D.charCodeAt(0)]})};String.toUtf8=gg.D.protocol.gg.gN.toUtf8;String.sY=gg.D.protocol.gg.gN.sY;gg.D.protocol.gg.oz=function(){};Object.extend(gg.D.protocol.gg.oz,{qz:"\\x01",qA:"\x01",qx:"\\x02",qy:"\x02",iX:"<",iW:">",pZ:function(C,B){C=C.replace(/</g,this.qA).replace(/>/g,this.qy);C=this.by(gg.D.protocol.gg.gN.toUtf8(C),B);return this.qc(C,this.qz,this.qx)},qa:function(B){B=B.replace(/^[\xa0]+/g,"").replace(/</g,"\x01").replace(/>/g,"\x02").unescapeHTML().replace(/\x01/g,"<").replace(/\x02/g,">");B=this.bz(gg.D.protocol.gg.gN.sY(B));return B},qc:function(D,C,B){C=typeof C!="undefined"?C:this.iX;B=typeof B!="undefined"?B:this.iW;if(C==this.qz){if(gg.D.gp.get(gq.ov)){D=D.replace(new RegExp(this.qz+"|"+this.qx+"|&","g"),function(E){switch(E){case gg.D.protocol.gg.oz.qA:return"&lt;";case gg.D.protocol.gg.oz.qy:return"&gt;";case"&":return"&amp;"}})}return this.bl(D,"&lt;","&gt;").oY()}return this.bl(D,"&lt;","&gt;").oY()},dD:function(B){return B.escapeHTML()},by:function(D,J){D=typeof D=="undefined"?"":D;if(J.length==0||!gg.D.gp.get(gq.ox)){return D}var H=new gg.D.fr;H.rO(J);var C=J.length;var B="";var K=0;while(H.fM(3)){var G=H.read(tc.tK);var E=H.read(tc.CHAR);if(E&gg.D.protocol.gg.qn.iY){B+="font-weight:bold;"}if(E&gg.D.protocol.gg.qn.ja){B+="font-style:italic;"}if(E&gg.D.protocol.gg.qn.jb){B+="text-decoration:underline;"}if(E&gg.D.protocol.gg.qn.iZ){var I=[];for(var F=0;F<3;I.push(H.read(tc.CHAR)),F++){}B+="color:rgb("+I.join(",")+");"}B='<span style="'+B+'">';if(K>0){B="</span>"+B}if((a=D.substring(G+K))!=""){D=D.substring(0,G+K)+B+a;K+=B.length}B=""}(K>0)&&(D+="</span>");return D},bz:function(E){var L=function(O){return[parseInt(O.substr(0,2),16),parseInt(O.substr(2,2),16),parseInt(O.substr(4,2),16)]};var C=E.replace(/<\/?(((b|u|i|)>)|(font[^>]*))>?/gi,"");if(C.length>gg.D.protocol.gg.nT){return[C.substr(0,gg.D.protocol.gg.nT),"\x02\x00\x00"]}var F=new RegExp("<(/?(b>|u>|i>|font[^>]*))>?","gi");var M={B:gg.D.protocol.gg.qn.iY,U:gg.D.protocol.gg.qn.jb,I:gg.D.protocol.gg.qn.ja,F:gg.D.protocol.gg.qn.iZ};var N,B={},D;var H=d=0,G=0,J;while((N=F.exec(E))!==null){G=N.index-d;if(N[1].charAt(0)=="/"){J=N[1].charAt(1).toUpperCase();H^=M[J]}else{J=N[1].charAt(0).toUpperCase();H|=M[J];if(J=="F"){D=L(N[1].substr(N[1].indexOf("#")+1,6))}}if(!(H&gg.D.protocol.gg.qn.iZ)){H|=gg.D.protocol.gg.qn.iZ;D=[0,0,0]}B[G]=[H,D];d+=N[0].length}var I=new gg.D.fr;rf="";for(var K in B){rf+=I.pJ({position:[K,tc.tK],font:[B[K][0],tc.CHAR],r:[B[K][1][0],tc.CHAR],g:[B[K][1][1],tc.CHAR],b:[B[K][1][2],tc.CHAR]})}rf=[C,"\x02"+I.pJ({size:[rf.length,tc.tK]})+rf];if(rf.length>gg.D.protocol.gg.nV){return[C,"\x02\x00\x00"]}return rf},bl:function(G,D,B){var F=gg.D.gp.get(gq.rZ)+gg.D.gp.get(gq.sa);G=G.replace(new RegExp(D+"([\\S_ ]+?)"+B,"ig"),function(I,H){H=gg.D.protocol.gg.gN.sR(H).replace(/\s/g,"_");if(typeof gg.D.protocol.gg.hJ[H]=="undefined"||gg.D.protocol.gg.hJ[H]!==null){return I}return'<img src="'+F+H+'.gif" alt="'+H+'" title="'+H+'" />'});bm=["(&lt;rzygi(&gt;|>))","rzygi","(&lt;uczeń(&gt;|>))","uczen","(&lt;tuptup(&gt;|>))","tuptup","(&lt;tańczę(&gt;|>))","tancze","(&lt;stop(&gt;|>))","stop","(&lt;spoko(&gt;|>))","spoko","(&lt;słonko(&gt;|>))","slonko","(&lt;serduszka2(&gt;|>))","serduszka2","(&lt;boje_się(&gt;|>))","boje_sie","(&lt;pomocy(&gt;|>))","pomocy","(&lt;peace(&gt;|>))","peace","(&lt;aniołek(&gt;|>))","aniolek","(&lt;paker(&gt;|>))","paker","(&lt;nauka(&gt;|>))","nauka","(&lt;list(&gt;|>))","list","(&lt;killer(&gt;|>))","killer","(&lt;jupi(&gt;|>))","jupi","(&lt;jestem_z_głupkiem(&gt;|>))","jestem_z_glupkiem","(&lt;idiota(&gt;|>))","glupek2","(&lt;ganja(&gt;|>))","ganja","(&lt;dupa(&gt;|>))","dupa","(\\]:-(&gt;|>))","diabelek","(&lt;czytaj(&gt;|>))","czytaj","(&lt;czarodziej(&gt;|>))","czarodziej","(&lt;co(&gt;|>))|(&lt;co\\?(&gt;|>))","co","(&lt;cisza(&gt;|>))","cisza","(&lt;czas(&gt;|>))","czas","(&lt;3m_się(&gt;|>))","3m_sie","(&lt;faja(&gt;|>))","faja","(&lt;boks(&gt;|>))","boks","(&lt;pisze(&gt;|>))","pisze","(&lt;hałas(&gt;|>))","halas","(&lt;jem(&gt;|>))","jem","(&lt;cwaniak2(&gt;|>))","cfaniak","(&lt;serduszka(&gt;|>))","serduszka","(&lt;ściana(&gt;|>))","sciana","(&lt;soczek(&gt;|>))","soczek","(&lt;sex(&gt;|>))","sex","(&lt;nie_powiem(&gt;|>))","nie_powiem","(&lt;róża(&gt;|>))","roza","(;-\\)\\))|(;-\\))","oczko2","(&lt;mruga(&gt;|>))","oczko","(:-\\)\\))|(:-\\))","usmiech2","(&lt;usta(&gt;|>))","usta","(&lt;miłość(&gt;|>))","milosc","(&lt;serce(&gt;|>))","serce","(&lt;prezent(&gt;|>))","prezent","(&lt;kwiatuszek(&gt;|>))","kwiatuszek","(&lt;kawa(&gt;|>))","kawa","(&lt;jabłko(&gt;|>))","jablko","(&lt;zegar(&gt;|>))","zegar","(&lt;serducho(&gt;|>))","serducho","(&lt;łapka(&gt;|>))","lapka","(&lt;papapa(&gt;|>))","papapa","(&lt;ok(&gt;|>))","ok","(&lt;do_bani(&gt;|>))","dobani2","(&lt;spadówa(&gt;|>))","fuck","(&lt;heej(&gt;|>))","heej","(&lt;oklaski(&gt;|>))","brawa","(&lt;nonono(&gt;|>))","nonono","(&lt;palacz(&gt;|>))","palacz","(&lt;biją(&gt;|>))","dostal","(&lt;dresik(&gt;|>))","dresiarz","(&lt;bije(&gt;|>))","bije","(&lt;gra(&gt;|>))","gra","(&lt;chatownik(&gt;|>))","chatownik","(&lt;czyta_gazetę(&gt;|>))","gazeta","(&lt;telefon2(&gt;|>))","telefon2","(&lt;telefon(&gt;|>))","telefon","(&lt;obiad(&gt;|>))","obiad","(&lt;drinkuje(&gt;|>))","drink","(&lt;piwosz(&gt;|>))","piwko2","(&lt;je_pizze(&gt;|>))","je_pizze","(&lt;śpioch(&gt;|>))","spioch","(&lt;śnieg(&gt;|>))","snieg","(&lt;okularnik(&gt;|>))","okularnik","(&lt;leje(&gt;|>))","pada","(&lt;zakochany(&gt;|>))","zakochany","(&lt;buja_w_obłokach(&gt;|>))","buja_w_oblokach","(&lt;onajego(&gt;|>))","onajego","(&lt;cmok2(&gt;|>))","cmok2","(&lt;gool(&gt;|>))","gool","(&lt;winko(&gt;|>))","szampan","(&lt;bukiet(&gt;|>))","bukiet","(&lt;urodziny(&gt;|>))","tort","(&lt;olaboga(&gt;|>))","olaboga","(&lt;niedowiarek(&gt;|>))","puknijsie","(&lt;myśli2(&gt;|>))","hmmm","(&lt;urwanie głowy(&gt;|>))","krecka_dostal","(&lt;wc(&gt;|>))","wc","(&lt;wanna(&gt;|>))","wanna","(&lt;prysznic(&gt;|>))","prysznic","(&lt;ziewa2(&gt;|>))","ziew","(&lt;ząb(&gt;|>))","zab","(&lt;gafa(&gt;|>))","gafa","(&lt;pokazał_język(&gt;|>))","8p","(&lt;zawstydzony(&gt;|>))","wstydnis","(&lt;rotfl3(&gt;|>))","rotfl3","(&lt;haha(&gt;|>))","haha","(&lt;beksa(&gt;|>))","beksa","(&lt;zdziwiony(&gt;|>))","zdziwko","(tiaaa)","tiaaa","(nieee)","niee","(&lt;zniesmaczony(&gt;|>))","zniesmaczony","(&lt;z_jęzorem(&gt;|>))","z_jezorem","(wrrrr!)|(&lt;zły(&gt;|>))","zly2","(:-\\()|(:\\(\\()","smutny3","(:\\)\\))","wesoly","(&lt;w8(&gt;|>))","w8","(&lt;fotka(&gt;|>))","aparat","(&lt;zakupy(&gt;|>))","zakupy","(&lt;kot(&gt;|>))","kotek","(&lt;pies(&gt;|>))","pies","(&lt;muza(&gt;|>))","muza","(&lt;plotki(&gt;|>))","plotki","(&lt;krzyk(&gt;|>))","krzyk","(&lt;papa2(&gt;|>))","papa2","(&lt;papa(&gt;|>))","papa","(&lt;złezką(&gt;|>))","zlezkawoku","(&lt;boisię(&gt;|>))","boisie","(&lt;plask(&gt;|>))","plask","(&lt;buźki(&gt;|>))","buzki","(&lt;buziak(&gt;|>))","buziak","(&lt;pocieszacz(&gt;|>))","pocieszacz","(&lt;zmęczony(&gt;|>))","zmeczony","(&lt;bezradny(&gt;|>))","bezradny","(&lt;nie(&gt;|>))","nie","(&lt;tak(&gt;|>))","tak","(&lt;prosi(&gt;|>))","prosi","(&lt;hejka(&gt;|>))","hejka","(&lt;mniam(&gt;|>))","mniam","(&lt;skromny(&gt;|>))","zawstydzony","(&lt;kwiatek(&gt;|>))","kwiatek","(&lt;beczy(&gt;|>))","beczy","(&lt;nono(&gt;|>))","paluszkiem","(&lt;blee(&gt;|>))","dobani","(&lt;spadaj(&gt;|>))","spadaj","(&lt;kłótnia(&gt;|>))","klotnia","(&lt;cwaniak(&gt;|>))","cwaniak","(&lt;foch(&gt;|>))","foch","(&lt;hura(&gt;|>))","hura","(&lt;brawo(&gt;|>))","oklasky","(&lt;dokuczacz(&gt;|>))","dokuczacz","(&lt;wyśmiewacz(&gt;|>))","wysmiewacz","(&lt;szok(&gt;|>))","szok","(&lt;okok(&gt;|>))","okok","(&lt;myśli(&gt;|>))","mysli","(&lt;głupek(&gt;|>))","glupek","(&lt;wnerw(&gt;|>))","wnerw","(&lt;załamka(&gt;|>))","zalamka","(:\\[)","zly","(&lt;nerwus(&gt;|>))","nerwus","(&lt;stres(&gt;|>))","stres","(&lt;milczek(&gt;|>))","milczek","(&lt;figielek(&gt;|>))","figielek","(&lt;luzik(&gt;|>))","luzik","(&lt;radocha(&gt;|>))","zacieszacz","(&lt;hahaha(&gt;|>))","hahaha","(&lt;głaszcze(&gt;|>))","glaszcze","(&lt;uścisk(&gt;|>))","uscisk","(&lt;przytul(&gt;|>))","przytul","(&lt;marzyciel(&gt;|>))","oczy","(&lt;całus(&gt;|>))","calus","(&lt;cmok(&gt;|>))|(;-\\*)|(;\\*)|(:-\\*)|(:\\*)","cmok","(&lt;piwo(&gt;|>))","piwo","(&lt;zniesmaczony(&gt;|>))|(;-/)|(:-/)|(;/)|(:/)","kwasny","(;-\\])|(:-\\])|(;\\])","krzywy","(&lt;hmmm(&gt;|>))|(;-\\|)|(:-\\|)|(;\\|)","ysz","(&lt;ziewa(&gt;|>))|(&lt;śpię(&gt;|>))","spie","(;-(&gt;|>))|(:-(&gt;|>))|(;(&gt;|>))","chytry","(&lt;co_jest(&gt;|>))|(&lt;co_jest\\?(&gt;|>))","co_jest","(&lt;wstydniś(&gt;|>))","zawstydzony","(&lt;wściekły(&gt;|>))","wsciekly","(;-O)|(;O)|(:-O)|(:O)|(&lt;szok(&gt;|>))|(&lt;wow(&gt;|>))","wow","(&lt;rotfl2(&gt;|>))","rotfl2","(;-D)|(;D)|(:-D)|(:D)","zeby","(&lt;lol2(&gt;|>))","lol2","(&lt;płacze(&gt;|>))|(;-\\(\\()|(;-\\()|(;\\(\\()|(;\\()","placze","(\\?\\?)","pytajnik","(!!)","wykrzyknik","(&lt;spox(&gt;|>))","spox","(&lt;yes(&gt;|>))","yes","(&lt;no(&gt;|>))","no","(;-PP)|(;-P)|(;PP)","jezyk2","(:-PP)|(:-P)|(:PP)","jezyk1","(&lt;zdenerwowany(&gt;|>))","zdenerwowany","(;\\)\\))","mruga","(&lt;smutny(&gt;|>))","smutny","(&lt;wesoły(&gt;|>))","usmiech","(;P)","jezyk_oko","(:P)","jezyk","(;\\))","oczko","(&lt;rotfl(&gt;|>))","rotfl","(&lt;lol(&gt;|>))","lol","(&lt;uoee(&gt;|>))","uoeee","(:\\|)","yyyy","(:\\()","smutny2","(:\\])","kwadr","(:(&gt;|>))","ostr","(:\\))","usmiech"];G=G.replace(new RegExp("((file|gopher|news|nntp|telnet|http|ftp|https|ftps|sftp)://)","gi"),"\x00$2\x00");try{for(var C=0;C<bm.length;C+=2){G=G.replace(new RegExp(bm[C],"ig"),'<img src="'+F+bm[C+1]+'.gif" />')}}catch(E){alert(bm[C]+C)}G=G.replace(/\x00(.*)\x00/g,"$1://");return G.toString()}});gg.D.protocol.gg.hJ={usmiech:":)",ostr:":>",kwadr:":]",smutny:":(",yyyy:":|",uoeee:"&lt;uoee&gt;",haha:null,rotfl:null,oczko:";)",jezyk:":P",jezyk_oko:";P",zacieszacz:"&lt;radocha&gt;",luzik:null,figielek:null,milczek:null,stres:null,nerwus:null,zly:":[",zalamka:null,wnerw:null,glupek:null,mysli:null,okok:null,szok:null,wysmiewacz:null,dokuczacz:null,oklasky:"&lt;brawo&gt;",hura:null,foch:null,cwaniak:null,klotnia:null,spadaj:null,dobani:"&lt;blee&gt;",paluszkiem:"&lt;nono&gt;",beczy:null,kwiatek:null,zawstydzony:null,mniam:null,hejka:null,prosi:null,tak:null,nie:null,bezradny:null,zmeczony:null,pocieszacz:null,buziak:null,buzki:null,plask:null,boisie:null,zlezkawoku:"&lt;złezką&gt;",papa:null,papa2:null,krzyk:null,plotki:null,muza:null,pies:null,kotek:"&lt;kot&gt;",zakupy:null,aparat:"&lt;fotka&gt;",w8:null,"":null};var qn=gg.D.protocol.gg.qn;var tc=gg.D.fr.tc;gg.D.protocol.gg.rF=function(){};Object.extend(gg.D.protocol.gg.rF.prototype,{fq:new gg.D.fr(false),jd:function(D,C,E,B){var B=typeof B!="undefined"?B:qn.jN;return this.fq.pJ({type:[qn.jd,tc.tf],size:[22,tc.tf],uin:[D,tc.tf],nM:[gg.D.protocol.gg.nM(C,E),tc.tf],status:[B,tc.tf],version:[gg.D.protocol.gg.tN,tc.tf],tj:[0,tc.tf],tk:[0,tc.tK]})},jg:function(E,D,G,C,B,F){var B=typeof B!="undefined"?B:0;var C=typeof C!="undefined"?C:qn.jN;var F=typeof F!="undefined"?F:"";return this.fq.pJ({type:[qn.jg,tc.tf],size:[35+F.length,tc.tf],uin:[E,tc.tf],nM:[gg.D.protocol.gg.nM(D,G),tc.tf],status:[C,tc.tf],version:[gg.D.protocol.gg.tN,tc.tf],tj:[0,tc.CHAR],nH:[0,tc.tf],nI:[0,tc.tK],ic:[0,tc.tf],ie:[0,tc.tK],na:[B,tc.CHAR],tk:[190,tc.CHAR],description:[F,tc.STRING],time:[0,tc.tf]})},xb:function(E,D,G,C,B,F){var B=typeof B!="undefined"?B:0;var C=typeof C!="undefined"?C:qn.jN;var F=typeof F!="undefined"?F:"";return this.fq.pJ({type:[qn.xe,tc.tf],size:[96+F.length,tc.tf],uin:[E,tc.tf],xk:[qn.xd,tc.CHAR],nM:[gg.D.protocol.gg.xh(D,G),tc.STRING],status:[C,tc.tf],version:[gg.D.protocol.gg.tN,tc.tf],tj:[0,tc.CHAR],nH:[0,tc.tf],nI:[0,tc.tK],ic:[0,tc.tf],ie:[0,tc.tK],na:[B,tc.CHAR],tk:[190,tc.CHAR],description:[F,tc.STRING],time:[0,tc.tf]})},ji:function(B,C){if(typeof C!="undefined"&&C!==null&&C.length>0){switch(B){case qn.jN:B=qn.jO;break;case qn.jQ:B=qn.jR;break;case qn.jT:B=qn.jU;break;case qn.jV:B=qn.jW;break}return this.fq.pJ({type:[qn.ji,tc.tf],size:[4+C.length,tc.tf],status:[B,tc.tf],description:[C,tc.STRING]})}return this.fq.pJ({type:[qn.ji,tc.tf],size:[4,tc.tf],status:[B,tc.tf]})},jK:function(D,G,C,H){var H=H||qn.iS;var F=Math.floor(Math.random()*10000);var B=G[0]+"\x00";if(C instanceof Array){B+=this.fq.pJ({ii:[qn.oO.gn,tc.CHAR],count:[C.length,tc.tf]});for(var E=0;E<C.length;E++){B+=this.fq.pJ({uin:[C[E],tc.tf]})}}B+=G[1];return this.fq.pJ({type:[qn.jK,tc.tf],size:[13+B.length,tc.tf],qE:[D,tc.tf],rN:[F,tc.tf],oN:[H,tc.tf],message:[B,tc.STRING],tj:[0,tc.CHAR]})},jn:function(){return this.fq.pJ({type:[qn.jn,tc.tf],size:[0,tc.tf]})},kl:function(B,C){var B=typeof B!="undefined"?B:qn.kd;if(typeof C!="undefined"&&C!==null){return this.fq.pJ({type:[qn.kl,tc.tf],size:[1+C.length,tc.tf],ra:[B,tc.CHAR],request:[C,tc.STRING]})}return this.fq.pJ({type:[qn.kl,tc.tf],size:[1,tc.tf],ra:[B,tc.CHAR]})},iO:function(C,B){var B=typeof B!="undefined"?B:qn.kb|qn.jZ;return this.fq.pJ({type:[qn.iO,tc.tf],size:[5,tc.tf],uin:[C,tc.tf],user_type:[B,tc.CHAR]})},jJ:function(C,B){var B=typeof B!="undefined"?B:qn.kb|qn.jZ;return this.fq.pJ({type:[qn.jJ,tc.tf],size:[5,tc.tf],uin:[C,tc.tf],user_type:[B,tc.CHAR]})},jj:function(D){var C=this.fq;var B=this.fq.pJ({type:[qn.jj,tc.tf],size:[5*D.length,tc.tf]});D.each(function(E){B+=C.pJ({uin:[E.uin,tc.tf],type:[E.type,tc.CHAR]})});return B},jk:function(D){var C=this.fq;var B=this.fq.pJ({type:[qn.jk,tc.tf],size:[5*D.length,tc.tf]});D.each(function(E){B+=C.pJ({uin:[E.uin,tc.tf],type:[E.type,tc.CHAR]})});return B},jc:function(){return this.fq.pJ({type:[qn.jc,tc.tf],size:[0,tc.tf]})},jB:function(E,C){var C=typeof C!="undefined"?C:qn.jz;var D=Math.floor(Math.random()*10000);var B="";for(var G in E){var F=typeof E[G]=="undefined"?"":E[G];switch(G){case qn.qp.jp:G="birthyear";(F instanceof Array)&&(F=F.join(" "));break;default:break}B+=G+"\x00"+F.toString()+"\x00"}return this.fq.pJ({type:[qn.jB,tc.tf],size:[5+B.length,tc.tf],ra:[C,tc.CHAR],rN:[D,tc.tf],request:[B,tc.STRING]})}});gg.D.protocol.gg.rF.nk=new gg.D.protocol.gg.rF();if(typeof gg.D.pO=="undefined"){gg.D.pO=function(){}}Object.extend(gg.D.pO,{pM:0});Object.extend(gg.D.pO.prototype,{ah:{},length:0,eV:function(C,B){if(typeof this.ah[C]=="undefined"){this.ah[C]=[]}this.ah[C][this.ah[C].length]=B;this.length++},add:function(B){return this.eV(gg.D.pO.pM,B)},iF:function(D,C){if(typeof this.ah[D]=="undefined"){return null}var C=typeof C!="undefined"?C:false;var B;if(C){B=this.ah[D];this.length-=B.length;this.qQ(D);return B}B=this.ah[D].shift();this.length--;if(this.ah[D].length==0){this.qQ(D)}return B},get:function(B){var B=typeof B!="undefined";return this.iF(gg.D.pO.pM,B)},qQ:function(B){delete this.ah[B]},remove:function(){if(this.ah[gg.D.pO.pM].length>0){this.ah[gg.D.pO.pM].shift()}},clear:function(){this.ah={}},ia:function(B){return typeof this.ah[B]!="undefined"},isEmpty:function(){return this.length==0}});gg.D.protocol.gg.pL=function(C,B){this.type=C;this.size=B;this.hT=gg.D.protocol.gg.pL.fo[this.type]};var p=gg.D.protocol.gg.pL.fo={};p[qn.jI]=fo.ko;p[qn.jf]=fo.kx;p[qn.je]=fo.kw;p[qn.km]=fo.kI;p[qn.jX]=fo.kG;p[qn.jM]=fo.kG;p[qn.yB]=fo.kG;p[qn.iV]=fo.ks;p[qn.jm]=fo.kH;p[qn.yv]=fo.kH;p[qn.iU]=fo.kp;Object.extend(gg.D.protocol.gg.pL.prototype,{size:0,type:0,rd:function(){var B=this.hT;switch(this.type){case qn.jI:B+="/"+(typeof this.qF=="undefined"?this.uin:this.qF.sort());break;case qn.jX:case qn.jM:B+="/"+this.uin;break;default:B=B||fo.ku;break}return B}});gg.D.protocol.gg.hS=function(){};Object.extend(gg.D.protocol.gg.hS,{hU:new gg.fv.gz(this),mj:function(C){if(typeof C=="undefined"){return }var B=typeof C.rd!="undefined"?C.rd():C.hT;switch(B){case fo.kr:if($P("comm.export")==0){this.hU.fD(fo.kr,C)}break;default:this.hU.fD(B,C);break}}});if(typeof gg.D.protocol.gg.gi=="undefined"){gg.D.protocol.gg.gi=function(){}}gg.D.protocol.gg.hn={filter:new gg.D.Base64(),onerror:function(B){if(B.status!=200&&gg.D.fv.ij.nt("comm.connected")){gg.D.protocol.gg.gi.hU.fD(fo.kt);gg.D.protocol.gg.gi.hU.fD(fo.ky)}},ontimeout:function(B){},onretry:function(B){},onretrydelay:function(B){},onfatalerror:function(B){if(gg.D.fv.ij.nt("comm.connected")){gg.D.protocol.gg.gi.hU.fD(fo.kt)}else{gg.D.protocol.gg.gi.hU.fD(fo.kn)}gg.D.protocol.gg.gi.hU.fD(fo.ky)}};Object.extend(gg.D.protocol.gg.gi,{ac:new gg.D.Base64(),dL:new gg.D.pO(),eA:{uin:"",password:"",status:"",description:""},dH:new gg.D.protocol.gg.rF(),hU:new gg.fv.gz(this),mw:function(C,B){this.send(this.dH.xb(this.eA.uin,this.eA.password,B.rz,!gg.D.gp.get(gq.tC)?this.eA.status|qn.jS:this.eA.status,0,gg.D.protocol.gg.gN.sY(this.eA.description)))},lU:function(C,B){this.eA={uin:"",password:"",status:"",description:""};gg.fv.sq.set("sid_gg","");this.hU.tg(fo.lq);this.hU.tg(fo.ly);this.hU.tg(fo.kY);this.hU.tg(fo.lx);this.hU.tg(fo.ks);this.hU.tg(fo.lp);this.hU.tg(fo.ld);this.hU.tg(fo.lb);this.hU.tg(fo.lh);this.hv();this.dL.clear();gg.D.gi.eH();gg.D.fv.ij.tm("comm.connected")},lQ:function(C,B){gg.D.gi.setSid(B.sid)},mb:function(C,B){this.send(this.dH.jc());if(!gg.D.fv.ij.nt("gB.imported")&&gg.D.gp.get(gq.tw)=="1"){this.hU.fD(fo.lA);this.nc()}this.hU.mG(fo.ks,this.lU.bind(this));this.hU.mG(fo.lb,function(E,D){this.qM(D.uin,D.type)}.bind(this));this.hU.mG(fo.ld,function(E,D){this.qS(D.uin,D.type)}.bind(this));this.hU.mG(fo.lq,function(E,D){this.rM(D.qG,D.msg)}.bind(this));this.hU.mG(fo.ly,function(E,D){this.fO(D.status,D.description)}.bind(this));this.hU.mG(fo.kY,this.importUserProfile.bind(this));this.hU.mG(fo.lx,this.mv.bind(this));this.hU.mG(fo.eN,this.handleContactList.bind(this));this.hU.mG(fo.lh,this.nc.bind(this));this.hU.mG(fo.lv,this.lW.bind(this));this.hU.mG(fo.kD,this.mq.bind(this));this.activatePingTimer();gg.D.fv.ij.set("comm.connected")},handleContactList:function(F,H){var D=[].concat(H.gK,H.mV),C=[];var E=new Array(D.length);var B;for(B=0;B<D.length;B++){if(E.indexOf(D[B].uin)<0){E.push(D[B].uin)}else{D.splice(B,1)}}while(D.length>gg.D.protocol.gg.jl){var G=D.splice(0,gg.D.protocol.gg.jl);C.push(this.dH.jj(G))}C.push(this.dH.jk(D));this.send(C)},mv:function(C,B){for(cc in B){B[cc]=gg.D.protocol.gg.gN.sY(B[cc])}this.send(this.dH.jB(B,qn.jH))},mx:function(C,B){this.send(this.dH.jK(B.uin,[B.status?"\xff":"\xfe",""],0,qn.iR))},fO:function(B,C){this.eA.status=B;this.eA.description=typeof C!="undefined"?C:"";if(!gg.D.gp.get(gq.tC)&&(B!=qn.jV&&B!=qn.jW)){B|=qn.jS}this.send(this.dH.ji(B,gg.D.protocol.gg.gN.sY(C)))},rM:function(B,C){if(!(B instanceof Array)){this.send(this.dH.jK(B,gg.D.protocol.gg.oz.qa(C.substring(0,gg.D.protocol.gg.nT)),B))}else{B.each(function(E,D){this.send(this.dH.jK(E,gg.D.protocol.gg.oz.qa(C.substring(0,gg.D.protocol.gg.nT)),B.without(E)))}.bind(this))}},qM:function(C,B){this.send(this.dH.iO(C,B))},qS:function(C,B){this.send(this.dH.jJ(C,B))},qL:function(D){for(var C=0,B=D.length;C<B;C++){this.qM(D[C],qn.jY)}},qR:function(D){for(var C=0,B=D.length;C<B;C++){this.qS(D[C],qn.jY)}},nc:function(){this.send(this.dH.kl())},lW:function(F,G){var J=[].concat(G.gK,G.mV);var C=0,H=qn.kg;var E=[];var I=gg.D.protocol.gg.nV-gg.D.protocol.gg.mz-9;while(C<J.length){var K="";while(K.length<(I)&&C<J.length){var B=J[C++];var D=(B.name!="i"?[B.name,B.hB,B.hy,B.visible,B.ht,B.group,B.uin,B.mail,B.pp,B.pq,B.oA,B.oB,B["private"],B.hE].join(";"):"i;;;;;;"+B.uin)+"\n";if(K.length+D.length<I){K+=D}else{C--;break}}E.push(this.dH.kl(H,gg.D.protocol.gg.gN.sY(K)));$V("comm.export");H=qn.kh}this.send(E)},mq:function(I,C){var B={},K={};for(var H in qn.qp){K[qn.qp[H]]=null}var G=C.fa||0,E=C.fb||0;fc=parseInt(G);E=parseInt(E);if(G+E>0){var J=new Date().getYear()+1900;if(G>0&&E==0){C.birthyear=[0,J-G]}else{if(G==0&&E>0){C.birthyear=[J-E,J]}else{if(G>0&&E>0){C.birthyear=[J-E,J-G]}}}}var D=typeof C.ix!="undefined",F=typeof C.iw!="undefined",L=null;if(D&&!F){L=qn.jw}else{if(!D&&F){L=qn.jv}}(L!==null)&&(C.gender=L);if(typeof C.ActiveOnly=="undefined"){delete C.ActiveOnly}else{C.ActiveOnly=1}for(var H in C){if(typeof K[H]!="undefined"&&C[H]!=""){B[H]=C[H]}}this.rv(B)},importUserProfile:function(){var B={};B[qn.qp.jG]=this.eA.uin;this.send(this.dH.jB(B,qn.jz))},rv:function(B){this.send(this.dH.jB(B,qn.jC))},qe:function(){this.send(this.dH.jn())},gr:function(D,C,B,E){gg.D.gi.gc();gg.fv.sq.set("sid_gg","");var E=E||"";var B=parseInt(B);if(E.length==0){switch(B){case qn.jW:B=qn.jV;break;case qn.jO:B=qn.jN;break;case qn.jR:B=qn.jQ;break;case qn.jU:B=qn.jT;break}}this.eA={uin:parseInt(D),password:C,status:B,description:E};gg.D.gi.qI(Object.extend(gg.D.protocol.gg.hn,{ondata:function(F){pP=gg.D.protocol.gg.qo.mj(F);pP.each(function(G){var H=gg.D.protocol.gg.rE.mj(G);gg.D.protocol.gg.hS.mj(H)})}}))},send:function(C){if(typeof C!="undefined"){}else{}if(C instanceof Array){for(var B=0;B<C.length;B++){this.dL.add(C[B])}}else{if(typeof C!="undefined"){this.dL.add(C)}}if(!this.dL.isEmpty()&&!gg.D.fv.ij.nt("comm.sending")){var D="";gg.D.fv.ij.set("comm.sending");this.dL.get(true).each(function(E){if(E.length>gg.D.protocol.gg.nV){return }if(D.length+E.length<gg.D.protocol.gg.nV){D+=E}else{gg.D.protocol.gg.gi.dL.add(E)}});gg.D.gi.send(D,Object.extend(gg.D.protocol.gg.hn,{onfinalization:function(E){gg.D.fv.ij.tm("comm.sending");gg.D.protocol.gg.gi.send()}}))}else{return }},de:null,activatePingTimer:function(){this.hv();this.de=window.setInterval(function(){this.qe()}.bind(this),gg.D.protocol.gg.qf)},hv:function(){window.clearInterval(this.de)}});var mz=gg.D.protocol.gg.mz;gg.D.protocol.gg.qo=function(){};Object.extend(gg.D.protocol.gg.qo,{fq:new gg.D.fr(false),ah:"",mj:function(D){var B=[];var C={};this.ah+=D;try{C=this.bI(this.ah);while(this.ah.length>=C.size+mz){B.push(this.bW(C,this.ah.substring(mz,C.size+mz)));this.ah=this.ah.substring(C.size+mz);(this.ah.length>=this.bI(this.ah).size+mz)&&(C=this.bI(this.ah))}}catch(E){this.ah=""}return B},bI:function(B){p=this.fq.tl(B,{type:tc.tf,size:tc.tf});if(p.size>gg.D.protocol.gg.nU||p.size<0){throw {msg:"pK.size > nU",size:p.size}}return new gg.D.protocol.gg.pL(p.type,p.size)},bW:function(B,H){var E={};switch(B.type){case qn.iU:E=this.fq.tl(H,{sid:tc.tf});break;case qn.km:E=this.fq.tl(H,{rz:tc.tf});break;case qn.jf:break;case qn.jL:E=this.fq.tl(H,{status:tc.tf,qE:tc.tf,rN:tc.tf});break;case qn.je:break;case qn.jI:E=this.fq.tl(H,{uin:tc.tf,rN:tc.tf,time:tc.tf,aw:tc.tf,msg:[tc.STRING,H.length-16]});E.sender=E.uin;if(E.msg.indexOf("\x00")!=-1){E.qB=String.toUtf8(E.msg.substring(0,E.msg.indexOf("\x00")));var I=E.msg.substring(E.qB.length+1);this.fq.rO(I);var D=this.fq.read(tc.CHAR);while(this.fq.iJ()<I.length){switch(D){case qn.oO.gn:E.qF=[E.uin];var F=this.fq.read(tc.tf);for(var C=0;C<F;C++){E.qF.push(this.fq.read(tc.te))}break;case qn.oO.rm:var G=this.fq.read(tc.tK);E.richText=this.fq.read([tc.STRING,G]);break;case qn.oO.mZ:case qn.oO.mX:case qn.oO.mY:default:this.fq.sb(I.length-this.fq.iJ());break}D=this.fq.read(tc.CHAR)}}break;case qn.iV:break;case qn.jX:E=this.fq.tl(H,{uin:tc.te,status:tc.CHAR,qO:tc.tf,qP:tc.tK,version:tc.CHAR,nb:tc.CHAR,tj:tc.CHAR,description:[tc.STRING,H.length-11]});break;case qn.jM:E=this.fq.tl(H,{uin:tc.te,status:tc.tf,description:[tc.STRING,H.length-5]});break;case qn.yB:E=this.fq.tl(H,{uin:tc.tf,status:tc.CHAR,qO:tc.tf,qP:tc.tK,version:tc.CHAR,nb:tc.CHAR,yu:tc.CHAR,sF:tc.tf,description:[tc.STRING,H.length-11]});break;case qn.kk:E=this.fq.tl(H,{qY:tc.CHAR,request:[tc.STRING,H.length-1]});break;case qn.yv:E.pi=[];this.fq.rO(H);while(this.fq.iJ()<B.size){cX={description:""};cX.uin=this.fq.read(tc.tf);cX.status=this.fq.read(tc.CHAR);this.fq.sb(13);if(cX.status==qn.jW||cX.status==qn.jO||cX.status==qn.jR||cX.status==qn.jU){cX.aX=this.fq.read(tc.CHAR);cX.description=fs(this.fq.read([tc.STRING,cX.aX]),true).rp()}E.pi.push(cX)}break;case qn.jm:E.pi=[];this.fq.rO(H);while(this.fq.iJ()<B.size){cX={description:""};cX.uin=this.fq.read(tc.te);cX.status=this.fq.read(tc.CHAR);this.fq.sb(9);if(cX.status==qn.jW||cX.status==qn.jO||cX.status==qn.jR||cX.status==qn.jU){cX.aX=this.fq.read(tc.CHAR);cX.description=fs(this.fq.read([tc.STRING,cX.aX]),true).rp()}E.pi.push(cX)}break;case qn.jA:E=this.fq.tl(H,{qY:tc.CHAR,rN:tc.tf,qX:[tc.STRING,H.length-5]});break;case qn.jh:break;default:break}return Object.extend(B,E)}});var mR=Ext.isIE;gg.D.protocol.gg.rE=function(){};Object.extend(gg.D.protocol.gg.rE,{dn:new gg.D.pO(),mj:function(N){var C=function(L,O){return gg.D.protocol.gg.oz.pZ(typeof L!="undefined"?L:"",typeof O!="undefined"?O:"")};switch(N.type){case qn.kk:this.dn.eV(qn.kk,N.request);switch(N.qY){case qn.kf:var D=[],G=[];var E=this.dn.iF(qn.kk,true).join("");if(E.indexOf("\x3b\x0d\x0a")!=-1){E=E.substr(E.indexOf("\x2c\x3b\x0d\x0a")+4,E.length)}E=gg.D.protocol.gg.gN.toUtf8(E).split("\n");var B=[],F=0,M,I=gg.D.gp.get(gq.dB);for(var H=0,J=E.length-1;H<J;H++,B=[]){if(H>50&&I){break}B=E[H].split(";");E[H]="";if(B[0]=="i"){G.push({uin:B[6],type:qn.jY});continue}F=B.length-1;if(F!=11&&F!=7&&(B[F-7]>0||B[4]>0)){D.push({name:fs(B[0]||""),hB:fs(B[1]||""),hy:fs(B[2]||B[3]||B[0]||B[F-7]||""),visible:fs(B[3]||B[2]||B[0]||B[F-7]||""),ht:B[4],group:fs(B[F-8]||nz.nY),uin:B[F-7],mail:fs(B[F-6]||""),pp:B[F-5],pq:B[F-4],oA:B[F-3],oB:B[F-2],"private":B[F-1],type:B[F-1]==1?qn.kc:qn.kb,hE:B[F]})}else{if(B[6]>0||B[4]>0){D.push({name:fs(B[0]||""),hB:fs(B[1]||""),hy:fs(B[2]||B[3]=="0"?B[0]:B[3]||B[6]||""),visible:fs(B[3]=="0"?B[2]:B[3]||B[0]||B[6]||""),ht:B[4]||"",group:fs(B[5]||nz.nY),uin:B[6]||"",mail:fs(B[7]||""),pp:B[8]||"",pq:B[9]||"",oA:B[10]||"",oB:B[11]||"","private":B[12]||0,type:B[12]==1?qn.kc:qn.kb,hE:B[13]||""})}}}E=null;D.sort(gg.D.protocol.gg.gk);N={gK:D,mV:G,hT:fo.kq};break;case qn.ki:case qn.kj:N.hT=fo.kr;break;default:break}break;case qn.jI:N.msg=C(N.qB,N.richText);break;case qn.jX:case qn.jM:case qn.yB:N.description=fs(N.description.rp(),true);break;case qn.jm:case qn.yv:if(N.pi.length==1){N=N.pi[0];Object.extend(N,new gg.D.protocol.gg.pL(qn.jM,0))}break;case qn.jA:var K={};switch(N.qY){case qn.jC:case qn.jz:K.hT=fo.kA;Object.extend(K,this.dc(N.qX));break;case qn.jE:case qn.jD:Object.extend(K,{hT:fo.kE,results:[]});if(N.size>5){N.qX.split("\x00\x00").each(function(O,L){K.results.push(gg.D.protocol.gg.rE.dc(O))})}break;case qn.jH:K.hT=fo.kB;break;default:break}N=K;break;case qn.jf:N.status=gg.D.protocol.gg.gi.eA.status;N.description=gg.D.protocol.gg.gi.eA.description;break;case qn.xc:default:break}return N},dc:function(B){var D={};B=B.split("\x00");for(var C=0;C<B.length-1;C+=2){D[B[C]]=fs(B[C+1],true)}return D}});gg.D.lK.hA={mS:{"class":"className","for":"htmlFor"},mT:function(B,C,D){var E;if(E=this.mS[C]){D[E]=B[C]}else{if(C=="style"){D.style.cssText=B[C]}else{if(C.match(/^on/)){D[C]=new Function(B[C])}else{D.setAttribute(C,typeof B[C]=="undefined"?"":B[C])}}}},apply:function(E){E=E||{};var C=("p|div|span|strong|em|img|table|tr|td|th|thead|tbody|tfoot|pre|code|h1|h2|h3|h4|h5|h6|ul|ol|li|form|input|textarea|legend|fieldset|select|option|blockquote|cite|br|hr|dd|dl|dt|address|a|button|abbr|acronym|script|link|style|bdo|ins|del|object|param|col|colgroup|optgroup|caption|label|dfn|kbd|samp|var|iframe").split("|");var D,B=0;while(D=C[B++]){E[D.toUpperCase()]=gg.D.lK.hA.sH(D)}return E},sH:function(B){return function(){var D=arguments,C,E;D.slice=[].slice;if(D.length>0){if(D[0].nodeName||typeof D[0]=="string"){E=D}else{C=D[0];E=D.slice(1)}}return gg.D.lK.hA.hI(B,C,E)}},hI:function(G,C,H){C=C||{};H=H||[];var F=navigator.userAgent.match(/MSIE/);var E=document.createElement((F&&C.name)?"<"+G+" name="+C.name+">":G);for(var D in C){if(typeof C[D]!="function"){if((D=="lang"||D=="langr")&&typeof C[D]=="string"){var B=C[D];if(D=="langr"){if(typeof nz[B]!="undefined"){gg.fv.nz.add(E,B);H[H.length]=nz[B]}else{gg.fv.nz.eZ(E,B);H[H.length]=gg.fv.nz.qb(B)}}else{if(B.indexOf(" ")!=-1){B=B.split(" ");gg.fv.nz.add(E,B[0],B[1]);E.setAttribute(B[1],nz[B[0]])}else{gg.fv.nz.add(E,B);H[H.length]=nz[B]}}}if(F){this.mT(C,D,E)}else{E.setAttribute(D,typeof C[D]=="undefined"?"":C[D])}}}for(var D=0;D<H.length;D++){if(typeof H[D]=="number"){H[D]=H[D].toString()}if(typeof H[D]=="string"){H[D]=document.createTextNode(H[D])}if(typeof H[D]=="undefined"){H[D]=document.createTextNode("")}E.appendChild(H[D])}if(!F&&E.getAttribute("unselectable")=="on"){Element.addClassName(E,"unselectable")}return E}};gg.D.lK.hA.apply(window);if(typeof gg.D.lK.gS=="undefined"){gg.D.lK.gS=function(){}}Object.extend(gg.D.lK.gS,{wh:"TabManager",wf:"tabBar",ou:"messageBar",tV:"windowManager",uW:"TabHeader",wg:"TabHeaderActive",vc:"TabTitle",uY:"TabContent",ve:"closeTab",va:"TabIcon",we:"moreTabs",wc:"moreTabsList",vW:"TabChatConference",wa:"TabChatConferenceList",TAB_WRITE_NOTIFY_ON:"TabChatWriteNotifyOn",wd:"TabChatWriteNotifyOff",CM:"ContactManger",vb:"ContactManagerContactList",cL:"ContactManagerInner",uZ:"Contact",wC:"ContactAvail",wF:"ContactNotAvail",wB:"ContactBusy",vd:"ContactInvisible",wE:"ContactBlocked",wD:"ContactActive",wG:"ContactTel",cZ:"ContactMessage",vk:"ContactGroup",vh:"ContactGroupName",vl:"ContactGroupCounter",vf:"ContactGroupOpen",vU:"ContactIcon",vT:"ContactName",vn:"ContactStatus",vX:"ContactEdit",uX:"ContactSelected",vj:"ContactDropSelected",vq:"ContactPreview",vo:"ContactPreviewWrapper x-window-tc",vV:"Menu",vC:"MenuDrop",vE:"MenuDropHR",vH:"MenuItem",vA:"MenuItemHover",vI:"MenuBarItem",vB:"MenuBarItemHover",vP:"ContactManagerBanner",vD:"ContactManagerTitleBar",yL:"ContactManagerRssFeed",yW:"ContactManagerRssFeedVisible",za:"link",yZ:"close",vg:"ContactManagerAddContact",wb:"ContactUserProfile",vY:"ContactUserData",vM:"ContactExportContacts",vZ:"ContactImportContacts",vt:"ContactSearch",vu:"ContactNaglos",vv:"ContactRadio",vs:"ContactWWW",vx:"ContactGeneracja",vJ:"ContactEdit",vN:"ContactDelete",vR:"ContactBan",vQ:"ContactChat",vS:"ContactIgnoreList",vO:"About",vK:"disabled",vL:"hover",cQ:"UserStatus",uV:"UserStatusItem",CM_USER_STATUS_ITEM_SELECTED:"UserStatusItemSelected",vr:"UserStatusCurrent x-window-tc",dj:"UserStatusCurrentInner",vG:"UserStatusCurrentText",vy:"UserStatusList x-window-tc x-panel-body-noheader",vw:"UserStatusInputText",vi:"MessageInputWindow",vm:"MessageInputToolbar",vp:"edit",uU:"colorTable",uT:"emoticonTable",vF:"hover",MIW_BASE_CLASS:"ChatMessageWindow",MIW_USERNAME_CLASS:"username",MIW_NOTIFY_USERNAME_CLASS:"notifyUsername",MIW_TIME_CLASS:"time",MIW_TEXT_CLASS:"message",MIW_INCOMMING_CLASS:"incomming",MIW_OUTGOING_CLASS:"outgoing",MIW_EVENT_CLASS:"event",MIW_BANNER:"MessageWindowBanner",MIW_SMALL_BANNER:"MessageWindowSmallBanner",NM_POPUP_BASE_CLASS:"PopupNotifyWindow",NM_POPUP_POSITION_BR:"pnw_bottomRight",NM_POPUP_POSITION_TR:"pnw_topRight",NM_POPUP_STATUS_DESCRIPTION_CLASS:"description",NM_POPUP_STATUS_UNAVAILABLE_CLASS:"unavailable",NM_POPUP_STATUS_AVAILABLE_CLASS:"available",NM_POPUP_STATUS_BUSY_CLASS:"busy",NM_POPUP_STATUS_BLOCKED_CLASS:"blocked",NM_POPUP_MESSAGE_CLASS:"message",NM_POPUP_MESSAGE_CONTENT_CLASS:"message_content",NM_POPUP_NICKNAME_CLASS:"nickname",NM_TITLE_MESSAGE_ICON:"message.ico",NM_TITLE_DEFAULT_ICON:"default.ico",wl:"wm_panel",wi:"wm_panel_tab",wj:"wm_window",wm:"wm_break",wq:"wm_minimized",wn:"wm_minimized_full",wp:"wm_maximized",wo:"wm_normal",wu:"wm_button",wk:"wm_label",wr:"wm_buttons_panel",wy:"wm_buttons_panel_visible",wx:"wm_buttons_panel_hidden",wz:"wm_button_minimize",wt:"wm_button_maximize",wv:"wm_button_close",wA:"wm_button_minimize_inactive",ww:"wm_button_maximize_inactive",ws:"wm_button_close_inactive",DG_OVERLAYID:"dg_overlay",DG_DATAID:"dg_data",DG_DATA_TITLE:"title",DG_DATA_CONTENT:"content",DG_DATA_BUTTONS:"buttons",DG_TYPE_INFORMATION:"nh",DG_TYPE_ERROR:"error",DG_TYPE_QUESTION:"question",DG_TYPE_WARNING:"warning",IL_ITEM:"il_item",IL_FORMID:"ignoreListForm",PBS_FORMID:"pubdirSearchForm",PBS_TABLEID:"pubdirResults",PBS_TDBUTTONS:"btns",PBS_STATUS_AVAILABLE:"available",PBS_STATUS_BUSY:"busy",PBS_STATUS_UNAVAILABLE:"unavailable",WAIT:"wait",WAIT_TEXT:"waitText",yF:"loginPageBanner",yE:"menuAdBanner"});var gS=gg.D.lK.gS;function fs(B,C){B=B.escapeHTML().oY();return C?gg.D.protocol.gg.gN.toUtf8(B):B}function yN(B){if(!gg.D.gp.get(gq.eP)){window.open(B,"","");return }gg.lK.hw.confirm(null,nz.oI,function(C){if(C!=gg.lK.hw.mP){return }window.open(B,"","")});return false}function zK(B){return B===true||B===false}function sC(B){return/^[0-9]{1,10}$/.test(B)}Object.extend(Form,{getArray:function(C){C=$(C);var D=this.getElements(C);var B=new Object();for(var E=0;E<D.length;E++){if(D[E].name){B[D[E].name]=$F(D[E])}}return B}});Object.extend(String.prototype,{oY:function(){return this.replace(/\x0A/g,"<br />").replace(/\x0D/g,"")},rp:function(){return this.replace(/[\s\x00]*$/g,"")},linkUrls:function(){return this.replace(new RegExp("((((file|gopher|news|nntp|telnet|http|ftp|https|ftps|sftp)://)|(www([0-9]*)?\\.))+(([a-zA-Z0-9\\._-]+\\.[a-zA-Z]{2,6})|([0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}))((:[1-9][0-9]*)?)(/[a-zA-Z0-9\\?=#;\\.\\&%_,/\\-~]*)?)","gi"),function(C){var D=C;if(C.indexOf("://")==-1){D="http://"+C}var B=C.match(/http:\/\/(pl\.www.)?youtube\.com\/watch\?v=([a-zA-Z0-9_-]+)(&[a-zA-Z0-9_=&%;\+]+)?/i);if(B){return"<a onclick=\"yT('"+B[2]+'\');" href="javascript:;">'+C+"</a>"}return'<a href="'+D+'" target="_blank" onclick="return yN(this.href)">'+C+"</a>"})}});String.prototype.escapeHTML=function(){return this.replace(/<|>|&|"/g,function(B){switch(B){case"<":return"&lt;";case">":return"&gt;";case"&":return"&amp;";case'"':return"&quot;"}})};Object.extend(Element,{parentOf:function(C,B){C=$(C);while(C.parentNode){if(C==B){return true}C=C.parentNode}return false}});Object.extend(Array.prototype,{fh:function(D){var C=UL();for(var B=0;B<this.length;B++){C.appendChild(LI(typeof D=="undefined"?this[B]:D(this[B])))}return C}});if(typeof gg.D.lK.zi=="undefined"){gg.D.lK.zi=function(){}}Object.extend(gg.D.lK.zi,{create:function(){var B=new this;B.initialize();return B}});Object.extend(gg.D.lK.zi.prototype,{initialize:function(){var B=this;B.ev=new gg.fv.gz();B.qD=null;B.zr=null;B.ev.mG(fo.kx,function(C,D){B.zh(C,D)});B.ev.mG(fo.ks,function(C,D){B.zg(C,D)});B.ev.mG(fo.lo,function(C,D){B.zg(C,D)})},zh:function(B,C){this.yw()},zg:function(B,C){this.zk()},zk:function(){if(this.qD!=null){this.qD.hide()}},yw:function(){if(this.qD!=null){this.qD.show()}else{var B=gg.D.gp.get(gq.sA);this.qD=new Ext.Window({title:nz.yD,layout:"fit",maximizable:false,animCollapse:false,hideMode:"visibility",collapsible:false,constrain:true,border:false,draggable:true,width:412,height:330,x:Math.floor((document.body.offsetWidth-B.width-gg.D.gp.get(gq.qV).width)/3)+gg.D.gp.get(gq.qV).width+B.margin,y:B.top,resizable:false,closable:true,buttonAlign:"center",items:{region:"north",border:false,html:'<iframe frameborder="0" allowtransparency="true" scrolling="no" src="http://adserver.gadu-gadu.pl/appsvc/appmsg_webgg.asp" style="height: 265px; width: 400px; margin: 0px; padding: 0px; background: transparent;"></iframe>'},buttons:[{text:nz.yC,handler:function(){this.qD.hide()}.bind(this)}]});this.qD.show()}},zB:function(){if(this.yl==null){this.yl=new Ext.Window({layout:"fit",title:'<div style="text-align: center;"><a id="bannerAdTitle" class="windowTitleLink">WebGadu zostało wzbogacone o możliwość słuchania radia.  Słuchaj muzyki prosto z Webgadu!</a></div>',hideMode:"visibility",collapsible:false,border:false,bodyBorder:false,hideBorders:true,shadow:false,height:10,buttonAlign:"left",frame:true,draggable:false,resizable:false,closable:false,plain:true,toFront:function(){}});this.yl.show();this.zl();$("bannerAdTitle").observe("click",function(){this.zn();return false}.bind(this))}},zn:function(){if(this.nj==null){this.nj=new Ext.Window({layout:"fit",buttonAlign:"center",width:300,height:230,title:"W WebGadu jest już radio!",html:'<p style="padding: 10px">Wychodząc naprzeciw Waszym oczekiwaniom dajemy Wam możliwość słuchania radia bezpośrednio z WebGadu!<br /><br />Wystarczy kliknąć ikonę OPEN.FM znajdującą się w prawym dolnym rogu komunikatora.<br /><br />Spowoduje to uruchomienie playera.<br />Potem wybieramy stację, której chcemy słuchać i… gra muzyka!</p>',buttons:[{text:nz.yC,handler:function(){this.nj.close();this.nj=null}.bind(this)}],listeners:{close:{fn:function(){this.nj=null}.bind(this)}}});this.nj.show()}},zl:function(){if(this.yl!=null){var B=document.body.offsetWidth;if(Ext.isIE){this.yl.setWidth(B+1);this.yl.alignTo(document.body,"bl-bl",[1,2])}else{this.yl.setWidth(B);this.yl.alignTo(document.body,"bl-bl")}}}});if(typeof gg.D.lK.yy=="undefined"){gg.D.lK.yy=function(){}}Object.extend(gg.D.lK.yy,{create:function(){var B=new this;return B}});Object.extend(gg.D.lK.yy.prototype,{zA:null,zx:function(){if(this.zA==null){this.zA=new gg.D.lK.zy}return this.zA}});if(typeof gg.D.lK.zy=="undefined"){gg.D.lK.zy=function(){}}Object.extend(gg.D.lK.zy,{});Object.extend(gg.D.lK.zy.prototype,{openFMWindow:null,zG:false,zu:"http://open.fm/player.php",zz:"grPlayer",zw:"empty.html",zv:[[31,"Orange Music"],[11,"Największe Hity"],[1,"Po Polsku"],[39,"Freszzz"],[2,"Impreza"],[8,"Dyskotekowo"],[5,"House"],[7,"Trance"],[21,"Disco-Polo"],[27,"Italo Disco"],[34,"Classic Disco"],[35,"100% Madonna"],[23,"Hip-Hop Stacja"],[24,"Hip-Hop PL"],[26,"Czarne Brzmienia"],[19,"Latino"],[30,"Reggaeneracja"],[33,"Chillout"],[25,"Jazz"],[4,"We Dwoje"],[20,"Ballady Wszech czasów"],[18,"Hity Lat 60"],[17,"Hity Lat 70"],[3,"Hity Lat 80"],[14,"Hity Lat 90"],[29,"Polski Rock"],[32,"Classic Rock"],[6,"Modern Rock"],[13,"Ciężkie Brzmienia"],[15,"100% Dżem"],[28,"Szanty"],[37,"Kraina ?agodności"],[16,"Kids"],[38,"Wielkie Hity Filmowe"],[12,"ASAP - Hity z Reklam"]],zC:function(){this.zq();this.openFMWindow.show();this.zG=true},zD:function(){if(this.zG==true){this.openFMWindow.close();this.zG=false}else{this.zC()}},zq:function(){var B=new Ext.data.SimpleStore({fields:["id","name"],data:this.zv});var C=new Ext.form.ComboBox({x:201,y:6,width:100,height:12,store:B,displayField:"name",typeAhead:true,mode:"local",triggerAction:"all",emptyText:"Wybierz kanał...",selectOnFocus:true,ctCls:"openFMWindow",listClass:"openFMChannelsList",listeners:{select:{fn:function(F,D,E){this.zo(D.data.id);F.clearValue()}.bind(this)}}});this.openFMWindow=new Ext.Window({layout:"absolute",maximizable:false,animCollapse:false,draggable:true,width:322,height:146,x:Math.floor(document.body.offsetWidth-330),y:70,title:"OPEN.FM",plain:true,resizable:false,items:[{x:0,y:0,border:false,html:'<iframe width="306" height="117" style="display:block" src="'+this.zu+'" id="'+this.zz+'" border="0" noborder frameborder="no" ></iframe>'},C]})},zo:function(B){if(B==null){document.getElementById(this.zz).src=this.zu}else{document.getElementById(this.zz).src=this.zu+"?id="+B}},zs:function(){document.getElementById(this.zz).src=null}});if(typeof gg.D.lK.cY=="undefined"){gg.D.lK.cY=function(){}}Object.extend(gg.D.lK.cY,{bg:null,cU:null,create:function(){var B=new this;if(gg.D.gp.get(gq.dB)){B.bJ()}else{if(gg.D.gp.get(gq.cT)){B.bh()}else{if(gg.D.gp.get(gq.aR)){B.yg()}else{B.bK()}}}return B}});Object.extend(gg.D.lK.cY.prototype,{bK:function(){this.bg=gg.D.lK.ContactManager.create(gg.D.lK.pQ.create());this.cU=gg.D.lK.TabManager.create()},bh:function(){var B=gg.D.lK.az.create();this.cU=gg.D.lK.ak.create();this.vieport=new Ext.Viewport({layout:"border",defaults:{split:true,animFloat:false,autoHide:false,animate:false,useSplitTips:false},items:[this.cU.TabWindow],renderTo:Ext.getBody()});this.vieport.doLayout();this.cU.TabWindow.doLayout();this.cU.tabs.push(B);this.cU.TabPanel.add(B);B.expand();this.cU.TabWindow.doLayout();this.bg=gg.D.lK.ContactManager.create(B);gg.lK.hw.afterShow=function(D,C){D.getDialog(C).maximize()}},bJ:function(){var B=gg.D.lK.O.create()},yg:function(){this.cU=gg.D.lK.yh.create()}});gg.D.lK.oj=function(){};Object.extend(gg.D.lK.oj,{create:function(C,D){var B=this.zq(D);this.og(B,C,D)},og:function(B,D,E){var C=new Date();if(B.document.body.innerHTML!=""){B.document.body.innerHTML='<div class="chatPreviewLogo"></div><div class="chatPreviewInfo">'+nz.oo+": "+E+"<br />"+nz.op+": "+C.toLocaleString()+"</div>"+D.innerHTML}else{B.document.write('<html><head><style>html, body {overflow: auto !important;}</style><head><link rel="stylesheet" type="text/css" href="css/ggclient.css" /></head><body style="background-image: none; background-color: #fff; overflow: auto;"><div class="chatPreviewLogo"></div><div class="chatPreviewInfo">'+nz.oo+": "+E+"<br />"+nz.op+": "+C.toLocaleDateString()+"</div>");B.document.write(D.innerHTML);B.document.write("</body></html>")}},zq:function(B){return window.open("",B,"height=400, width=500, scrollbars=yes, menubar=yes")}});if(typeof gg.D.lK.Contact=="undefined"){gg.D.lK.Contact=function(){}}Object.extend(gg.D.lK.Contact,{create:function(D,G,B,C,F){var E=new this;E.uin=D;E.id=null;E.visible=G.toString();E.hy=E.visible;E.description="";E.status=qn.jV;E.group="";E.qw=false;E.sX=false;E.cp=false;E.nm=false;E.ns=false;E.type=qn.kb;E.isContactList=(typeof F=="undefined");E.container=B.appendChild(DIV({"class":gS.uZ,unselectable:"on"},E.visible));E.container.innerHTML+='<div class="'+gS.vn+'" ></div>';E.gF=C;E.nodeName=$(E.container.childNodes[0]);E.nodeStatus=$(E.container.childNodes[1]);Event.observe(E.container,"dblclick",function(H){E.pD()}.bind(E));Event.observe(E.container,"click",function(J){var L=this.gF.iC();if(!J.shiftKey){this.gF.dS=L.indexOf(E);this.select(J.ctrlKey)}else{this.gF.hf(null);this.gF.bo=L.indexOf(E);var I=this.gF.dS<=this.gF.bo?this.gF.dS:this.gF.bo;var H=this.gF.dS>this.gF.bo?this.gF.dS:this.gF.bo;for(var K=I;K<=H;K++){L[K].highlight(true,true)}this.triggerSelected()}}.bind(E));Event.observe(E.container,"keyup",function(H){switch(H.keyCode){case 46:this.gF.hq();break;case 38:this.gF.rC(-1);break;case 40:this.gF.rC(1);break}Event.stop(H)}.bind(E));E.ev=E.gF.ev;E.status=qn.jV;E.am(E.uin>0?gS.wF:gS.wG);E.description="";E.ev.mI(E.uin,E.mt.bind(E),gg.fv.gz.hW);if(E.isContactList){E.ev.mI(E.uin,E.mp.bind(E),gg.fv.gz.hX)}else{E.ev.mG(fo.hC,function(H,I){if(I.uin==E.uin){E.mt(H,I)}});E.ev.mG(fo.lL+"/"+E.uin,E.mt.bind(E));setTimeout(function(){E.ev.fD(fo.lk+"/"+E.uin,{uin:E.uin})},Math.floor(Math.random()*5))}E.tT();return E}});Object.extend(gg.D.lK.Contact.prototype,{select:function(C,B){if(!C){this.gF.hf(this)}if(!this.ns){this.highlight();if(typeof B=="undefined"||!B){this.triggerSelected()}}else{if(C){this.hp()}}this.container.focus()},tT:function(){if(!gg.D.gp.get(gq.cT)){return }this.ev.mG(fo.ko+"/"+this.uin,function(B,C){this.am(gS.cZ)}.bind(this));this.ev.mG(fo.lq+"/"+this.uin,function(B,C){if(this.container.hasClassName(gS.cZ)){this.fO()}}.bind(this));this.ev.mG(fo.lq+"/"+this.uin,function(B,C){if(this.container.hasClassName(gS.cZ)){this.fO()}}.bind(this))},triggerSelected:function(){this.ev.fD(fo.kO,{uin:this.uin,status:this.status,description:this.description})},pD:function(){if(this.container.hasClassName(gS.cZ)){this.fO()}if(!this.my()){gg.lK.hw.error(null,nz.fP);return }if(this.status==qn.jP){gg.lK.hw.error(null,nz.gd);return }this.ev.fD(fo.kT,{id:this.uin,title:this.visible.toString()});this.hp();this.select()},hp:function(){this.ns=false;$(this.container).removeClassName(gg.D.lK.gS.uX)},highlight:function(){this.ns=true;Element.addClassName(this.container,gS.uX)},destroy:function(){Element.remove(this.container)},iG:function(){return{contactId:this.contactId||"",name:this.name||"",hB:this.hB||"",hy:this.hy||"",visible:this.visible||"",ht:this.ht||"",group:this.group||"",uin:this.uin||"",iA:this.iA||"","private":this.type==qn.kc?1:0,hE:this.hE||"",type:this.type,pp:this.pp||0,pq:this.pq||"",oA:this.oA||0,oB:this.oB||"",status:this.status,description:this.description,py:true,nm:this.nm}},nl:function(){switch(this.status){case qn.jV:case qn.jW:case qn.jT:case qn.jU:case qn.jP:this.cp=false;break;default:this.cp=true}return this.cp},mp:function(B,C){if(this.uin!=C.uin){return }this.ev.fD(fo.lL+"/"+this.uin,this.iG())},mt:function(C,D){if((D.uin!=this.uin)||(typeof D.status!="undefined"&&D.status==this.status&&typeof D.description!="undefined"&&D.description==this.description&&this.isContactList)){return }if(typeof D.nm!="undefined"){this.nN(D.nm)}var B=this.nl();this.fO({description:D.description||this.description,uin:D.uin,status:D.status||this.status,visible_name:D.visible});if(this.isContactList){if(B!=this.cp){this.ev.fD(fo.lj,{uin:this.uin,group:this.group,nl:this.cp})}if(gg.D.gp.get(gq.ty)!=this.uin&&this.isContactList&&!this.nm){this.ev.fD(fo.kQ,{status:this.status,uin:this.uin,hy:this.visible,type:"status",description:this.description})}}},nN:function(B){this.nm=B;if(this.nm){this.am(gS.wE);this.nodeStatus.innerHTML=""}},sm:function(){this.status=qn.jV;this.description="";this.fO()},fO:function(B){if(typeof B!="undefined"){if(typeof B.visible_name!="undefined"){B.visible=B.visible_name}Object.extend(this,B)}if(this.nm){return }this.nodeName.nodeValue=this.visible;this.nodeStatus.innerHTML=this.description.linkUrls();(this.description=="")?this.nodeStatus.hide():this.nodeStatus.show();this.nl()?this.container.addClassName(gS.wD):this.container.removeClassName(gS.wD);if(this.my()){switch(this.status){case qn.jV:case qn.jW:this.am(gS.wF);break;case qn.jN:case qn.jO:this.am(gS.wC);break;case qn.jQ:case qn.jR:this.am(gS.wB);break;case qn.jT:case qn.jU:this.am(gS.vd);break;case qn.jP:this.am(gS.wE);break;default:this.am(gS.wF)}}if(typeof this.gF.fJ=="function"){this.gF.fJ()}},nG:function(B){this.ev.mG(fo.ly,function(C,D){this.mt(C,{uin:this.uin,status:D.status,description:fs(D.description)})}.bind(this));this.mt(fo.ly,{uin:this.uin,status:this.gF.tG?this.gF.tG.status:0,description:this.gF.tG?fs(this.gF.tG.gV):""});this.pD=function(){gg.lK.hw.error(null,nz.os)}},am:function(B){this.container.className=gS.uZ+" "+B;if(this.ns){this.highlight()}},my:function(){return !((!isNaN(this.uin)&&this.uin<1)||isNaN(this.uin))}});gg.D.lK.gC=function(){};Object.extend(gg.D.lK.gC,{gK:null,gL:null,lH:null,dS:null,bo:null,initialize:function(B){this.container=B;this.gE=B;this.gK=$A();this.gL=$A();this.ev=new gg.fv.gz()},pF:function(B,E,D){var C=gg.D.lK.Contact.create(B,E,this.gE,this,false);this.gK.push(C);return C},hf:function(B){this.gK.each(function(C){if(B!=C){C.hp()}})},hq:function(){},iC:function(){return this.gK},rC:function(B){this.dS=(this.dS+B)%this.gK.length;if(this.dS<0){this.dS=this.gK.length-1}this.gK[this.dS].select()},aK:function(D,C){var B=$A();if(typeof D=="undefined"||D==null){var D=this.gK}if(typeof C=="undefined"){var C="uin"}D.each(function(E){B.push(E[C])});return B},bL:function(){return this.gK.findAll(function(C,B){return Element.hasClassName(C.container,gg.D.lK.gS.uX)})}});gg.D.lK.gD=function(B){this.initialize(B)};Object.extend(gg.D.lK.gD.prototype,gg.D.lK.gC);Object.extend(gg.D.lK.gD.prototype,{qN:function(B){this.fU=B;this.fJ()},fJ:function(){var B="";this.gK.each(function(C,D){B+=C.visible+";"});if(typeof this.fU!="undefined"){Element.update(this.fU,B.toString().substring(0,50))}},getName:function(B){return this.gK.find(function(C,D){return(C.uin==B)}).visible},hG:function(){var B=this.bL();if(B.length<1){return }B.each(function(D,C){this.ev.fD(fo.kU,D.iG())}.bind(this))}});gg.D.lK.ContactGroup=function(D,B,C){this.initialize(D,B,C)};Object.extend(gg.D.lK.ContactGroup.prototype,{activeList:null,inactiveList:null,groupName:null,gE:null,lG:null,lJ:null,container:null,visible:true,initialize:function(D,B,C){this.groupName=D||nz.nY;this.activeList=$A();this.inactiveList=$A();this.bT=this.groupName;this.container=B.appendChild(DIV(this.lG=DIV({"class":gS.vk,unselectable:"on"},this.lJ=SPAN({"class":gS.vl,unselectable:"on"}),this.lF=SPAN({"class":gS.vh,unselectable:"on"},this.bT)),this.gE=DIV()));Event.observe(this.lG,"click",function(){this.bw()}.bind(this))},gw:function(B){this.inactiveList.push(B)},hu:function(B){if(B.nl()){this.activeList.splice(this.activeList.indexOf(B),1)}else{this.inactiveList.splice(this.inactiveList.indexOf(B),1)}B.destroy();delete B;this.qW()},iK:function(){return this.getAll().findAll(function(B,C){return B.ns})},getAll:function(){return $A().concat(this.activeList,this.inactiveList)},getUinHashMap:function(){var C=new Object();for(var B=0;B<this.inactiveList.length;B++){if(typeof C[this.inactiveList[B].uin]=="undefined"){C[this.inactiveList[B].uin]=$A()}C[this.inactiveList[B].uin].push(this.inactiveList[B])}return C},fO:function(B){if(B){this.oK()}else{this.oL()}},oK:function(){for(var B=0;B<this.inactiveList.length;B++){if(this.inactiveList[B].cp){Element.remove(this.inactiveList[B].container);this.activeList.push(this.inactiveList[B]);this.inactiveList.splice(B,1);B--}}this.activeList.sort(gg.D.protocol.gg.gk);this.dv()},oL:function(){for(var B=0;B<this.activeList.length;B++){if(!this.activeList[B].cp){this.gE.removeChild(this.activeList[B].container);this.inactiveList.push(this.activeList[B]);this.activeList.splice(B,1);B--}}this.inactiveList.sort(gg.D.protocol.gg.gk);this.dw()},he:function(){for(var B=0;B<this.activeList.length;B++){this.activeList[B].sm();this.gE.removeChild(this.activeList[B].container);this.inactiveList.push(this.activeList[B]);this.activeList.splice(B,1);B--}this.inactiveList.sort(gg.D.protocol.gg.gk);this.dw()},ih:function(C,B){for(var D=0;D<this.activeList.length;D++){if(this.activeList[D][C]==B){return this.activeList[D]}}for(var D=0;D<this.inactiveList.length;D++){if(this.inactiveList[D][C]==B){return this.inactiveList[D]}}return null},dv:function(){var C=this.gE.firstChild;for(var B=0;B<this.activeList.length;B++){if(this.activeList[B].container.parentNode!=this.gE){this.gE.insertBefore(this.activeList[B].container,C)}C=this.activeList[B].container.nextSibling}this.qW()},dw:function(){var C=null;for(var B=0;B<this.inactiveList.length;B++){if(this.inactiveList[B].container.parentNode!=this.gE){this.gE.insertBefore(this.inactiveList[B].container,C)}C=this.inactiveList[B].container.nextSibling}this.qW()},qW:function(){this.visible?$(this.lG).addClassName(gS.vf):$(this.lG).removeClassName(gS.vf);$(this.lJ).update(this.activeList.length+"/"+this.ep())},sf:function(B){this.gE.removeChild(B.container);this.inactiveList.sort(gg.D.protocol.gg.gk);this.dw()},bw:function(){this.visible=!this.visible;this.visible?$(this.gE).show():$(this.gE).hide();this.qW()},ep:function(){return this.activeList.length+this.inactiveList.length}});if(typeof gg.D.lK.pQ=="undefined"){gg.D.lK.pQ=function(){}}Object.extend(gg.D.lK.pQ,{create:function(){var C=new this;C.ev=new gg.fv.gz();C.createWindow();var E=gg.D.gp.get(gq.fd);var B=gg.D.gp.get(gq.qV);var D=new Ext.Window({title:E,id:"WebGaduContactManager",width:B.width,height:B.height,minWidth:B.width,minHeight:B.height,x:Math.floor((document.body.offsetWidth-B.width-gg.D.gp.get(gq.sA).width)/3),y:B.top,shim:false,animCollapse:false,constrain:true,constrainHeader:true,closable:true,border:false,layout:"border",tbar:[{text:nz.ft,menu:C.menu},{text:nz.fu,menu:C.contactsMenu},{text:nz.fT,menu:C.np}],items:[C.gC,{id:"ContactManagerTopMenu",region:"north",border:false,height:!gg.D.gp.get(gq.cH)?33:75,html:!gg.D.gp.get(gq.cH)?"":'<div class="'+gg.D.lK.gS.vP+' x-toolbar"><iframe frameborder="0" marginwidth="0" marginheight="0" class="'+gg.D.lK.gS.vP+'" src="http://adserver.gadu-gadu.pl/getmainbannerwebgg.asp"></iframe></div>',minSize:33,nZ:75}]});D.on("beforeclose",function(){gg.lK.hw.confirm(null,nz.zj,function(F){if(F==gg.lK.hw.mP){C.ev.fD(fo.lo)}});return false},this);D.show();D.hide();C.ev.mG(fo.kx,function(){D.show()});return D}});Object.extend(gg.D.lK.pQ.prototype,{createWindow:function(){this.ev=new gg.fv.gz();this.menu=new Ext.menu.Menu({id:"ContactsManagerMenu",items:[{text:nz.fw,handler:function(){this.ev.fD(fo.kY)},scope:this},{text:nz.fp,handler:function(){this.ev.fD(fo.la)},scope:this},"-",{text:nz.yU,handler:function(){this.ev.fD(fo.lo)},scope:this}]});this.contactsMenu=new Ext.menu.Menu({id:"ContactsManagerContactsMenu",items:[{text:nz.eQ,iconCls:gg.D.lK.gS.vg,handler:function(){this.ev.fD(fo.kU,{})},scope:this},{text:nz.wP,handler:function(){this.ev.fD(fo.en)},scope:this},{text:nz.fx,handler:function(){this.ev.fD(fo.iy)},scope:this},{text:nz.wQ,handler:function(){this.ev.fD(fo.eR)},scope:this},{text:nz.fE,handler:function(){this.ev.fD(fo.im)},scope:this},"-",{text:nz.ga,handler:function(){this.ev.fD(fo.lh)},scope:this},{text:nz.wK,handler:function(){this.ev.fD(fo.le)},scope:this},{text:nz.gM,handler:function(){this.ev.fD(fo.kW)},scope:this},{text:nz.ff,handler:function(){this.ev.fD(fo.kZ)},scope:this}]});this.np=new Ext.menu.Menu({id:"ContactsManagerHelpMenu",items:[{text:nz.wN,handler:function(){this.ev.fD(fo.kS)},scope:this},"-",{text:nz.ye,handler:function(){window.open(nz.yf)},scope:this},{text:nz.xZ,handler:function(){window.open(nz.yd)},scope:this}]});this.gC=new Ext.Panel({id:"ContactManager",border:false,region:"center"})}});if(typeof gg.D.lK.az=="undefined"){gg.D.lK.az=function(){}}Object.extend(gg.D.lK.az,{create:function(){var C=new this;C.ev=new gg.fv.gz();C.createWindow();C.gC=new Ext.Panel({id:"ContactManager",border:false,autoScroll:true,region:"center"});var E=gg.D.gp.get(gq.fd)+" "+gg.D.gp.get(gq.fe);var B=gg.D.gp.get(gq.qV);var D=new Ext.Panel({title:E,collapsible:true,collapsed:false,autoScroll:false,animCollapse:false,floatable:true,animate:false,animFloat:false,titleCollapse:true,header:true,id:"WebGaduContactManager",shim:false,animCollapse:false,constrainHeader:true,constrain:true,closable:true,border:false,layout:"border",items:[C.gC,{id:"ContactManagerTopMenu",region:"north",border:false,height:40,html:"",minSize:40,nZ:40},{id:"ContactManagerStatus",region:"south",border:false,height:25,html:"",minSize:25,nZ:25,listeners:{render:function(F){C.tG=new gg.D.lK.tH(F.body.dom)}}}],active:function(){this.mode=gg.D.lK.sD.MODE.ACTIVE},od:function(){if(this.mode!=gg.D.lK.sD.MODE.ge){this.mode=gg.D.lK.sD.MODE.INACTIVE}},qu:function(){},close:function(F){this.mode=gg.D.lK.sD.MODE.ge}});D.on("beforeclose",function(){C.ev.fD(fo.lo);return false},this);D.panelLayout=D;return D}});Object.extend(gg.D.lK.az.prototype,gg.D.lK.pQ.prototype);if(typeof gg.D.lK.ContactManager=="undefined"){gg.D.lK.ContactManager=function(){}}Object.extend(gg.D.lK.ContactManager,{menu:null,sO:null,window:null,create:function(E){var D=new this;var F=null;var C=null,B=null;D.ev=new gg.fv.gz();D.gK=$A();D.contactGroups=$A();D.gL=$A();D.inner=$A();D.lH=$A();D.bR={};D.dS=0;D.bo=0;D.fi=1;D.window=E;D.title=!gg.D.gp.get(gq.cT)?gg.D.gp.get(gq.tP):nz.iq;D.window.dom=$(D.window.getComponent("ContactManager").body.dom);D.container=D.window.dom;D.inner=D.container.appendChild(DIV({id:gg.D.lK.gS.cL,"class":gg.D.lK.gS.cL}));D.gE=D.inner.appendChild(DIV({"class":gg.D.lK.gS.vb}));D.zb=D.inner.appendChild(new Element("div",{"class":gg.D.lK.gS.yL}));D.zb.hide();if(!gg.D.gp.get(gq.cT)){D.gJ=D.inner.appendChild(DIV({"class":gg.D.lK.gS.vo}));D.gI=D.gJ.appendChild(DIV({"class":gg.D.lK.gS.vq}));D.tG=new gg.D.lK.tH(D.inner)}D.wait=new gg.D.lK.Wait(D.inner);D.xi();D.window.on("resize",function(){D.pw()});D.window.on("move",function(){D.pw()});D.pw();D.ev.mG(fo.hC,function(G,H){D.lV(G,H)});D.ev.mG(fo.kq,function(G,H){D.lZ(G,H)});D.ev.mG(fo.kH,function(G,H){D.me(G,H)});D.ev.mG(fo.lj,function(G,H){D.ms(G,H)});D.ev.mG(fo.kx,function(G,H){D.mc(G,H)});D.ev.mG(fo.ks,function(G,H){D.lU(G,H)});D.ev.mG(fo.xK,function(G,H){D.xN(G,H)});D.ev.mG(fo.lk,function(G,H){D.mp(G,H)});D.ev.mG(fo.le,function(G,H){D.mn(G,H)});D.ev.mG(fo.kO,function(G,H){D.qj(G,H)});D.ev.mG(fo.lc,function(G,H){D.mo()});D.ev.mG(fo.ln,function(G,H){D.wY()});D.ev.mG(fo.kO,function(G,H){D.qj(G,H)});D.ev.mG(fo.lf,function(G,H){D.lX(H)});D.ev.mG(fo.lg,function(G,H){D.lY(H)});D.ev.mG(fo.lA,function(G,H){this.wait.show();this.wait.update(nz.ya)}.bind(D));D.ev.mG(fo.lo,function(G,H){D.rW()});D.ev.mG(fo.iy,function(G,H){D.hG()});D.ev.mG(fo.en,function(G,H){D.hq()});D.ev.mG(fo.im,function(G,H){D.pE()});D.ev.mG(fo.eR,function(G,H){D.eL()});D.ev.mG(fo.kK,function(G,H){if(H.type==gg.D.lK.sD.tc.tp){this.window.setTitle(gg.D.gp.get(gq.tP)+" ("+gg.D.gp.get(gq.ty)+")")}}.bind(D));return D}});Object.extend(gg.D.lK.ContactManager.prototype,gg.D.lK.gC);Object.extend(gg.D.lK.ContactManager.prototype,gg.D.lK.pQ);Object.extend(gg.D.lK.ContactManager.prototype,{gK:null,gL:null,contactGroups:null,lH:null,dS:null,bo:null,bR:null,pF:function(B,E,F,D){F=F||nz.nY;if(typeof this.bR[F]=="undefined"){bQ=new gg.D.lK.ContactGroup(F,this.gE);this.bR[F]=this.contactGroups.push(bQ)-1;this.sortGroups()}var C=gg.D.lK.Contact.create(B,E,this.contactGroups[this.bR[F]].gE,this);C.group=F;C.contactId=this.fi++;this.contactGroups[this.bR[F]].gw(C);return C},xf:function(D){var F=this.iC();D=D.toLowerCase();for(var G=0;G<F.length;G++){var B=F[G].visible.split(" ");var E=false;for(var C=0;C<B.length;C++){if(D==B[C].substring(0,D.length).toLowerCase()){E=true}}if(D==F[G].uin.toString().substring(0,D.length).toLowerCase()){E=true}if(!E){$(F[G].container).hide()}else{$(F[G].container).show();$($(F[G].container.parentNode).show().parentNode.firstChild).addClassName(gS.vf)}}},zd:function(){this.zb.show();this.pw()},ze:function(B){var C=Ext.data.Record.create([{name:"title"},{name:"link"},{name:"description"},{name:"pubDate"},{name:"ttl"}]);var D=new Ext.data.XmlReader({record:"item",id:"guid"},C);new Ajax.Request("get_rss.php?uid="+B,{method:"get",contentType:"text/xml",onSuccess:function(H){var F=D.read(H).records;if(F.length>0){var G=F[0];this.zb.innerHTML="";this.zb.insert('<div class="'+gg.D.lK.gS.za+'"><a target="_blank" href="'+G.get("link")+'">'+G.get("title")+"</a></div>");var E=new Element("a",{"class":gg.D.lK.gS.yZ});this.zb.insert(E);E.observe("click",function(){this.zb.removeClassName(gg.D.lK.gS.yW);this.zb.hide();this.pw()}.bind(this));this.zb.addClassName(gg.D.lK.gS.yW)}}.bind(this)})},xi:function(){var D,C,B,E;E=$(this.window.getComponent("ContactManagerTopMenu").body.dom).appendChild(DIV({"class":"x-toolbar"}));E.innerHTML='<table width="100%" border="0" height="30"><tr><td valign="middle" width="30" id="ContactManagerTopMenuLeft"></td><td valign="middle"align="left" id="ContactManagerTopCenter"></td><td width="30" valign="middle" align="right" id="ContactManagerTopMenuRight"></td></tr></table>';E=$("ContactManagerTopCenter");D=INPUT({type:"text",style:"border: none;width: 79%;padding: 3px;background: transparent;",value:nz.xa});C=DIV({"class":"x-tool",style:"float: right;display: none;margin: 5px 5px 0px 0px;"});B=function(F){D.value=typeof F!=="undefined"?F:nz.xa;C.hide();this.xf("")}.bind(this);new Ext.Button({renderTo:"ContactManagerTopMenuLeft",tooltip:nz.eQ,iconCls:gg.D.lK.gS.vg,handler:function(){var G=D.value!=nz.xa?D.value:"";var F=G.toString().match(/^[0-9]+$/);this.ev.fD(fo.kU,{uin:F?G:"",hy:G});B()},style:"display: inline;",scope:this});Event.observe(E.appendChild(C),"click",function(){B()}.bind(this));Event.observe(E.appendChild(DIV({style:"border: 1px solid #d0d0d0;margin: 2px;"})).appendChild(D),"keyup",function(F){if(F.target.value.length>0&&F.target.value!=nz.xa){C.show();this.xf(F.target.value)}else{C.hide();B("")}}.bind(this));Event.observe(D,"click",function(F){if(F.target.value==nz.xa){B("")}});new Ext.Button({renderTo:"ContactManagerTopMenuRight",tooltip:nz.ff,iconCls:gg.D.lK.gS.vt,handler:function(){this.ev.fD(fo.kZ);if(D.value!=nz.xa){this.ev.fD(fo.ll,{uin:D.value})}B()},style:"display: inline;",scope:this})},rW:function(){this.window.hide()},hf:function(B){var C=this.bL();for(var D=0;D<C.length;D++){if(C[D]!=B){C[D].hp()}}},pw:function(){if($(this.window.dom).getWidth()==0){return }var B=0;if(this.tG){$(this.tG.container).setStyle({width:$(this.window.dom).getWidth()+"px"});$(this.tG.sk).setStyle({width:$(this.tG.container).getWidth()+"px"});B=$(this.tG.gY).getHeight();var C=this.zb.getHeight();$(this.tG.sk).hide();$(this.gE).setStyle({height:($(this.window.dom).getHeight()-B-C-$(this.gJ).getHeight())+"px"})}},lZ:function(C,D){if(D.gK.length<1){this.wait.hide();gg.lK.hw.nh(null,nz.fA,function(){});return }var B=function(G){if(D.gK.length>25){this.wait.show()}this.gE.style.visibility="hidden";var K=this;var O=gg.D.gp.get(gq.ty);var F={};for(var N=0;N<this.contactGroups.length;N++){var M=this.contactGroups[N].getAll();for(var Q=0;Q<M.length;Q++){F[M[Q].visible]=M[Q].uin}}var P=0;var J=25,H=200;var M=function(V){var U=Math.min(V+J,G);for(var T=V;T<U;T++){var S=this.gK[T];if(S.uin>gg.D.protocol.gg.yp){S.uin=""}if(F[S.visible]==S.uin){continue}K.wait.update((T+1)+"/"+G);F[S.visible]=S.uin;var R=K.pF(S.uin,S.visible,S.group,true);Object.extend(R,S);if(K.gL.indexOf(R.uin)>=0){R.nN(true)}if(S.uin==O){R.nG()}}}.bind(D);D.mV.each(function(S,R){if(K.gL.indexOf(S.uin)<0){K.gL.push(S.uin)}});for(var I=0,L=G;I<L;I+=J){setTimeout(function(){M(this.j)}.bind({j:I}),P);P+=H}setTimeout(function(){this.gE.style.visibility="visible";this.wait.hide();this.zd();this.ev.fD(fo.eN,D);for(var R=0;R<this.contactGroups.length;R++){this.contactGroups[R].qW()}}.bind(this),P)}.bind(this);var E=gg.D.gp.get(gq.nR);if(D.gK.length>E){gg.lK.hw.confirm(null,nz.oa,function(F){B(F==gg.lK.hw.mP?D.gK.length:E)})}else{B(D.gK.length)}},wY:function(){this.ev.fD(fo.le)},me:function(E,F){var H=new Object();for(var G=0;G<this.contactGroups.length;G++){var D=this.contactGroups[G].getUinHashMap();for(var B in D){for(var C=0;C<D[B].length;C++){if(typeof H[B]=="undefined"){H[B]=$A()}H[B].push(D[B][C])}}}for(var G=0;G<F.pi.length;G++){if(typeof H[F.pi[G].uin]!="undefined"){for(var C=0;C<H[F.pi[G].uin].length;C++){H[F.pi[G].uin][C].fO(F.pi[G]);H[F.pi[G].uin][C].mp(fo.lk+"/"+F.pi[G].uin,{uin:F.pi[G].uin})}}else{this.dM(F.pi[G])}}for(var G=0;G<this.contactGroups.length;G++){this.contactGroups[G].oK()}},mp:function(B,C){if(!this.dE("uin",C.uin)){this.ev.fD(fo.lb,this.bG(C));this.dM(this.bG(C))}},xN:function(C,D){var B={uin:false,visible:false};if(this.dE("uin",D.uin)){B.uin=true}if(this.dE("visible",D.visible)){B.visible=true}this.ev.fD(fo.xJ+"/"+D.uin,B)},mc:function(E,F){var D=gg.D.gp.get(gq.ty);this.ze(D);var C={gK:$A(),mV:$A()};var B=F;var H=$H();this.window.setTitle(this.title+" ("+gg.D.gp.get(gq.ty)+")");for(var G=0;G<this.contactGroups.length;G++){H=H.merge(this.contactGroups[G].getUinHashMap())}H.values().each(function(J,I){if(J[0].uin<1){return }if(J[0].uin==D){J[0].nG(B)}else{C.gK.push(J[0].iG())}});this.gL.each(function(J,I){if(J[0].uin<1){return }C.mV.push(parseInt(J));this.ev.fD(fo.kG+"/"+parseInt(J),{uin:parseInt(J),nm:true})}.bind(this));this.ev.fD(fo.eN,C)},lU:function(){for(var B=0;B<this.contactGroups.length;B++){this.contactGroups[B].he()}},lV:function(B,E){E.group=E.group||nz.nY;E.contactId=E.contactId||"";var D=(E.contactId!=""&&(E.group!=E.iI||E.uin!=E.oldUin));var C=E.contactId!=""?this.dE("contactId",E.contactId):null;if(D){this.aZ(C)}if(!C||D){C=this.pF(E.uin,E.visible_name,E.group);this.contactGroups[this.bR[E.group]].sf(C);this.ev.fD(fo.ld,this.bG(E));this.ev.fD(fo.lb,C.iG())}C.contactId=E.contactId=this.fi.toString();if(C.uin>0){this.ev.fD(fo.lL+"/"+C.uin,C.iG());if(C.uin==gg.D.gp.get(gq.ty)){C.nG()}}C.fO(E);this.ev.fD(fo.le)},ms:function(B,C){var D=!gg.D.gp.get(gq.lC);if(typeof C.group!="undefined"){this.contactGroups[this.bR[C.group]].fO(C.nl)}},hG:function(){var B=this.bL();if(B.length<1){gg.lK.hw.error(null,nz.oh);return }B.each(function(D,C){this.ev.fD(fo.kU,D.iG())}.bind(this));this.hf()},hq:function(){var B=this.bL();var C=this;if(B.length<1){gg.lK.hw.error(null,nz.ob);return }gg.lK.hw.confirm(nz.oD,B.collect(function(D){return D.visible+" ("+D.uin+")"}).join(", "),function(D){if(D==gg.lK.hw.mN){return }B.each(function(F,E){C.aZ(F)});C.ev.fD(fo.kO,{uin:"",description:""})});this.ev.fD(fo.le)},eL:function(){var B=this.bL();if(B.length<1){gg.lK.hw.error(null,nz.pg);return }gg.lK.hw.confirm(nz.lE,B.collect(function(C){return C.visible+" ("+C.uin+")"}).join(", "),function(C){if(C==gg.lK.hw.mN){return }var D=[];B.each(function(F,E){D.push(F.uin);this.ev.fD(fo.kG+"/"+F.uin,{uin:F.uin,nm:true})}.bind(this));this.hf();this.ev.fD(fo.lf,D);this.ev.fD(fo.ln,this.gL)}.bind(this))},qj:function(C,B){if(!this.gI){return }this.gI.innerHTML=(B.uin>0?B.uin:"")+(B.description==""?"":" | "+B.description)},pE:function(){var B=this.bL();for(var D=0;D<B.length;D++){if(!B[D].my()){gg.lK.hw.error(null,nz.fP);return ;B.splice(D,1);D--}}if(B.length<1){gg.lK.hw.error(null,nz.pa);return }var C=this.aK(B).sort().toString();this.ev.fD(fo.kT,{id:C,title:C})},dM:function(B){this.ev.fD(fo.lL+"/"+B.uin,this.bG(B))},bG:function(C){var B=qn.kb;return{uin:C.uin,type:B,"private":0,status:typeof C.status!="undefined"?C.status:gg.D.protocol.gg.qn.jV,description:typeof C.description!="undefined"?C.description:"",uin:C.uin,visible:nz.tR,py:false,nm:(this.gL.indexOf(C.uin)>=0)}},bL:function(){var B=$A();for(var C=0;C<this.contactGroups.length;C++){B=B.concat(this.contactGroups[C].iK())}return B},iC:function(){var B=$A();for(var C=0;C<this.contactGroups.length;C++){B=B.concat(this.contactGroups[C].activeList,this.contactGroups[C].inactiveList)}return B},mn:function(C,D){var B={gK:$A(),mV:$A()};var E=this.iC();E.each(function(G,F){B.gK.push(G.iG())});this.gL.each(function(G,F){B.mV.push({name:"i",uin:G})});if(B.gK.length<1){gg.lK.hw.nh(null,nz.bS,function(){});return }this.ev.fD(fo.lv,B)},mo:function(C,B){this.ev.fD(fo.ln,this.gL)},lX:function(B){if(B instanceof Array){B.each(function(D,C){this.cg(D)}.bind(this))}else{this.cg(B)}},lY:function(B){if(B instanceof Array){B.each(function(D,C){this.ci(D)}.bind(this))}else{this.ci(B)}},sortGroups:function(){this.contactGroups.sort(gg.D.protocol.gg.gl);for(var B=0;B<this.contactGroups.length;B++){this.bR[this.contactGroups[B].groupName]=B;this.contactGroups[B].qW();this.gE.removeChild(this.contactGroups[B].container);this.gE.appendChild(this.contactGroups[B].container)}},cg:function(B){if(this.gL.indexOf(B)==-1){this.gL.push(B);this.ev.fD(fo.kG+"/"+B,{uin:B,nm:true})}},ci:function(B){this.gL=this.gL.without(B);this.ev.fD(fo.kG+"/"+B,{uin:B,nm:false})},dE:function(D,C){for(var E=0;E<this.contactGroups.length;E++){var B=this.contactGroups[E].ih(D,C);if(B!=null){return B}}return null},aZ:function(B){if(!B){return }this.ev.fD(fo.ld,B.iG());this.dM(B.iG());this.contactGroups[this.bR[B.group]].hu(B)}});if(typeof gg.D.lK.TabManager=="undefined"){gg.D.lK.TabManager=function(){}}Object.extend(gg.D.lK.TabManager,{create:function(C){var B=new this;B.init();B.createWindow();return B}});Object.extend(gg.D.lK.TabManager.prototype,{init:function(){var B=this;B.tabs=$A();B.ev=new gg.fv.gz();B.ev.mG(fo.kR,function(C,D){B.mi(C,D)});B.ev.mG(fo.kJ,function(C,D){B.lN(C,D)});B.ev.mG(fo.kK,function(C,D){B.lP(C,D)});B.ev.mG(fo.kP,function(C,D){B.lT(C,D)});B.ev.mG(fo.kv,function(C,D){B.md(C,D)});B.ev.mG(fo.ko,function(C,D){B.lO(C,D)});B.ev.mG(fo.kz,function(C,D){B.handleProfileTab(C,D)});B.ev.mG(fo.lo,function(C,D){B.rW()})},createWindow:function(){var C=this;C.TabPanel=new Ext.TabPanel({minTabWidth:20,enableTabScroll:true,animScroll:false,border:false,autoDestroy:false,region:"center",animCollapse:false,layoutOnTabChange:true,onStripMouseDown:function(E){E.preventDefault();if(E.button!=0){return }var D=this.findTargets(E);if(D.close){C.ev.fD(fo.kK,D.item.getPanelObj());return }if(D.item&&D.item!=this.activeTab){C.ev.fD(fo.kJ,D.item.getPanelObj())}},onItemTitleChanged:function(G,H,D){var F=this.getTabEl(G);if(F){var E=Ext.fly(F).child("span.x-tab-strip-text");E.update(H);if(D){$(F).addClassName("x-tab-with-icon");E.replaceClass(D,G.iconCls)}}},defaults:{autoScroll:true}});var B=gg.D.gp.get(gq.sA);C.TabWindow=new Ext.Window({id:"TabManager",closable:true,collapsible:false,constrain:true,maximizable:true,animCollapse:false,animScroll:false,width:B.width,height:B.height,minWidth:B.width,minHeight:B.height,x:Math.floor((document.body.offsetWidth-B.width-gg.D.gp.get(gq.qV).width)/3)+gg.D.gp.get(gq.qV).width+B.margin,y:B.top,border:false,split:true,plain:true,layout:"border",items:[C.TabPanel,{region:"north",border:false,height:50,html:!gg.D.gp.get(gq.cH)?"":'<div class="'+gg.D.lK.gS.MIW_BANNER+' x-toolbar"><iframe frameborder="0" class="'+gg.D.lK.gS.MIW_BANNER+'" src="http://adserver.gadu-gadu.pl/getbannerwebgg.asp?uid='+gg.D.gp.get(gq.ty)+'"></iframe></div>',minSize:50,nZ:50}],listeners:{beforeclose:function(){C.rW();return false}}});return C},tabs:{},rY:-1,pG:function(F,C,E,D){if(typeof D=="undefined"){var D={}}this.TabWindow.show();var B=gg.D.lK.sD.create(F,C,E,D);this.tabs.push(B);this.R(B);this.TabWindow.doLayout();B.panelLayout.expand();B.qh();this.TabWindow.doLayout();if(Ext.isSafari){B.panelLayout.hide();setTimeout(function(){B.panelLayout.show()}.bind(this),0)}return B},rW:function(){this.tabs.each(function(B){this.aC(B)}.bind(this));if(this.TabWindow.isVisible()){this.TabWindow.hide()}},mi:function(E,F){if(typeof F!="undefined"){if(typeof F.title=="undefined"&&typeof F.id!="undefined"){F.title=F.id.toString()}}switch(E){case fo.kT:var C=$A(F.id.toString().split(","));var B=(C.length>1);var D=this.dG(gg.D.lK.sD.tc.fR,F.id);if(D){this.R(D);return }this.pG(F.id,gg.D.lK.sD.tc.fR,F.title,{gm:B,qF:C});break;case fo.kX:break;case fo.kU:var G=typeof F.contactId!="undefined"?F.contactId:this.rY;var D=this.dG(gg.D.lK.sD.tc.hF,G);if(D){if(G<0){this.ds(D)}else{this.R(D);return }}this.pG(G,gg.D.lK.sD.tc.hF,F.contactId>0?nz.ph+": "+F.uin:nz.pU,F);break;case fo.kY:var D=this.dG(gg.D.lK.sD.tc.qm);if(D){this.R(D);return }this.pG(this.rY,gg.D.lK.sD.tc.qm,nz.mh);break;case fo.la:var D=this.dG(gg.D.lK.sD.tc.tp);if(D){this.R(D);return }this.pG(this.rY,gg.D.lK.sD.tc.tp,nz.nd);break;case fo.kS:var D=this.dG(gg.D.lK.sD.tc.eK);if(D){this.R(D);return }this.pG(this.rY,gg.D.lK.sD.tc.eK,nz.wN);break;case fo.kZ:var D=this.dG(gg.D.lK.sD.tc.qq);if(D){this.R(D);return }this.pG(this.rY,gg.D.lK.sD.tc.qq,nz.mL);break;case fo.kW:var D=this.dG(gg.D.lK.sD.tc.nv);if(D){this.R(D);return }D=this.pG(this.rY,gg.D.lK.sD.tc.nv,nz.mE,gg.D.lK.sD.ItemList.mW);this.ev.mG(fo.ln,D.ma.bind(D));this.ev.fD(fo.lc);break;case fo.kV:var D=this.dG(gg.D.lK.sD.tc.nv);if(D){this.R(D);return }this.pG(this.rY,gg.D.lK.sD.tc.nv,nz.mD);break;default:throw ("No params for open tab")}},md:function(B,C){},lN:function(C,B){if(B.mode==gg.D.lK.sD.MODE.ge){return }this.R(B)},lT:function(C,B){this.bb(B);delete B},lP:function(C,B){if(B.type==gg.D.lK.sD.tc.nK&&!gg.D.fv.ij.nt("comm.connected")){return }else{this.aC(B)}},lO:function(D,C){if(C.aw&qn.iR){return }var E=typeof C.qF=="undefined"?C.uin:C.qF.toString(),B=this.dG(gg.D.lK.sD.tc.fR,E);if(B){if(B.mode==gg.D.lK.sD.MODE.INACTIVE||(B.mode==gg.D.lK.sD.MODE.ge&&this.bu())){B.qu()}else{if(B.mode==gg.D.lK.sD.MODE.ge){}else{return }}this.ev.fD(fo.kQ,{uin:E,hy:B.title,message:C.qB,type:"message"});return }else{this.ev.mG(fo.lL+"/"+C.uin,function(G,F){this.aM(F,C)}.bind(this));this.ev.fD(fo.lk+"/"+C.uin,{uin:C.uin})}},aM:function(B,E){this.ev.tg(fo.lL+"/"+B.uin);if((!B.py&&!gg.D.gp.get(gq.tv))||B.nm){return }var C=typeof E.qF!="undefined";if(!C){E.qF={}}var G=C?E.qF.toString():E.uin.toString();var F=this.bt();var D=this.pG(G,gg.D.lK.sD.tc.fR,G,{gm:C,qF:E.qF});if(D.mode!=gg.D.lK.sD.MODE.ACTIVE){this.ev.fD(fo.kQ,{uin:G,hy:C?G:B.visible,message:E.qB,type:"message"})}D.mg(fo.ko,E)},handleProfileTab:function(D,C){var B=this.dG(gg.D.lK.sD.tc.qm,this.rY);if(!B){B=this.pG(this.rY,gg.D.lK.sD.tc.qm,"Profil")}},R:function(B){if(typeof B=="undefined"){return }B.active();this.TabWindow.show();this.TabPanel.activate(this.TabPanel.add(B.panelLayout.show()));B.panelLayout.doLayout();this.TabPanel.unhideTabStripItem(B.panelLayout)},aC:function(B){if(typeof B=="undefined"){return }B.close();this.TabPanel.hideTabStripItem(B.panelLayout.hide());var C=this.bu();if(C){this.R(C)}else{this.TabWindow.hide()}},bb:function(B){this.ds(B);var C=this.bu();if(C){this.R(C)}else{this.TabWindow.hide()}},aU:function(B){this.tabs.each(function(C){if(C!=B&&C.mode!=gg.D.lK.sD.MODE.ge){C.od()}})},ds:function(B){if(typeof B=="undefined"){return }this.TabPanel.remove(B.panelLayout);this.tabs=this.tabs.reject(function(C){return(C==B)});B.destroy()},aq:function(){},bv:function(){return this.tabs.findAll(function(C,B){return(C.mode==gg.D.lK.sD.MODE.ACTIVE||C.mode==gg.D.lK.sD.MODE.INACTIVE)})},bt:function(){return this.tabs.find(function(C,B){return(C.mode==gg.D.lK.sD.MODE.ACTIVE)})},bu:function(){return this.tabs.find(function(C,B){return(C.mode!=gg.D.lK.sD.MODE.ge)})},dG:function(B,C){return this.tabs.find(function(E,D){return typeof C!="undefined"?(E.id==C&&E.type==B):(E.type==B)})}});gg.D.lK.ak=function(){};Object.extend(gg.D.lK.ak,{create:function(){var B=new this;B.init();B.createWindow();return B}});Object.extend(gg.D.lK.ak.prototype,gg.D.lK.TabManager.prototype);Object.extend(gg.D.lK.ak.prototype,{createWindow:function(){var C=this;C.TabPanel=new Ext.Panel({layout:"accordion",closable:false,border:false,region:"center",layoutConfig:{enableTabScroll:true,hideCollapseTool:true,titleCollapse:true},defaults:{autoScroll:true},activate:function(D){D.expand()},unhideTabStripItem:function(D){},hideTabStripItem:function(){}});var B=gg.D.gp.get(gq.sA);C.TabWindow=new Ext.Panel({id:"TabManager",region:"center",closable:true,border:false,collapsible:false,maximizable:true,animCollapse:false,animScroll:false,border:false,split:true,plain:true,layout:"border",items:[C.TabPanel,{id:"TabManagerTopMenu",region:"north",border:false,height:33,html:!gg.D.gp.get(gq.cH)?"":'<div class="'+gg.D.lK.gS.vP+' x-toolbar"><iframe frameborder="0" class="'+gg.D.lK.gS.vP+'" src="http://adserver.gadu-gadu.pl/getmainbanner.asp?webgg=1"></iframe></div>',minSize:33,nZ:75},{id:"ContactManagerStatus",region:"south",border:false,height:25,html:"",minSize:25,nZ:25,listeners:{render:function(D){C.tG=new gg.D.lK.tH(D.body.dom)}}}],listeners:{beforeclose:function(){C.rW();return false},resize:function(){if(C.tG){C.tG.hide()}}}});return C}});gg.D.lK.sD.MODE={CLEAR:0,ACTIVE:1,qv:2,ge:3,DISABLED:4,INACTIVE:5};gg.D.lK.sD.tc={fR:1,nK:2,eS:3,hF:4,qm:5,tp:6,eK:7,qq:8,nv:9};Object.extend(gg.D.lK.sD,{sT:null,tabPanel:null,create:function(F,B,E,D){var C=new this;if(typeof D!="undefined"){Object.extend(C,D)}C.id=F;C.type=B;C.mode=gg.D.lK.sD.MODE.ACTIVE;C.title=E;C.sT=$A();C.ev=new gg.fv.gz();C.header=DIV({"class":gg.D.lK.gS.uW});C.pb=null;C.pd=C.header.appendChild(SPAN({"class":gg.D.lK.gS.vc,unselectable:"on",langr:C.title}));C.fC=DIV({"class":gg.D.lK.gS.ve}," ");C.content=DIV({"class":gg.D.lK.gS.uY});switch(C.type){case gg.D.lK.sD.tc.nK:Object.extend(C,gg.D.lK.sD.nJ);break;case gg.D.lK.sD.tc.fR:Object.extend(C,gg.D.lK.sD.fQ);break;case gg.D.lK.sD.tc.hF:Object.extend(C,gg.D.lK.sD.Contact);break;case gg.D.lK.sD.tc.qm:Object.extend(C,gg.D.lK.sD.ql);break;case gg.D.lK.sD.tc.tp:Object.extend(C,gg.D.lK.sD.tD);break;case gg.D.lK.sD.tc.eK:Object.extend(C,gg.D.lK.sD.eJ);break;case gg.D.lK.sD.tc.qq:Object.extend(C,gg.D.lK.sD.qt);break;case gg.D.lK.sD.tc.nv:Object.extend(C,gg.D.lK.sD.ItemList);break}C.panelLayout=new Ext.Panel({collapsed:false,header:true,layout:"fit",closable:true,border:false,animate:false,xtype:"panel",title:C.title,listeners:{render:function(G){G.body.dom.appendChild(C.content)},activate:function(G){C.active()},beforeexpand:function(G){C.active();return true},beforecollapse:function(G){C.od();return true},od:function(G){C.od()}},getPanelObj:function(){return C},setTitle:function(I,H){this.title=I;if(this.header&&this.headerAsText){this.header.child("span").update(I)}var G=this.iconCls;if(H){this.setIconClass(H)}this.fireEvent("titlechange",this,I,G);return this},setIconClass:function(H){var G=this.iconCls;this.iconCls=H;if(this.rendered&&this.header){if(this.frame){this.header.addClass("x-panel-icon");this.header.replaceClass(G,this.iconCls)}else{var J=this.header.dom;var I=J.firstChild&&J.getElementsByTagName("IMG")[0]?J.getElementsByTagName("IMG")[0]:null;if(I){Ext.fly(I).replaceClass(G,this.iconCls)}else{Ext.DomHelper.insertBefore(this.header.child("span"),{tag:"img",src:Ext.BLANK_IMAGE_URL,cls:"x-panel-inline-icon "+this.iconCls})}}}},scope:C});C.panelLayout.doLayout();if(gg.D.gp.get(gq.cT)){C.panelLayout.on("render",function(G){var H=DIV({"class":"x-tool"});$(G.header.dom.firstChild).insert({before:H});Event.observe(H,"click",function(I){I.stop();C.ev.fD(fo.kK,C)})})}return C}});Object.extend(gg.D.lK.sD.prototype,{active:function(){this.mode=gg.D.lK.sD.MODE.ACTIVE;if(typeof this.Q=="function"){this.Q()}},od:function(){if(this.mode!=gg.D.lK.sD.MODE.ge){this.mode=gg.D.lK.sD.MODE.INACTIVE}},qu:function(){alert("bede pulsowac"+this.id)},close:function(B){this.mode=gg.D.lK.sD.MODE.ge},destroy:function(){this.panelLayout.destroy();try{delete this}catch(B){var C=this;C=null}},ay:function(){},be:function(C,B){},bf:function(B){},qh:function(){alert("Brak qh!")},rS:function(){var B=IMG({"class":gg.D.lK.gS.va,src:"./img/wait-small.gif"});if(this.pb==null){this.header.insertBefore(B,this.pd)}else{this.cJ=this.header.replaceChild(B,this.pb)}this.pb=B},mC:function(){if(this.pb===null){return }if(this.cJ==null){try{this.header.removeChild(this.pb)}catch(B){}}else{this.header.replaceChild(this.cJ,this.pb)}this.pb=this.cJ;this.cJ=null}});if(typeof gg.D.lK.sD.nJ=="undefined"){gg.D.lK.sD.nJ=function(){}}Object.extend(gg.D.lK.sD.nJ,{bA:null,eb:null,bs:null,qh:function(){var D=new Ext.Button({text:nz.dO,icon:/^https/.test(window.location)?"/img/hmenu-lock.gif":false,cls:/^https/.test(window.location)?"x-btn-text-icon":"",handler:function(){E.submit()}});var B=new Ext.Button({text:nz.xm,handler:function(){window.open(nz.xl)}});var F=new Ext.Toolbar();function C(){var G=window.location.toString().match(/uin=([0-9]+)$/);return G&&typeof G[1]!="undefined"?G[1]:gg.D.gp.get(gq.ty)}var E=new Ext.form.FormPanel({tbar:F,onSubmit:Ext.emptyFn,submit:function(){var G=this.form.getForm().getValues();var I={};if(!sC(G.gg)){I.gg=nz.gx}if(G.pass==""||G.pass.length>16){I.pass=nz.dT}if(I.gg||I.pass){this.form.getForm().markInvalid(I);D.enable();return false}gg.D.gp.set(gq.ty,G.gg);gg.D.gp.set(gq.tz,G.pass);var H=new Array();H[gq.ty]=G.gg;H[gq.tz]=G.pass;new gg.fv.gz().fD(fo.lw,H)}.bind(this),border:false,bodyStyle:"padding:10px;",autoHeight:true,autoWidth:true,method:"POST",url:"/login",standardSubmit:true,items:[{xtype:"fieldset",buttonAlign:"center",bodyStyle:"margin: 10px 10px 0 10px;",style:"margin-bottom: 0;",autoHeight:true,defaultType:"textfield",items:[{fieldLabel:nz.iB,name:"gg",value:C()},{fieldLabel:nz.wI,name:"pass",value:gg.D.gp.get(gq.tz),inputType:"password"}],buttons:[D]}]});this.form=E;this.panelLayout.add(E);E.on("afterlayout",function(G){if($("ggc-safe-ssl")){return }G.getForm().getEl().dom.select(".x-fieldset-footer")[0].insert('<div id="ggc-safe-ssl" style="text-align: center;">'+nz.xv+": "+(/^https/.test(window.location)?'<a href="'+window.location.toString().replace("https","http")+'" target="_self">'+nz.xo+"</a> | "+nz.xn:nz.xo+' | <a href="'+window.location.toString().replace("http","https")+'" target="_self">'+nz.xn+"</a>")+"</div>");G.getForm().getEl().dom.insert('<div class="x-fieldset" style="border-top: none;margin-top: 0px;padding-top: 10px;"><div style="float: right;" id="gg-register-button"></div>'+nz.xu+"</div>");new Ext.Button({renderTo:"gg-register-button",text:nz.xm,handler:function(){window.location=nz.xl+window.location.toString().replace(/[\/]+\?uin=.*/,"").replace("/","%2F")+"%2F%3Fuin%3D"}})});E.on("render",function(G){var H=new Ext.KeyNav(G.getForm().getEl(),{enter:function(I){G.submit()}});G.getForm().getEl().dom.onsubmit=function(){G.submit();return false};checkHandler=function(I){if(I.value!=gg.D.gp.get(gq.xG)){gg.D.gp.set(gq.xG,I.value);gg.D.gp.xF();window.location.reload()}};F.add({xtype:"tbtext",text:gg.D.gp.get(gq.fd)+" "+gg.D.gp.get(gq.fe)});F.addFill();F.add({text:'<img src="/img/flags/'+gg.D.gp.get(gq.xG)+'.gif" /> '+nz.xt,menu:new Ext.menu.Menu({items:[{text:nz.xw,value:"pl",checked:gg.D.gp.get(gq.xG)=="pl",checkHandler:checkHandler,group:"language",icon:"/img/flags/pl.gif"},{text:nz.xy,value:"en",checked:gg.D.gp.get(gq.xG)=="en",checkHandler:checkHandler,group:"language",icon:"/img/flags/gb.gif"}]})})})}});if(typeof gg.D.lK.sD.fQ=="undefined"){gg.D.lK.sD.fQ=function(){}}Object.extend(gg.D.lK.sD.fQ,{qh:function(){this.gH=this.title;this.gA={};var B=[{border:false,region:"center",margins:"0",minSize:100},{region:"south",split:true,border:false,height:gg.D.gp.get(gq.cT)?50:150,minSize:150,nZ:350,margins:"0"}];if(this.gm){B.push({border:false,region:"east",margins:"0",minSize:100,width:100,split:true,nZ:200})}this.chatPanel=new Ext.Panel({layout:"border",split:true,border:false,margins:"0 0 0 0",footer:true,buttonAlign:"right",plain:true,items:B});var C={enter:this.chatPanel.addButton({name:"enter",cls:"x-btn-icon enter",minWidth:32,enableToggle:true}),send:this.chatPanel.addButton({text:nz.sh,name:"send"})};this.panelLayout.add(this.chatPanel);this.panelLayout.doLayout();this.tn({status:gg.D.protocol.gg.qn.jV});if(this.gm){var E=$(this.chatPanel.getComponent(2).body.dom).addClassName(gS.vb+" ChatMessageWindow "+gS.wa);var D=new gg.D.lK.gD(E);this.qF.each(function(G,F){D.pF(G,G,false)});D.qN(this.pd);this.am(gg.D.lK.gS.cZ)}else{this.ev.mG(fo.kG+"/"+this.id,function(F,G){this.mu(F,G)}.bind(this));this.ev.mG(fo.lL+"/"+this.id,function(F,G){this.mu(F,G)}.bind(this));this.ev.fD(fo.lk+"/"+this.id,{uin:this.id});setTimeout(function(){this.ev.fD(fo.lk+"/"+this.id,{uin:this.id})}.bind(this),3000)}this.iD=(!this.gm)?function(F){return this.title}.bind(this):function(F){return D.getName(F)};this.oR=new gg.D.lK.ChatMessageWindow(this.chatPanel.getComponent(0).body.dom);this.eg=!gg.D.gp.get(gq.cT)?new gg.D.lK.fS(this.chatPanel.getComponent(1),C,function(){this.submitMessage();return false}.bind(this),function(){this.oR.clear()}.bind(this),this.gm?function(){D.hG()}:function(){this.ev.fD(fo.kU,this.gA)}.bind(this),this.gm?null:function(){this.fl()}.bind(this),this.gm?null:function(){this.ev.fD(fo.lm,{uin:this.gA.uin})}.bind(this),function(F){this.ev.fD(fo.lz,{uin:this.id,status:F})}.bind(this),function(){this.ev.fD(fo.kK,this)}.bind(this),function(){this.yq()}.bind(this)):new gg.D.lK.T(this.chatPanel.getComponent(1),C,function(){this.submitMessage();return false}.bind(this),function(){this.oR.clear()}.bind(this),this.gm?function(){D.hG()}:function(){this.ev.fD(fo.kU,this.gA)}.bind(this),this.gm?null:function(){this.fl()}.bind(this),this.gm?null:function(){this.ev.fD(fo.lm,{uin:this.gA.uin})}.bind(this),function(F){this.ev.fD(fo.lz,{uin:this.id,status:F})}.bind(this),function(){this.ev.fD(fo.kK,this)}.bind(this),function(){this.yq()}.bind(this));this.panelLayout.on("activate",function(){this.focus()},this.eg);this.panelLayout.on("expand",function(){this.focus()},this.eg);gg.D.fv.ij.nt("comm.connected")?this.eg.enable():this.eg.disable();this.chatPanel.on("resize",function(){this.oR.vz()},this);if(Ext.isIE){this.panelLayout.on("show",function(F){if(this.chatPanel.getComponent(1).getSize().height<1){this.chatPanel.getComponent(1).setHeight(150)}},this)}this.ev.mG(fo.ko+"/"+this.id,function(F,G){this.mg(F,G)}.bind(this));this.ev.mG(fo.ks,function(F,G){this.lU(F,G)}.bind(this));this.ev.mG(fo.kx,function(F,G){this.mc(F,G)}.bind(this))},mu:function(B,C){if(this.id!=C.uin){return }(typeof C.visible!="undefined")&&(this.gH=C.visible);this.tn(C)},mg:function(B,D){if((D.aw&qn.iS)||(D.aw&qn.iQ)){var C=D.msg.linkUrls();if(!this.gA.nm){this.oR.eW(D.uin,C,this.iD(D.uin),D.time*1000)}}else{this.oR.eU(D.uin,D.msg)}},lU:function(B,C){if(!this.gm){this.tn({status:gg.D.protocol.gg.qn.jV})}this.eg.disable()},mc:function(B,C){this.eg.enable()},submitMessage:function(){var B=this.eg.getContent();if((Ext.isSafari||Ext.isOpera)&&B.length<2&&B.charCodeAt(0)==160){this.eg.clear();return false}if(B==""||B=="&nbsp;"){return false}if(this.status==qn.jP){gg.lK.hw.error(null,nz.gd);return }var D=this.gm?this.qF:this.id;var C={qG:D,msg:B};setTimeout(function(){this.oR.addOutgoing(gg.D.gp.get(gq.ty),gg.D.protocol.gg.oz.qc(C.msg).linkUrls(),gg.D.gp.get(gq.tP))}.bind(this),0);this.ev.fD(fo.lq+"/"+D,C);this.eg.clear()},tn:function(D){if(typeof D!="undefined"){if(typeof D.status!="undefined"){this.status=D.status}if(typeof D.visible!="undefined"&&D.py){this.title=D.visible;this.panelLayout.setTitle(this.title)}Object.extend(this.gA,D)}if(typeof this.qk=="undefined"){this.qk=null}var B=gg.D.gp.get(gq.pm)&&(typeof this.oR!="undefined"),C='<span class="'+gg.D.lK.gS.MIW_NOTIFY_USERNAME_CLASS+'">'+this.title+"</span> ";switch(this.status){case qn.jV:case qn.jW:this.am(gS.wF);if(this.qk!=qn.jV){B&&this.oR.eU(D.uin,C+nz.wO+" "+nz.st)}this.qk=qn.jV;break;case qn.jN:case qn.jO:this.am(gS.wC);if(this.qk!=qn.jN){if(this.qk!=qn.jV){B&&this.oR.eU(D.uin,C+nz.wO+" "+nz.sM)}}this.qk=qn.jN;break;case qn.jQ:case qn.jR:this.am(gS.wB);if(this.qk!=qn.jQ){B&&this.oR.eU(D.uin,C+nz.wO+" "+nz.sz)}this.qk=qn.jQ;break;case qn.jT:case qn.jU:this.am(gS.vd);if(this.qk!=qn.jV){B&&this.oR.eU(D.uin,C+nz.wO+" "+nz.st)}this.qk=qn.jV;break;case qn.jP:this.am(gS.wE);if(this.qk!=qn.jP){B&&this.oR.eU(D.uin,C+nz.eO)}this.qk=qn.jP;break;default:this.am(gS.wF);if(this.qk!=qn.jV){B&&this.oR.eU(D.uin,C+nz.wO+" "+nz.st)}this.qk=qn.jV}},fl:function(){gg.lK.hw.confirm(nz.lE,this.gH+" ("+this.id+")",function(B){if(B==gg.lK.hw.mN){return }this.ev.fD(fo.lf,[this.id]);this.ev.fD(fo.ln,[this.id])}.bind(this))},yq:function(){gg.D.lK.oj.create(this.oR.om(),this.title)},qu:function(){this.am(gg.D.lK.gS.cZ)},Q:function(){this.tn()},am:function(B){this.panelLayout.setTitle(this.panelLayout.title,B)}});if(typeof gg.D.lK.sD.ql=="undefined"){gg.D.lK.sD.ql=function(){}}Object.extend(gg.D.lK.sD.ql,{bA:null,eb:null,qh:function(){this.form=new Ext.form.FormPanel({onSubmit:Ext.emptyFn,border:false,bodyStyle:"padding:10px 10px 0;",autoHeight:true,submit:function(){var B=this.form.getForm().getValues();if(B.birthyear<1902||B.birthyear>new Date().getFullYear()){this.form.getForm().markInvalid({birthyear:nz.xz});return false}if(this.form.getForm().isValid()){this.sx(B)}return false}.bind(this),autoWidth:true,items:[{labelWidth:150,xtype:"fieldset",autoHeight:true,collapsible:false,defaultType:"textfield",items:[{fieldLabel:nz.dW,name:"firstname",value:"",anchor:"90%"},{fieldLabel:nz.dV,name:"lastname",value:"",anchor:"90%"},new Ext.form.ComboBox({fieldLabel:nz.nB,hiddenName:"gender",store:new Ext.data.SimpleStore({fields:["gender","id"],data:[[nz.xC,0],[nz.rV,1],[nz.rT,2]]}),valueField:"id",displayField:"gender",disableKeyFilter:true,value:0,editable:false,mode:"local",triggerAction:"all",selectOnFocus:true,width:165}),{fieldLabel:nz.ni,name:"birthyear",id:"birthyear",value:"",anchor:"90%"},{fieldLabel:nz.nC,name:"city",value:"",anchor:"90%"},{fieldLabel:nz.nx,name:"familyname",value:"",anchor:"90%"}]}],buttons:[{text:nz.nf,handler:function(){this.form.submit()}.bind(this)}]});this.panelLayout.add(this.form);this.ev.mG(fo.kA,this.mk.bind(this));this.ev.mG(fo.kB,this.ml.bind(this))},sx:function(B){Form.disable(this.form.getForm().el.dom);this.ev.fD(fo.lx,B)},mk:function(C,B){this.form.getForm().loadRecord(new Ext.data.Record({gender:typeof B.gender!="undefined"?B.gender:0,firstname:typeof B.firstname!="undefined"?B.firstname:"",lastname:typeof B.lastname!="undefined"?B.lastname:"",birthyear:typeof B.birthyear!="undefined"?B.birthyear:"",city:typeof B.city!="undefined"?B.city:"",familyname:typeof B.familyname!="undefined"?B.familyname:""}));Form.enable(this.form.getForm().el.dom)},ml:function(C,B){this.ev.fD(fo.kK,this);Form.disable(this.form.getForm().el.dom)}});if(typeof gg.D.lK.sD.tD=="undefined"){gg.D.lK.sD.tD=function(){}}Object.extend(gg.D.lK.sD.tD,{bA:null,eb:null,dU:{},qh:function(){var F=[gq.tP,gq.xG,gq.ts,gq.tq,gq.tC,gq.tv,gq.tw,gq.tx,gq.lD,gq.pm,gq.pl,gq.eP,gq.yo,gq.yn,gq.ym];var B=gg.D.gp.iH(F);var E=null;var G=null;var C=new Ext.form.Checkbox({fieldLabel:nz.sv,name:gq.yn,checked:Boolean(gg.D.gp.get(gq.yn)),listeners:{check:{fn:function(I,H){if(H){D.enable()}else{D.disable()}}}}});var D=new Ext.form.Checkbox({fieldLabel:nz.pS,name:gq.ym,checked:Boolean(gg.D.gp.get(gq.ym))});this.form=new Ext.form.FormPanel({onSubmit:Ext.emptyFn,border:false,bodyStyle:"padding:10px 10px 0;",autoHeight:true,submit:function(){var H=this.form.getForm().getValues();if(this.form.getForm().isValid()){this.sy(H)}return false}.bind(this),autoWidth:true,items:[{labelWidth:150,xtype:"fieldset",autoHeight:true,collapsible:false,defaultType:"textfield",plain:true,items:[{fieldLabel:nz.pf,name:gq.tP,value:B[gq.tP]}]},{xtype:"fieldset",autoHeight:true,collapsible:true,defaultType:"checkbox",title:nz.oF,labelWidth:320,items:[{fieldLabel:nz.oG,name:gq.tw,value:"1",checked:Boolean(gg.D.gp.get(gq.tw))},{fieldLabel:nz.nL,name:gq.lD,value:"1",checked:Boolean(gg.D.gp.get(gq.lD))},{fieldLabel:nz.oV,name:gq.pm,value:"1",checked:Boolean(gg.D.gp.get(gq.pm))},{fieldLabel:nz.oE,name:gq.pl,value:"1",checked:Boolean(gg.D.gp.get(gq.pl))},{fieldLabel:nz.ho,name:gq.eP,value:"1",checked:Boolean(gg.D.gp.get(gq.eP))}]},{xtype:"fieldset",autoHeight:true,collapsible:true,defaultType:"checkbox",title:nz.sG,labelWidth:320,items:[{fieldLabel:nz.wX,name:gq.yo,checked:Boolean(gg.D.gp.get(gq.yo))},C,D]}],buttons:[{text:nz.gy,handler:function(){this.form.submit()}.bind(this)}]});this.panelLayout.add(this.form)},sy:function(B){B[gq.tw]=typeof B[gq.tw]!="undefined";B[gq.lD]=typeof B[gq.lD]!="undefined";B[gq.pm]=typeof B[gq.pm]!="undefined";B[gq.pl]=typeof B[gq.pl]!="undefined";B[gq.eP]=typeof B[gq.eP]!="undefined";B[gq.yo]=typeof B[gq.yo]!="undefined";B[gq.yn]=typeof B[gq.yn]!="undefined";B[gq.ym]=typeof B[gq.ym]!="undefined";gg.fv.sq.set("userData",B);gg.D.gp.bind(B);this.ev.fD(fo.kK,this)}});if(typeof gg.D.lK.sD.eJ=="undefined"){gg.D.lK.sD.eJ=function(){}}Object.extend(gg.D.lK.sD.eJ,{count:0,ui:null,bA:null,eb:null,dU:{},qh:function(){var B=gg.D.gp.get(gq.fd)+" "+gg.D.gp.get(gq.fe);this.form=new Ext.form.FormPanel({onSubmit:Ext.emptyFn,border:false,bodyStyle:"padding:10px 10px 0;font-size:10pt;",width:"90%",autoHeight:true,submit:function(){this.ev.fD(fo.ls,{description:B});return false}.bind(this),labelWidth:100,items:[{html:'<p style="margin: 10px;"><span style="font-weight: bold;"><canvas id="canvasgaduLogo" style="float: right;" width="75" height="75"></canvas>'+B+"</span><br/>"+nz.ro.oY()+"</span>"}],buttons:[{text:nz.xY,handler:function(){this.form.submit()}.bind(this)}],listeners:{afterlayout:function(){var C=document.getElementById("canvasgaduLogo");if(!C){return }if(typeof C.getContext!="function"||gg.D.lK.sD.eJ.ui){return }gg.D.lK.sD.eJ.wZ();gg.D.lK.sD.eJ.ui=setInterval(gg.D.lK.sD.eJ.wZ,50)}}});this.panelLayout.add(this.form);this.panelLayout.on("beforehide",function(){if(!gg.D.lK.sD.eJ.ui){return }clearInterval(gg.D.lK.sD.eJ.ui);gg.D.lK.sD.eJ.ui=null})},wZ:function(){this.ui=true;var C=document.getElementById("canvasgaduLogo").getContext("2d");var B=new Date();C.save();C.clearRect(0,0,152,152);C.scale(0.5,0.5);gg.D.lK.sD.eJ.count++;C.strokeStyle="rgb(241,6,0)";C.save();C.translate(75,75);C.lineWidth=25;C.lineCap="butt";C.rotate(-gg.D.lK.sD.eJ.count*3);for(i=0;i<6;i++){C.beginPath();C.rotate(Math.PI/3);C.moveTo(0,0);C.lineTo(0,75);C.stroke()}C.restore();C.lineWidth=9;C.lineCap="round";C.fillStyle="rgb(255,192,0)";C.strokeStyle="rgb(241,6,0)";C.beginPath();C.arc(75,75,50,0,Math.PI*2,true);C.fill();C.stroke();C.beginPath();C.moveTo(105,75);C.lineWidth=7;C.strokeStyle="rgb(0,0,0)";C.arc(75,75,30,0,Math.PI,false);C.moveTo(57,65);C.arc(60,65,3,0,Math.PI*2,true);C.moveTo(87,65);C.arc(90,65,3,0,Math.PI*2,true);C.stroke();C.restore()}});if(typeof gg.D.lK.sD.Contact=="undefined"){gg.D.lK.sD.Contact=function(){}}Object.extend(gg.D.lK.sD.Contact,{bA:null,eE:null,_autofillFrom:null,qh:function(){var C=null;var D=null;var B=null;this.form=new Ext.form.FormPanel({onSubmit:Ext.emptyFn,border:false,bodyStyle:"padding:10px 10px 0",autoHeight:true,submit:function(){if(this.form.getForm().isValid()){this.su(this.form.getForm().getValues())}return false}.bind(this),labelWidth:200,items:[{xtype:"fieldset",autoHeight:true,collapsible:false,defaultType:"textfield",items:[{fieldLabel:nz.iM,name:"uin",value:this.uin,anchor:"90%"},{name:"oldUIN",value:this.uin,inputType:"hidden"},{name:"contactId",value:this.contactId,inputType:"hidden"},{fieldLabel:nz.tQ,name:"hy",value:this.hy||this.name||this.uin,anchor:"90%"},{fieldLabel:nz.pV,name:"group",value:this.group,anchor:"90%"}]},{xtype:"fieldset",autoHeight:true,collapsible:true,defaultType:"textfield",title:nz.pH,items:[{fieldLabel:nz.pW,name:"ht",value:this.ht,anchor:"90%"},{fieldLabel:nz.qT,name:"mail",value:this.iA,anchor:"90%"},{fieldLabel:nz.qU,name:"hE",value:this.hE,anchor:"90%"}]},{xtype:"fieldset",autoHeight:true,collapsible:true,defaultType:"textfield",title:nz.tu,items:[{fieldLabel:nz.dW,name:"name",value:this.name,anchor:"90%"},{fieldLabel:nz.dV,name:"hB",value:this.hB,anchor:"90%"}]}],buttons:[{text:nz.gy,handler:function(){this.form.submit()}.bind(this)}]});this.panelLayout.add(this.form)},su:function(C){var D=true;var E={};for(var B in C){if(C[B].toString().indexOf(";")>=0){D=false}}C.visible_name=C.hy;if(C.hy.length<1){E.hy=nz.uD}else{if(C.uin==gg.D.gp.get(gq.ty)){E.uin=nz.uE}else{if(!C.uin.toString().match(/^[0-9]+$/)){E.uin=nz.gx}else{if(!D){E.visible_name=nz.uF}else{this.ev.mG(fo.xJ+"/"+C.uin,function(F,G){this.ev.tg(fo.xJ+"/"+C.uin);if((G.uin||G.visible)&&C.contactId==""){if(G.uin){E.uin=nz.xM}if(G.visible){E.hy=nz.xL}this.form.getForm().markInvalid(E);return false}this.ev.fD(fo.lk+"/"+C.uin,{uin:C.uin});this.ev.fD(fo.hC,{uin:C.uin,oldUin:C.oldUin,visible_name:C.visible_name,visible:C.visible_name,hy:C.hy,name:C.name,hB:C.hB,ht:C.ht,group:C.group,iI:C.iI,iA:C.mail,hE:C.hE,contactId:C.contactId});this.ev.fD(fo.kK,this);return false}.bind(this));this.ev.fD(fo.xK+"/"+C.uin,{uin:C.uin,visible:C.visible_name});return false}}}}this.form.getForm().markInvalid(E);return false}});if(typeof gg.D.lK.sD.ItemList=="undefined"){gg.D.lK.sD.ItemList=function(){}}Object.extend(gg.D.lK.sD.ItemList,{button:null,qh:function(){this.button=new Ext.Button({text:nz.tO,handler:function(){this.form.submit()}.bind(this)});this.form=new Ext.form.FormPanel({onSubmit:Ext.emptyFn,border:false,bodyStyle:"padding:10px 10px 0",width:"90%",autoHeight:true,submit:function(){if(this.form.getForm().isValid()){this.submit(this.form.getForm().getValues())}return false}.bind(this),labelWidth:100,items:{html:nz.lB},buttons:[this.button]});this.button.hide();this.panelLayout.add(this.form)}});gg.D.lK.sD.ItemList.mW={ma:function(D,C){var B=$A();this.form.remove(this.form.getComponent(0),true);if(C.length>0){C.each(function(E){B.push({fieldLabel:E,name:"uin_il_"+E,inputValue:E})});this.form.add({xtype:"fieldset",autoHeight:true,collapsible:false,defaultType:"checkbox",items:B});this.button.show()}else{this.form.add({html:nz.lB});this.button.hide()}this.panelLayout.doLayout()},submit:function(B){this.ev.fD(fo.lg,Object.values(B));this.ev.fD(fo.lc)}};if(typeof gg.D.lK.sD.qt=="undefined"){gg.D.lK.sD.qt=function(){}}Object.extend(gg.D.lK.sD.qt,{bA:null,ee:null,eb:null,cv:null,co:null,busy:false,cw:0,__submitClick:null,H:null,G:null,qh:function(){this.ev.mG(fo.kE,function(C,B){this.mr(C,B)}.bind(this));this.ev.mG(fo.ll,function(C,B){if(C==fo.lm){return }this.rw(B.uin)}.bind(this));this.form=new Ext.form.FormPanel({onSubmit:Ext.emptyFn,border:false,layout:"column",bodyStyle:"padding:10px 10px 0;",autoHeight:true,maskDisabled:false,submit:function(){this.search();return false}.bind(this),autoWidth:true,items:[{columnWidth:0.5,xtype:"fieldset",defaultType:"textfield",autoHeight:true,border:false,collapsible:false,items:[{fieldLabel:nz.sV,name:"firstname",id:"firstname",value:"",anchor:"90%"},{fieldLabel:nz.dV,name:"lastname",value:"",anchor:"90%"},{fieldLabel:nz.sU,name:"nickname",value:"",anchor:"90%"},{fieldLabel:nz.tE,name:"city",value:"",anchor:"90%"},{fieldLabel:nz.rU,name:"FmNumber",id:"FmNumber",value:"",anchor:"90%"}]},{columnWidth:0.5,xtype:"fieldset",defaultType:"textfield",autoHeight:true,border:false,collapsible:false,items:[{fieldLabel:nz.pe+" "+nz.uO,name:"fa",value:"",anchor:"90%"},{fieldLabel:nz.mf,name:"fb",value:"",anchor:"90%"},{fieldLabel:nz.rV,name:"ix",value:"",xtype:"checkbox",anchor:"90%"},{fieldLabel:nz.rT,name:"iw",value:"",xtype:"checkbox",anchor:"90%"},{fieldLabel:nz.ng,name:"ActiveOnly",xtype:"checkbox",value:"",anchor:"90%"}]}]});this.form.on("render",function(B){var C=new Ext.KeyNav(B.getForm().getEl(),{enter:function(D){B.submit()}});B.getForm().getEl().dom.onsubmit=function(){B.submit();return false}});this.moreButton=new Ext.Button({text:nz.nu,disabled:true,handler:function(){this.oJ()}.bind(this)});this.searchButton=new Ext.Button({text:nz.nn,handler:function(){this.form.submit()}.bind(this)});this.mainPanel=new Ext.Panel({layout:"border",border:false,items:[{region:"center",border:false,listeners:{render:function(C){var B,D;D=C.body.dom.appendChild(DIV({id:"pubdirResultsContainer"}));D.appendChild(B=TABLE({id:gS.PBS_TABLEID},THEAD(TR(TD(nz.tX),TD(nz.uw),TD(nz.ut),TD(nz.uo),TD())),this.ee=TBODY()))}.bind(this)}},{region:"south",border:false,height:140,items:[this.form]}],buttons:[this.searchButton,this.moreButton]});this.panelLayout.add(this.mainPanel)},search:function(F){var F=F||false;var B=this.form.getForm().getValues(),E=["firstname","lastname","nickname","ix","iw","fa","fb","city","FmNumber"];empty=true;for(var D=0,C=E.length;D<C;D++){if(typeof B[E[D]]!="undefined"&&B[E[D]]!=""){empty=false}B[E[D]]=gg.D.protocol.gg.gN.sY(B[E[D]])}if(F){B[gg.D.protocol.gg.qn.qp.jF]=this.cw}if(empty){gg.lK.hw.error(null,nz.tF);return }this.busy=true;this.form.disable();this.searchButton.disable();this.ev.fD(fo.kD,B);this.rS()},rw:function(B){if(this.busy){return }if(sC(B)){this.form.getForm().setValues([{id:"FmNumber",value:B}])}else{this.form.getForm().setValues([{id:"firstname",value:B}])}this.search()},oJ:function(){this.search(true)},mr:function(G,B){this.busy=false;while(this.ee.rows.length){this.ee.deleteRow(0)}var H,N,F;var H=new Date().getFullYear();F=B.results;si=["",gS.PBS_STATUS_UNAVAILABLE,gS.PBS_STATUS_AVAILABLE,gS.PBS_STATUS_BUSY,gS.PBS_STATUS_AVAILABLE,gS.PBS_STATUS_BUSY];var L=function(){var Q={uin:this.eB[0]},P;P=this.eB[2]==""?this.eB[1]:this.eB[2];Q.visible=P.unescapeHTML();Q.hy=this.eB[2].unescapeHTML();Q.name=this.eB[1].unescapeHTML();new gg.fv.gz().fD(fo.kU,Q)};var C=function(){var P={id:this.eB,title:this.eB};new gg.fv.gz().fD(fo.kT,P)};var M,K;for(var E=0,I=F.length-1;E<I;E++){var O=[],J=TR(TD({"class":"status "+si[F[E]["FmStatus"]]},F[E]["FmNumber"]));if(typeof F[E]["firstname"]!="undefined"){O.push(F[E]["firstname"])}if(typeof F[E]["nickname"]!="undefined"){O.push(F[E]["nickname"])}var D=J.appendChild(TD());D.innerHTML=O.join(", ");J.appendChild(TD(typeof F[E]["birthyear"]=="undefined"||F[E]["birthyear"]=="0"?"":(H-F[E]["birthyear"]<0?H-F[E]["birthyear"]+1990:H-F[E]["birthyear"]).toString()));D=J.appendChild(TD());D.innerHTML=typeof F[E]["city"]=="undefined"?"":F[E]["city"];J.appendChild(TD({"class":gS.PBS_TDBUTTONS},M=BUTTON({"class":"PubdirSearchAdd",style:"cursor:pointer;"}),K=BUTTON({"class":"PubdirSearchChat",style:"cursor:pointer;"})));this.ee.appendChild(J);M.eB=[F[E]["FmNumber"],F[E]["firstname"]||"",F[E]["nickname"]||""];M.onclick=L;K.eB=F[E]["FmNumber"];K.onclick=C}this.form.enable();this.searchButton.enable();this.cw=0;if(F.length>0&&typeof F[F.length-1].nextstart!="undefined"){this.cw=F[F.length-1].nextstart;if(F[F.length-1].nextstart!="0"){this.moreButton.enable()}else{this.moreButton.disable()}}else{this.moreButton.disable()}setTimeout(function(){this.mC()}.bind(this),0)}});gg.D.lK.ChatMessageWindow=function(B){this.cF=$(B);this._init()};Object.extend(gg.D.lK.ChatMessageWindow,{oT:gg.D.lK.gS.MIW_INCOMMING_CLASS,oU:gg.D.lK.gS.MIW_OUTGOING_CLASS,oS:gg.D.lK.gS.MIW_EVENT_CLASS});Object.extend(gg.D.lK.ChatMessageWindow.prototype,{bC:null,cF:null,bQ:null,_lastUIN:null,_init:function(){this.bC=gg.D.gp.get(gq.tP);this.cF.addClassName(gg.D.lK.gS.MIW_BASE_CLASS)},bO:function(B){return(B===null?new Date():new Date(B)).toLocaleTimeString().substring(0,this.bQ?5:8)},bU:null,bT:null,t:t=new Ext.Template('<div class="{classMsg}">',' <div class="avatar">','    <a target="_blank" href="http://www.mojageneracja.pl/{uin}"><img src="http://www.mojageneracja.pl/{uin}/avatar/img/0" /></a>'," </div>",' <div class="header">',"   <h1><span>{fromName}</span></h1>","  </div>",'  <div class="body">','    <div class="message {first_message}">','     <p class="date">',"        {time}","     </p>",'      <p class="content">',"        {message}","      </p>","    </div>"," </div>").compile(),oc:new Ext.Template('  <div class="body">','    <div class="message {first_message}">','     <p class="date">',"        {time}","     </p>",'      <p class="content">',"        {message}","      </p>","    </div>"," </div>").compile(),add:function(D,C,E,B,F){var F=this.bO(F||null);this.bQ=gg.D.gp.get(gq.lD);var G=((this.bQ&&F!=this.bU)||C!=this._lastUIN||!this.bQ?this.t:this.oc).append(this.cF,{uin:C,message:E,time:F,fromName:B||"",first_message:this.bQ&&F!=this.bU?"first-message":"",classMsg:D!=gg.D.lK.ChatMessageWindow.oT?"entry text outgoing":"entry text incomming"});this.vz(G);this.bU=F;this._lastUIN=C},vz:function(){var B=$(this.cF).getOffsetParent().getHeight();if(B<1){return }$(this.cF).setStyle({height:B+"px"});this.cF.scrollTop=this.cF.scrollHeight},eW:function(C,D,B,E){var B=B||nz.tR;var E=E||null;this.add(gg.D.lK.ChatMessageWindow.oT,C,D,B,E)},addOutgoing:function(C,D,B,E){this.add(gg.D.lK.ChatMessageWindow.oU,C,D,B,E)},eU:function(B,C){this.add(gg.D.lK.ChatMessageWindow.oS,B,C)},clear:function(){this.bU=null;this.bT=null;this.cF.innerHTML=""},om:function(){return this.cF}});gg.D.lK.fS=function(G,H,E,K,D,J,C,B,I,F){this.cF=G;this.buttons=H;this.dJ=E;this.ax=K;this.cr=D;this.ab=J;this.dC=C;this.eF=function(){};this.aD=I;this.oi=F;this._init()};Object.extend(gg.D.lK.fS,{sS:["color","emoticon",null,"clear","chat_save","remove_format",null,"add_contact","ban_contact","search_uin"],oX:[nz.xP,nz.xQ,null,nz.xS,nz.ua,nz.xW,null,nz.yc,nz.yb,nz.xT],Q:null,mH:false,setActive:function(B){gg.D.lK.fS.Q=B},iz:function(){return gg.D.lK.fS.Q}});Object.extend(gg.D.lK.fS.prototype,{cF:null,dJ:null,ax:null,cr:null,ab:null,dC:null,aD:null,oi:null,dK:true,cf:null,ai:{},du:false,eq:true,eh:100,bd:false,bn:true,J:null,editor:null,_init:function(){var B=this;Ext.form.HtmlEditor.prototype.buttonTips.bold.title=nz.xR;Ext.form.HtmlEditor.prototype.buttonTips.bold.text="";Ext.form.HtmlEditor.prototype.buttonTips.italic.title=nz.xV;Ext.form.HtmlEditor.prototype.buttonTips.italic.text="";Ext.form.HtmlEditor.prototype.buttonTips.underline.title=nz.xU;Ext.form.HtmlEditor.prototype.buttonTips.underline.text="";this.editor=new Ext.form.HtmlEditor({border:false,enableColors:false,enableAlignments:false,enableFont:false,enableFontSize:false,enableLinks:false,enableLists:false,enableSourceEdit:false,applyCommand:function(D){if(D.getKey()==13){if(this.ar()){this.deferFocus();D.preventDefault()}}if(D.ctrlKey){var E=D.getCharCode(),C;if(E>0){E=String.fromCharCode(E);switch(E){case"b":C="bold";break;case"i":C="italic";break;case"u":C="underline";break}if(C){this.win.focus();this.execCmd(C);this.deferFocus();D.preventDefault()}}}},fixKeys:function(){if(Ext.isIE){return function(F){var C=F.getKey(),D;if(C==F.TAB){F.stopEvent();D=this.doc.selection.createRange();if(D){D.collapse(true);D.pasteHTML("&nbsp;&nbsp;&nbsp;&nbsp;");this.deferFocus()}}else{if(C==F.ENTER){if(this.ar()){F.stopEvent()}else{D=this.doc.selection.createRange();if(D){var E=D.parentElement();if(!E||E.tagName.toLowerCase()!="li"){F.stopEvent();D.pasteHTML("<br />");D.collapse(false);D.select()}}}}}}}else{if(Ext.isOpera){return function(D){var C=D.getKey();if(C==D.TAB){D.stopEvent();this.win.focus();this.execCmd("InsertHTML","&nbsp;&nbsp;&nbsp;&nbsp;");this.deferFocus()}else{if(C==D.ENTER){if(this.ar()){D.preventDefault()}}}}}else{if(Ext.isSafari){return function(D){var C=D.getKey();if(C==D.TAB){D.stopEvent();this.execCmd("InsertText","\t");this.deferFocus()}else{if(C==D.ENTER){if(this.ar()){D.stopEvent()}}else{if(C==D.ESC){D.stopEvent()}}}}}}}}(),ar:function(){if(this.dK){this.er("send")}return this.dK}.bind(this)});this.cF.add(this.editor);this.cF.on("resize",function(){this.onResize()},this);this.onResize();this.editor.on("render",function(){this.topToolbar=this.editor.getToolbar();this.topToolbar.addClass(gg.D.lK.gS.vm);for(var E=0,D=gg.D.lK.fS.sS;E<D.length;E++){var C=D[E];this.topToolbar.add(D[E]!==null?{cls:"x-btn-icon "+D[E],enableToggle:false,scope:this,handler:function(G,H){this.er(G.name,H.browserEvent)},clickEvent:"click",tooltip:gg.D.lK.fS.oX[E],name:D[E],tabIndex:-1}:"-")}this.topToolbar.addFill();var F=new Element("iframe");this.topToolbar.addElement(F);F.replace('<iframe frameborder="0" allowtransparency="true" scrolling="no" class="SmallChatWindowBanner" src="http://adserver.gadu-gadu.pl/getsmallbannerwebgg.asp?uid='+gg.D.gp.get(gq.ty)+'"></iframe>')},this);this.editor.on("initialize",function(){this.focus();this.editor.updateToolbar()},this);this.editor.on("sync",function(){this.ca()},this);this.aN();this.aO();this.dK&=gg.D.gp.get(gq.rI);if(this.dK){this.buttons.enter.toggle(true)}this.buttons.send.on("click",function(C,D){this.er(C.name,D.browserEvent)},this);this.buttons.enter.on("click",function(C,D){this.er(C.name,D.browserEvent)},this);this.hU=new gg.fv.gz,ca=function(){this.ca()}.bind(this);this.hU.mG(fo.kK,ca);this.hU.mG(fo.kJ,ca);if(!gg.D.lK.fS.mH){Event.observe(Ext.isIE?document.body:window,Ext.isIE?"mousedown":"click",function(E){var D=Event.element(E);if(D.tagName.toLowerCase()=="button"&&(D.name=="color"||D.name=="emoticon")){return }var C=Event.findElement(E,"TABLE");if(C&&(C.id==gg.D.lK.gS.uU||C.id==gg.D.lK.gS.uT)){return }ca()}.bindAsEventListener(this));gg.D.lK.fS.mH=true}},onResize:function(){var B=this.cF.getSize();if(B.width<10||B.height<10){return }this.editor.setSize(B.width,B.height-2)},aN:function(){if($(gg.D.lK.gS.uU)){return }var F=new Element("table",{id:gg.D.lK.gS.uU}).hide();document.body.appendChild(F);F.appendChild(new Element("thead"));var C=new Element("tbody");F.appendChild(C);var G=new Element("tr");var E=85;for(var D=0;D<=255;D+=E){if(D>1){C.appendChild(G);var G=new Element("tr")}for(g=0;g<=255;g+=E){for(b=0;b<=255;b+=E){var B=((D==0)?"00":D.toString(16))+((g==0)?"00":g.toString(16))+((b==0)?"00":b.toString(16));var H=new Element("td");H.bgColor="#"+B;H.onmousedown=function(){gg.D.lK.fS.iz().er("color_click",this.bgColor)};G.appendChild(H)}}}C.appendChild(G)},aO:function(){if($(gg.D.lK.gS.uT)){return }var F=new Element("table",{id:gg.D.lK.gS.uT}).hide();F.id=gg.D.lK.gS.uT;document.body.appendChild(F);F.appendChild(new Element("thead"));var D=new Element("tbody");F.appendChild(D);var G=new Element("tr");var E=1;var H=gg.D.gp.get(gq.rZ)+gg.D.gp.get(gq.sa);for(var C in gg.D.protocol.gg.hJ){if(C==""){break}var I=new Element("td");var B=new Element("img");B.src=H+C+".gif";if(gg.D.protocol.gg.hJ[C]===null){B.title="<"+C+">";B.name=I.name="&lt;"+C+"&gt;"}else{B.title=gg.D.protocol.gg.hJ[C].replace("&gt;",">").replace("&lt;","<");I.name=B.name=gg.D.protocol.gg.hJ[C]}Event.observe(I,"mouseover",function(J){Element.addClassName(Event.findElement(J,"TD"),"on")});Event.observe(I,"mouseout",function(J){Element.removeClassName(Event.findElement(J,"TD"),"on")});Event.observe(I,"click",function(J){gg.D.lK.fS.iz().er("emoticon_click",this.name)}.bind(B));I.appendChild(B);G.appendChild(I);if(E++==7){D.appendChild(G);G=new Element("tr");E=1}}D.appendChild(G)},ca:function(){$(gg.D.lK.gS.uU).hide();$(gg.D.lK.gS.uT).hide()},dF:null,er:function(E,D){var C=this.editor.getEditorBody();switch(E){case"enter":this.dK=!this.dK;break;case"send":this.dJ();break;case"clear":this.ax();break;case"remove_format":C.body.innerHTML=C.body.innerHTML.stripTags();this.dx();break;case"add_contact":this.cr();break;case"ban_contact":this.ab();break;case"search_uin":this.dC();break;case"chat_save":this.oi();break;case"color":case"emoticon":var B=E=="color"?$(gg.D.lK.gS.uU):$(gg.D.lK.gS.uT);this.ca();$(B).setStyle({display:"block",left:D.pointerX()+"px",top:D.pointerY()+"px"}).show();D.stop();this.fL=false;break;case"color_click":this.editor.execCmd("forecolor",Ext.isSafari||Ext.isIE?"#"+D:D);this.editor.deferFocus();this.ca();return ;case"emoticon_click":if(Ext.isIE){this.editor.setValue(this.editor.getRawValue()+D)}else{this.editor.execCmd("insertHTML",D)}this.focus();this.ca();break}},focus:function(){gg.D.lK.fS.setActive(this);if(Ext.isOpera){rb=this.editor.getEditorBody().createRange();rb.setStart(0,0);rb.collapse(true)}else{this.editor.deferFocus()}},getContent:function(){var B=this.editor.getEditorBody().innerHTML;if(Ext.isIE||Ext.isOpera){B=B.replace(/<P>&nbsp;<\/P>|<P>|<\/P>/ig,"");B=B.replace(/<(.?)STRONG>/ig,"<$1B>");B=B.replace(/<(.?)EM>/ig,"<$1I>")}else{if(Ext.isSafari){B=B.replace(/\sclass="(?:Apple-style-span|khtml-block-placeholder)"/gi,"");B=B.replace(/(&lt;[a-z]+)(>)/gi,"$1&gt;")}else{B=B.replace(/<BR>/ig,"\n").replace(/((\s*\S+)*)\s*/,"$1")}}B=B.replace(/<\/?([a-z]*)[^>]*>/gi,function(C,D){if(/^(b|i|u|font)$/i.test(D)){return C}return""});return B.replace(/^(&nbsp;| )/,"")},clear:function(){this.editor.setRawValue("");this.editor.getEditorBody().innerHTML=Ext.isSafari||Ext.isOpera?"&nbsp;":"";this.focus()},disable:function(){this.bd=true},enable:function(){this.bd=false}});var mR=Ext.isIE;gg.D.lK.po=function(){};Object.extend(gg.D.lK.po,{hQ:"status",hP:"message",ps:1,NT_SOUND:2,pu:3,hU:null,au:{},init:function(){this.hU=new gg.fv.gz;this.hU.mG(fo.kQ,function(C,B){gg.D.lK.po.er(B.type,B)});this.hU.mG(fo.ko,function(C,B){gg.D.lK.po.er(fo.ko,B)});this.qC()},er:function(C,D){var B;for(B in this.au){this.au[B].er(C,D)}},qC:function(){if(gg.D.gp.get(gq.pj)){this.activate(this.ps)}else{this.od(this.ps)}if(gg.D.gp.get(gq.pk)){this.activate(this.NT_SOUND)}else{this.od(this.NT_SOUND)}if(gg.D.gp.get(gq.pn)){this.activate(this.pu)}else{this.od(this.pu)}},activate:function(C){if(typeof this.au[C]!="undefined"&&this.au[C]!==null){return false}var B;switch(C){case gg.D.lK.po.ps:B=new gg.D.lK.po.qi();break;case gg.D.lK.po.NT_SOUND:B=new gg.D.lK.po.sg();break;case gg.D.lK.po.pu:B=new gg.D.lK.po.sN();break}this.au[C]=B;return true},od:function(C){if(typeof this.au[C]=="undefined"){return false}if(typeof this.au[C].destroy=="function"){this.au[C].destroy()}try{delete this.au[C]}catch(B){this.au[C]=null}return true}});gg.D.lK.po.qi=function(){this._init()};Object.extend(gg.D.lK.po.qi,{mB:5000,oy:40});Object.extend(gg.D.lK.po.qi.prototype,{cF:null,au:{},av:0,cy:{},ek:null,_init:function(){this.ek=DIV({"class":gg.D.lK.gS.NM_POPUP_BASE_CLASS,style:"position: absolute; top: -1000px; white-space: nowrap"});document.body.appendChild(this.ek);this.cF=DIV({"class":gg.D.lK.gS.NM_POPUP_BASE_CLASS+" "+gg.D.lK.gS.NM_POPUP_POSITION_BR});document.body.appendChild(this.cF);this.cF.style.display="none";if(mR){Event.observe(window,"scroll",function(){Element.removeClassName(this.cF,gg.D.lK.gS.NM_POPUP_POSITION_BR);Element.addClassName(this.cF,gg.D.lK.gS.NM_POPUP_POSITION_BR)}.bind(this))}gg.D.lK.po.hU.mG(fo.kJ,function(D,E){for(var C in this.au){var B=this.au[C][0];if(B.type=="message"&&E.id==B.rel){B._onclick(null,B)}}}.bind(this))},er:function(I,F){var H=function(L){gg.D.lK.po.hU.fD(fo.lm,{uin:Event.findElement(L,"A").rel});Event.stop(L);return false};var J=A({href:"#",unselectable:"on",onclick:"return false;"});switch(I){case gg.D.lK.po.hP:if(typeof this.cy[F.uin]!="undefined"){return }this.cy[F.uin]=null;J.className=gg.D.lK.gS.NM_POPUP_MESSAGE_CLASS;var K="<button></button>";K+='<span class="'+gg.D.lK.gS.NM_POPUP_NICKNAME_CLASS+'">'+F.hy+"</span> "+nz.eY;var C=gg.D.lK.po.qi.oy,D=F.message;if(F.message.length>C){var B=new RegExp("^.{0,"+C+"}[^ ]+").exec(F.message);if(B===null){D=D.substr(0,C).rp()+"..."}else{D=B[0]+"..."}}J.innerHTML=K+"<br>"+D.escapeHTML();J.type="message";J.rel=F.uin;Event.observe(J.firstChild,"click",H);J._onclick=function(N,M){var L=typeof M!="undefined"?M:Event.findElement(N,"A");if(!L){return false}L.blur();gg.D.lK.po.hU.fD(fo.kT,{id:L.rel});delete this.cy[L.rel];this.dq(L.id);Element.remove(L);return false}.bind(this);Event.observe(J,"click",J._onclick);this.cA(J);break;case gg.D.lK.po.hQ:if(!gg.D.gp.get(gq.pl)){break}J.type="status";J.rel=F.uin;var G,E;switch(F.status){case qn.jN:case qn.jO:G=gg.D.lK.gS.NM_POPUP_STATUS_AVAILABLE_CLASS;E=nz.sM;break;case qn.jQ:case qn.jR:G=gg.D.lK.gS.NM_POPUP_STATUS_BUSY_CLASS;E=nz.sz;break;case qn.jV:case qn.jW:G=gg.D.lK.gS.NM_POPUP_STATUS_UNAVAILABLE_CLASS;E=nz.st;break;case qn.jP:G=gg.D.lK.gS.NM_POPUP_STATUS_BLOCKED_CLASS;break}J.className=G;if(F.status!=qn.jP){var D='<span class="'+gg.D.lK.gS.NM_POPUP_NICKNAME_CLASS+'">'+(F.hy+"</span> "+nz.wO+" "+E);if(F.description!=""){D+='<br><span class="'+gg.D.lK.gS.NM_POPUP_STATUS_DESCRIPTION_CLASS+'">'+F.description+"</span>"}}else{var D='<span class="'+gg.D.lK.gS.NM_POPUP_NICKNAME_CLASS+'">'+(F.hy+"</span> "+nz.eO)}J.innerHTML=D;Event.observe(J,"click",function(){var M=this.cF.getElementsByTagName("a");for(var L=0;L<M.length;L++){if(typeof M[L]["rel"]=="undefined"||M[L]["type"]!="status"){continue}else{window.clearTimeout(M[L]["ei"]);this.dq(M[L].id);Element.remove(M[L]);L--}}}.bind(this));this.cA(J);J.ei=setTimeout(function(){if(J.parentNode){this.dq(J.id);Element.remove(J)}}.bind(this),gg.D.lK.po.qi.mB);break}},cA:function(C){var B="_NM_POPUP_"+new Date().getTime().toString().substr(5)+Math.floor(Math.random()*100).toString();C.id=B;$(C).setStyle({clear:"right",display:"block"});this.ek.appendChild(C);this.au[B]=[C,this.ek.offsetWidth];(C.firstChild.tagName=="BUTTON")&&($(C.firstChild).setStyle({"float":"right"}));if(this.cF.childNodes.length==0){this.cF.appendChild(C)}else{this.cF.insertBefore(C,this.cF.firstChild)}this.ek.innerHTML="";this.av++;this.du()},dq:function(B){delete this.au[B];this.av--;this.du()},du:function(){if(this.av==0){this.cF.style.display="none";return }var C=0;for(var B in this.au){if(C<this.au[B][1]){C=this.au[B][1]}}this.cF.style.display="block";this.cF.style.width=C+"px"},destroy:function(){Element.remove(this.cF)}});gg.D.lK.po.sN=function(){this._init()};Object.extend(gg.D.lK.po.sN,{sB:1500,nS:40,ow:gg.D.lK.gS.NM_TITLE_MESSAGE_ICON,hm:gg.D.lK.gS.NM_TITLE_DEFAULT_ICON});Object.extend(gg.D.lK.po.sN.prototype,{bx:true,cK:null,ce:0,ei:null,cd:null,_init:function(){Event.observe(window,"focus",function(){this.bx=true;this.dY()}.bind(this));Event.observe(window,"blur",function(){this.bx=false}.bind(this))},er:function(B,C){if(this.bx||B!=gg.D.lK.po.hP){return }if(this.ei===null){this.cK=document.title}this.ce=-1;window.clearInterval(this.ei);this.aP();(gg.D.gp.get(gq.ik))&&(window.focus());this.ei=window.setInterval(function(){this.ec(C)}.bind(this),gg.D.lK.po.sN.sB);this.ec(C)},ec:function(D){if(++this.ce>1){this.ce=0}var C;switch(this.ce){case 0:C=D.hy+" "+nz.eY;break;case 1:var B=D.message.escapeHTML();if(B.length>gg.D.lK.po.sN.nS){C=B.substr(0,gg.D.lK.po.sN.nS).rp()+"..."}else{C=B}break}document.title=C},dY:function(){window.clearInterval(this.ei);this.ei=null;if(this.cK!==null){document.title=this.cK}this.ba()},aP:function(B){B=typeof B!="undefined"?B:gg.D.lK.po.sN.ow;this.cd=document.createElement("link");this.cd.type="image/x-icon";this.cd.rel="shortcut icon";this.cd.href=B;document.getElementsByTagName("head")[0].appendChild(this.cd)},ba:function(){if(this.cd===null){return }Element.remove(this.cd);this.cd=null;this.aP(gg.D.lK.po.sN.hm)},destroy:function(){this.dY()}});gg.D.lK.po.sg=function(){this._init()};Object.extend(gg.D.lK.po.sg,{sc:gg.D.gp.get(gq.rQ),sd:gg.D.gp.get(gq.rR)});Object.extend(gg.D.lK.po.sg.prototype,{cD:null,statusSound:"statusSound",oA:"oA",_init:function(){soundManager.onload=function(){soundManager.createSound({id:this.statusSound,url:gg.D.gp.get(gq.rP)+gg.D.lK.po.sg.sd,volume:100});soundManager.createSound({id:this.oA,url:gg.D.gp.get(gq.rP)+gg.D.lK.po.sg.sc,volume:100})}.bind(this)},er:function(B,C){if(B==fo.ko){if(gg.D.gp.get(gq.yn)&&gg.D.gp.get(gq.ym)){this.df(this.oA)}}else{if(B==gg.D.lK.po.hQ){if(gg.D.gp.get(gq.yo)){switch(C.status){case qn.jN:case qn.jO:break;default:return }this.df(this.statusSound)}}else{if(B==gg.D.lK.po.hP){if(gg.D.gp.get(gq.yn)&&!gg.D.gp.get(gq.ym)){this.df(this.oA)}}}}},df:function(B){soundManager.stop(B);soundManager.play(B)},dY:function(){soundManager.stopAll()}});if(typeof gg.D.lK.tI=="undefined"){gg.D.lK.tI=function(){}}var mR=Ext.isIE;gg.D.lK.tI=function(){};Object.extend(gg.D.lK.tI,{gW:null,gZ:null,gX:null,sk:null,gV:"",status:null,ev:null,cW:null,tA:["AVAIL","BUSY","INVISIBLE","NOT_AVAIL"],fy:[nz.ot,nz.oq,nz.or,nz.of],gP:[gS.wC,gS.wB,gS.vd,gS.wF],initialize:function(C){var E=cb=eC=cX=null,D=this;this.ev=new gg.fv.gz();this.gX=this.tA[3];this.container=$(C.appendChild(DIV({"class":gS.cQ})));this.radioToggle=new Element("div",{id:"radioToggle",className:"radioToggle"});this.container.appendChild(this.radioToggle);Event.observe(this.radioToggle,"mouseover",function(G){this.radioToggle.addClassName("radioToggleHover")}.bind(this));Event.observe(this.radioToggle,"mouseout",function(G){this.radioToggle.removeClassName("radioToggleHover")}.bind(this));var B=new Element("div",{style:"height: 5px; border: none; overflow: hidden;"});this.gY=$(this.container.appendChild(DIV({"class":gS.vr},B,this.gZ=SPAN({"class":gS.vG,unselectable:"on",style:"margin: 4px 0 0 4px; padding-left: 20px;"},nz.of))));this.sk=$(document.body.appendChild(DIV({"class":gg.D.lK.gS.vy}))).hide();for(var F=0;F<this.tA.length;F++){var E=DIV({"class":gS.uV,style:"padding-left: 20px",unselectable:"on",sl:F},SPAN({unselectable:"on"},this.fy[F]));E.sl=F;this.sk.appendChild(E);this.am(E,F);E.onclick=function(G){D.bY(this.sl)}}Event.observe(this.gY,"mouseover",function(G){this.gY.addClassName(gg.D.lK.gS.CM_USER_STATUS_ITEM_SELECTED)}.bind(this));Event.observe(this.gY,"mouseout",function(G){this.gY.removeClassName(gg.D.lK.gS.CM_USER_STATUS_ITEM_SELECTED)}.bind(this));Event.observe(this.sk,"keyup",function(G){switch(G.keyCode){case Event.KEY_RETURN:this.bY(this.gX);break;case Event.KEY_ESC:Element.hide(this)}}.bind(this));Event.observe(this.sk,"keyup",function(G){if((G.keyCode==88&&G.ctrlKey)||(G.keyCode==46||Event.element(G)!=this.sj)){this.sj.value=""}Event.stop(G)}.bind(this));this.dp();Event.observe(this.gY,"click",function(H){var I,G;H.stop();I=this.container.viewportOffset();G=this.sk.getHeight();this.sk.setStyle({top:I[1]-(G<120&&Ext.isGecko&&/Windows/.test(navigator.userAgent)?121:G)+"px",left:I[0]+"px",zIndex:"90000",width:this.container.getWidth()-4+"px"}).toggle()}.bind(this));this.ey("",this.tA[this.tA.length-1])},dp:function(){for(var B=0;B<this.sk.childNodes.length;B++){if(this.sk.childNodes[B].getAttribute("highlight")=="off"){continue}this.sk.childNodes[B].onmouseover=function(C){Element.addClassName(this,gg.D.lK.gS.CM_USER_STATUS_ITEM_SELECTED)};this.sk.childNodes[B].onmouseout=function(C){Element.removeClassName(this,gg.D.lK.gS.CM_USER_STATUS_ITEM_SELECTED)}}},bY:function(B){this.mt(B)},ey:function(C,B){this.gX=B;this.gV=C;if(typeof this.sj!="undefined"){this.sj.value=this.gV}this.am(this.gZ,this.gX);$(this.gZ).update(C&&C!=""?fs(C):this.fy[this.gX]);this.sk.hide()},am:function(C,B){for(var D=0;D<this.tA.length;D++){Element.removeClassName(C,this.gP[D])}Element.addClassName(C,this.gP[B])},sn:function(B){switch(B){case qn.jV:case qn.jW:return"NOT_AVAIL";case qn.jN:case qn.jO:return"AVAIL";case qn.jQ:case qn.jR:return"BUSY";case qn.jT:case qn.jU:return"INVISIBLE";case qn.jP:return"NOT_AVAIL";default:return"AVAIL"}}});gg.D.lK.tH=function(B){this.initialize(B);this.qh()};Object.extend(gg.D.lK.tH.prototype,gg.D.lK.tI);Object.extend(gg.D.lK.tH.prototype,{pz:null,pB:null,qh:function(){this.ev.mG(fo.kx,function(C,D){this.mc(C,D)}.bind(this));this.ev.mG(fo.kw,function(C,D){this.lU(C,D)}.bind(this));this.ev.mG(fo.ks,function(C,D){this.lU(C,D)}.bind(this));this.ev.mG(fo.ls,function(C,D){this.lS(C,D)}.bind(this));this.sk.appendChild(DIV({style:"overflow:auto;",highlight:"off"},DIV({"class":gS.uV},this.mF=$(SPAN({unselectable:"on"},nz.uu)),this.sj=$(INPUT({"class":gS.vw,type:"text",value:"",style:"margin-left: 4px;",name:"sj",maxLength:gg.D.gp.get(gq.hs)})))));this.pz=!gg.D.gp.get(gq.tC);cX=this.sk.appendChild(DIV({"class":gS.uV},this.pA=INPUT({type:"checkbox"}),SPAN({unselectable:"on"},nz.uy)));this.pA.checked=this.pz;Event.observe(cX,"click",function(C){this.cR()}.bind(this));this.pB=!gg.D.gp.get(gq.tv);cX=this.sk.appendChild(DIV({"class":gS.uV},this.onlyFromFriendNode=INPUT({type:"checkbox"}),SPAN({unselectable:"on"},nz.uz)));this.onlyFromFriendNode.checked=this.pB;Event.observe(cX,"click",function(C){this.cS()}.bind(this));Event.observe(Ext.isIE?document.body:window,Ext.isIE?"mousedown":"click",function(C){if(!this.sk.visible()){return }if(!Element.parentOf(Event.element(C),this.sk)&&Event.findElement(C,"DIV")!=this.gY){this.bY(this.gX)}}.bind(this));this.dp();Event.observe(this.gY,"click",function(){this.sj.setStyle({width:this.sk.getDimensions().width-this.mF.getDimensions().width-(Ext.isIE?65:15)+"px"});try{this.sj.focus()}catch(C){}}.bind(this));new Ext.ToolTip({target:this.radioToggle,html:nz.yA});var B=gg.D.lK.yy.create();this.radioToggle.observe("click",function(){B.zx().zD()})},hide:function(){},cR:function(){this.pz=!this.pz;this.pA.checked=this.pz;gg.D.gp.set(gq.tC,!this.pz);this.mt(this.gX,true);$(this.sk).hide()},cS:function(){this.pB=!this.pB;this.onlyFromFriendNode.checked=this.pB;gg.D.gp.set(gq.tv,!this.pB);$(this.sk).hide()},lU:function(B,C){this.ey("",this.tA.indexOf("NOT_AVAIL"))},mt:function(C,F){var H=$F(this.sj);var G=H!=""?true:false;if(this.gX==C&&this.gV==H&&!F){this.sk.hide();return }this.ey(H,C);var I={status:gg.D.gQ.sn(this.tA[this.gX],G),description:this.gV};var E=this.sn(I.status);if(E!="NOT_AVAIL"&&gg.D.fv.ij.nt("comm.connected")){var B=[gq.tP,gq.xG,gq.ts,gq.tq,gq.tC,gq.tv,gq.tw,gq.tx,gq.lD,gq.pm,gq.pl,gq.eP,gq.yo,gq.yn,gq.ym];var D=gg.D.gp.iH(B);D[gq.ts]=I.status;D[gq.tq]=I.description;gg.fv.sq.set("userData",D);gg.D.gp.bind(D)}if(!gg.D.fv.ij.nt("comm.connected")&&E!="NOT_AVAIL"){var J=gg.D.gp.get(gq.ts);gg.D.protocol.gg.gi.gr(gg.D.gp.get(gq.ty),gg.D.gp.get(gq.tz),I.status,I.description)}else{if(E!="NOT_AVAIL"){this.ev.fD(fo.ly,I)}else{this.ev.fD(fo.lo)}}},lS:function(B,C){this.sj.value=C.description;this.mt(this.gX)},mc:function(C,D){if(typeof D.description=="undefined"){D.description=""}var B=D.status;this.ey(D.description,this.tA.indexOf(this.sn(B)))}});if(typeof gg.D.lK.Wait=="undefined"){gg.D.lK.Wait=function(){}}gg.D.lK.Wait=function(B){this.initialize(B)};Object.extend(gg.D.lK.Wait.prototype,{container:null,tS:null,sK:null,initialize:function(B){this.container=B;this.overflow=this.container.style.overflow;this.tS=$(this.container.appendChild(DIV({"class":gS.WAIT},DIV({style:"height: 60%;"}),this.sK=$(DIV({"class":gS.WAIT_TEXT,unselectable:"on"})))));Event.observe(this.tS,"click",function(C){Event.stop(C)});this.hide()},show:function(){if(this.tS.visible()){return }this.container.style.overflow="hidden";this.tS.show();this._updateDimentions()},update:function(B){return $(this.sK).update(B.toString())},hide:function(){if(!this.tS.visible()){return }this.update("");this.tS.hide();this.container.style.overflow=this.overflow},visible:function(){return this.tS.visible()},_updateDimentions:function(){Position.clone(this.container.parentNode,this.tS)}});gg.lK.hw={};Object.extend(gg.lK.hw,{mO:"ok",ID_CANCEL:"cancel",mP:"yes",mN:"no",alert:function(C,B,D){this.afterShow(Ext.Msg.show({title:C,msg:B,buttons:Ext.Msg.OK,fn:D,icon:Ext.MessageBox.WARNING,width:10}),C)},nh:function(C,B,D){this.afterShow(Ext.Msg.show({title:C,msg:B,buttons:Ext.Msg.OK,fn:D,icon:Ext.MessageBox.INFO}),C)},error:function(C,B,D){this.afterShow(Ext.Msg.show({title:C,msg:B,buttons:Ext.Msg.OK,fn:D,icon:Ext.MessageBox.ERROR}),C)},confirm:function(C,B,D){this.afterShow(Ext.Msg.show({title:C,msg:B,buttons:{yes:nz.wT,no:nz.wR},fn:D,icon:Ext.MessageBox.QUESTION}),C)},afterShow:function(C,B){}});function yX(){if(yH()){gg.lK.hw.nh(null,nz.up,function(){zt()});return }var I=gg.D.lK.zi.create();Ext.QuickTips.init();var E=gg.fv.sq.get("userData",true);if(E!==null){gg.D.gp.bind(E)}var H=gg.D.lK.sD.nJ;H.panelLayout=new Ext.Panel();var D=350;var C=245;var G=new Ext.Window({title:false,layout:"fit",maximizable:false,animCollapse:false,hideMode:"visibility",collapsible:false,constrain:true,border:false,draggable:false,resizable:false,closable:false,items:[H.panelLayout],height:C,width:D,x:250,y:160});var S=gg.D.gp.get(gq.xG);var N=new Ext.TabPanel({renderTo:"webgg-login-tabs_"+S,width:D,height:215,floating:true,shadow:false,activeTab:0,plain:true,frame:false,defaults:{autoScroll:true,cls:"webgg-login-tabs"},items:[{contentEl:"about_"+S,title:nz.xp},{contentEl:"possibilities_"+S,title:nz.xq},{contentEl:"requirements_"+S,title:nz.xr},{contentEl:"safety_"+S,title:nz.xB}]});H.qh();G.show();var R=function(V,W,U,T){yk=new Element("iframe");document.body.appendChild(yk);yk.replace('<iframe frameborder="0" allowtransparency="true" scrolling="no" id="'+W+'" src="'+V+'" style="height: '+T+"px; width: "+U+'px"></iframe>');return yk=$(W)};var M=R("http://adserver.gadu-gadu.pl/getloginbanner.asp?webgg=1",gS.yF,350,150);var P=document.body.appendChild(DIV({"class":"webgg-header-buttons"}));P.innerHTML='<div class="contactButton"><a target="_blank" href="'+nz.oH+'">'+nz.xA+'</a></div> <div class="faq"><a target="_blank" href="'+nz.xE+'">'+nz.nQ+"</a></div>";var K=function(){var T=R("http://adserver.gadu-gadu.pl/getafterloginbanner.asp?webgg=1",gS.yE,90,28)};var J=$("webgg-footer_"+S);if(gg.D.gp.get(gq.cT)){G.maximize()}var Q=function(){center=document.body.offsetWidth/2;var T=Math.floor(center-D-135);G.setPosition(T,110);N.setPosition(T,120+C);M.setStyle({position:"absolute",left:T+D+40+"px",top:190+C+"px"});J.setStyle({left:T+"px"}).removeClassName("x-hide-display")};Q();Event.observe(window,"resize",function(){Q()});$(document.body).setStyle({backgroundImage:"url(/img/bg_login_"+S+".jpg)"});var L=null;var F=function(){var U=new Element("div");document.body.appendChild(U);var T=document.body.offsetWidth/2;U.setStyle({position:"absolute",left:(T-150)+"px",top:190+C+"px"});L=new Ext.ProgressBar({id:"mA",width:300,text:nz.tY+"...",renderTo:U});L.on("update",function(V){});L.show();L.wait({interval:200,increment:15,fn:function(){}})};var B=function(){L.reset(true)};var O=new gg.fv.gz();O.mG(fo.kx,function(T,U){B();O.tg(fo.kx)});O.mG(fo.kw,function(T,U){B()});O.mG(fo.kn,function(T,U){B()});O.mG(fo.ks,function(T,U){B()});O.mG(fo.kt,function(T,U){B()});O.mG(fo.lw,function(T){F();G.hide();N.hide();J.hide();M.hide();K();$(document.body).setStyle({backgroundImage:"url(/img/bg.jpg)"})})}function yH(){return !(Ext.isSafari||Ext.isIE||Ext.isOpera||Ext.isGecko)}function zt(){window.location="http://www.gadu-gadu.pl"}window.onbeforeunload=function(){if(gg.D.fv.ij.nt("comm.connected")){return nz.xD}return };if(top!=self){top.location.href=self.location.href}if(/iPhone|iPod/.test(navigator.userAgent)){window.location="iphone.html"}var yr=function(){};Ext.onReady(function(){if(Ext.MessageBox){Ext.MessageBox.buttonText={ok:"OK",cancel:"Anuluj",yes:"Tak",no:"Nie"}}Ext.QuickTips.init();var D=gg.fv.sq.get("userData",true);if(D!==null){gg.D.gp.bind(D)}if(/default_lang%3Den%26/.test(document.cookie)||(!/default_lang/.test(document.cookie)&&/en-US;/.test(navigator.userAgent))){gg.D.gp.set(gq.xG,"en")}var C=gg.D.gp.get(gq.ts);if(C==qn.jV||C==qn.jW||C==qn.jP){gg.D.gp.set(gq.ts,qn.jN)}else{gg.D.gp.set(gq.ts,parseInt(gg.D.gp.get(gq.ts)))}gg.D.gp.set("path.root","./");gg.fv.sq.set(gq.rX,"","");var B=gg.D.protocol.gg.gi;var E=new gg.fv.gz();var F=null;B.hU.mG(fo.kI,function(H,G){B.mw(H,G)});if(!F){F=gg.D.lK.cY.create()}B.hU.mG(fo.kx,function(H,G){B.mb(H,G)});B.hU.mG(fo.kw,function(H,G){gg.D.gi.eH();gg.lK.hw.error(null,nz.dT,function(){yM()})});B.hU.mG(fo.ky,function(H,G){});B.hU.mG(fo.kn,function(H,G){gg.lK.hw.confirm(null,nz.wH,function(I){if(I==gg.lK.hw.mP){gg.D.protocol.gg.gi.gr(gg.D.gp.get(gq.ty),gg.D.gp.get(gq.tz),gg.D.gp.get(gq.ts),gg.D.gp.get(gq.tq))}})});B.hU.mG(fo.ks,function(H,G){gg.D.gi.eH();gg.lK.hw.confirm(null,nz.oM,function(I){if(I==gg.lK.hw.mP){gg.D.protocol.gg.gi.gr(gg.D.gp.get(gq.ty),gg.D.gp.get(gq.tz),gg.D.gp.get(gq.ts),gg.D.gp.get(gq.tq))}})});B.hU.mG(fo.kt,function(H,G){gg.D.gi.eH();gg.lK.hw.confirm(null,nz.oM,function(I){if(I==gg.lK.hw.mP){gg.D.protocol.gg.gi.gr(gg.D.gp.get(gq.ty),gg.D.gp.get(gq.tz),gg.D.gp.get(gq.ts),gg.D.gp.get(gq.tq))}})});B.hU.mG(fo.lw,function(H,G){if(G[gq.ty===""]||G[gq.tz===""]){B.hU.fD(fo.kw,{});return }B.gr(G[gq.ty],G[gq.tz],gg.D.gp.get(gq.ts),gg.D.gp.get(gq.tq))});document.title=gg.D.gp.get(gq.fd)+" "+gg.D.gp.get(gq.fe);B.hU.mG(fo.lz,function(H,G){B.mx(H,G)});if(!gg.D.gp.get(gq.cT)){gg.D.lK.po.init()}B.hU.mG(fo.kq,function(H,G){gg.D.fv.ij.set("countactList.imported")});B.hU.mG(fo.kp,function(H,G){B.lQ(H,G)});B.hU.fD(fo.kX,{});B.hU.mG(fo.lf,function(H,G){B.qL(G)});B.hU.mG(fo.lg,function(H,G){B.qR(G)});Event.observe(window,"scroll",function(){Element.removeClassName($("windowManager"),gg.D.lK.gS.NM_POPUP_POSITION_BR);Element.addClassName($("windowManager"),gg.D.lK.gS.NM_POPUP_POSITION_BR)});E.mG(fo.lm,function(H,G){E.fD(fo.kZ);E.fD(fo.ll,G)});B.hU.mG(fo.lo,function(H,G){B.hU.tg(fo.ky);B.hU.tg(fo.ks);B.hU.tg(fo.kt);gg.D.protocol.gg.gi.hU.fD(fo.ly,{status:qn.jV,description:gg.D.gp.get(gq.tq)||""});window.onbeforeunload=null;yM()});if(yH()){gg.lK.hw.nh(null,nz.up,function(){gg.D.protocol.gg.gi.hU.fD(fo.lo)})}yX()});Ext.BLANK_IMAGE_URL="/images/default/s.gif";gadu_login=function(){};function yM(){window.location.reload()}function yT(D){if(!gg.D.gp.get(gq.ta)){return }var C=new Ext.ux.YoutubePlayer({developerKey:"AI39si5hrUAfeH6xblrClKwb8tapkqcQ25WY7MKgiS1fCGmKEem-pYg-DTlIovimS9lINBVjIafghHguMdrsfVPNxkXzncyseQ",playerId:"p"+Math.floor(Math.random()*10000),border:false,ratioMode:"strict",hideMode:"visibility",bgColor:"#000000",bodyStyle:"background-color:#000000;"});C.on("ready",function(E,F){E.cueVideoById(D,0)},C);var B=new Ext.Window({title:"YouTube",layout:"fit",id:"p"+Math.floor(Math.random()*10000),maximizable:true,animCollapse:false,hideMode:"visibility",collapsible:true,resizable:true,items:[C],bbar:new Ext.ux.YoutubePlayer.Control({player:C,border:false,id:"p"+Math.floor(Math.random()*10000),style:"border:none;"}),listeners:{resize:function(){this.bottomToolbar.fireEvent("resize")}},height:400,width:500});B.show()};
