RoomEnterAd={adLoaded:false,remainingDisplaySeconds:0,closeLabel:"",init:function(){RoomEnterAd.loadingTimer=window.setTimeout(RoomEnterAd.loadingTimeout,10*1000)},checkAd:function(a,b){if(!RoomEnterAd.isRealAd(a)){return}RoomEnterAd.displayTimer=window.setTimeout(RoomEnterAd.displayTimeout,b*1000);RoomEnterAd.labelTimer=window.setTimeout(RoomEnterAd.labelTimeout,1000);
RoomEnterAd.remainingDisplaySeconds=b;RoomEnterAd.centerTheBanner();$("roomenterad-habblet-container").style.visibility="visible";RoomEnterAd.closeLabel=$("roomenterad-closing").innerHTML;RoomEnterAd.adLoaded=true;FlashExternalInterface.track("habblet","roomenterad","shown")},isRealAd:function(a){var b=false;
jQuery(a).contents().find(".ad-container").find("*").each(function(f,g){var d=g.tagName.toLowerCase();if(d!="script"&&d!="noscript"&&d!="a"&&d!="br"){if(d=="img"){var h=g.getAttribute("width");var c=g.getAttribute("height");var e=(h=="1"&&c=="1")||g.src.indexOf("1x1.gif")>=0||g.src.indexOf("transparent.gif")>=0;
if(!e){b=true;return false}}else{b=true;return false}}});return b},centerTheBanner:function(){contentWidth=$("flash-wrapper").offsetWidth;margins=contentWidth-740-65;margin=Math.round(margins/2);$("roomenterad").style.top="-55px";$("roomenterad").style.right=margin+"px"},closeTheBanner:function(){HabbletLoader.removeHabblet("roomenterad");
FlashExternalInterface.track("habblet","roomenterad","closed")},loadingTimeout:function(){if(RoomEnterAd.adLoaded){return}HabbletLoader.removeHabblet("roomenterad")},displayTimeout:function(){HabbletLoader.removeHabblet("roomenterad")},labelTimeout:function(){closingElement=$("roomenterad-closing");if(!closingElement){return
}RoomEnterAd.remainingDisplaySeconds--;closingElement.innerHTML=RoomEnterAd.closeLabel+" "+RoomEnterAd.remainingDisplaySeconds;closingElement.style.visibility="visible";if(RoomEnterAd.remainingDisplaySeconds>1){RoomEnterAd.labelTimer=window.setTimeout(RoomEnterAd.labelTimeout,1000)}RoomEnterAd.centerTheBanner()
}};__roomenterad__defined__=true;