var QuickRegister={link:"/quickregister/start",windowName:"registration",windowParams:"toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=yes,resizable=yes,",narrowSizeParams:"width=740,height=620",wideSizeParams:"width=980,height=620",nowOpening:false,open:function(b){if(QuickRegister.nowOpening){return
}QuickRegister.nowOpening=true;if(typeof b=="undefined"){b=QuickRegister.link}if(screen.width<990){b+=((b.indexOf("?")!=-1)?"&":"?")+"wide=false"}var a=QuickRegister._openHabboWindow(b,QuickRegister.windowName);QuickRegister.nowOpening=false},_openHabboWindow:function(a,b){return window.open(a,b,QuickRegister.windowParams+(screen.width>=990?QuickRegister.wideSizeParams:QuickRegister.narrowSizeParams))
},initAgeGate:function(d){Event.observe($("back-link"),"click",function(){Overlay.show(null,L10N.get("identity.register.overlay.loading.text"))});Event.observe("proceed","click",function(e){Overlay.show(null,L10N.get("identity.register.overlay.loading.text"));$("quickregisterform").submit()});var b=$$(".select_gender.boy img");
if(b.length>0){b[0].observe("click",QuickRegister.selectMaleAvatar);$("radio-button-boy").observe("click",QuickRegister.selectMaleAvatar)}var c=$$(".select_gender.girl img");if(c.length>0){c[0].observe("click",QuickRegister.selectFemaleAvatar);$("radio-button-girl").observe("click",QuickRegister.selectFemaleAvatar)
}var a=$$("#date-selector select");if(a.length>0){a[0].focus()}if($("radio-button-boy").checked){QuickRegister.selectMaleAvatar()}else{if($("radio-button-girl").checked){QuickRegister.selectFemaleAvatar()}}if(d){new Ajax.Request("/quickregister/start_loaded")}},selectMaleAvatar:function(){$("radio-button-boy").checked=true;
$$(".select_gender.boy")[0].addClassName("selected");$$(".select_gender.girl")[0].removeClassName("selected")},selectFemaleAvatar:function(){$("radio-button-girl").checked=true;$$(".select_gender.girl")[0].addClassName("selected");$$(".select_gender.boy")[0].removeClassName("selected")}};