
   if(!dbugScripts("doors",["doors.tron.frontdoor.js"])) {
   /*	doors.tron.frontdoor.js - packed	*/
       var LSSC;var LiveStreamStatusCheck=new Class({Implements:[Options,Events],options:{intervalLength:30000,countdown$:"countDownDisplay",apiUrl:"http://api.cnet.com/restApi/v1.0/",showImages:{13952:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_404.jpg",showName:"The 404"},19709:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_BOL.jpg",showName:"Buzz Out Loud"},12519:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_mp3insider.jpg",showName:"MP3 Insider"},17918:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_dialedin.jpg",showName:"Dialed In"},17920:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_realdeal.jpg",showName:"The Real Deal"},30976:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_roundtable.jpg",showName:"Reporters's Rountdable"},17919:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_cartech.jpg",showName:"Car Tech Live"},12552:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_gadgettes.jpg",showName:"Gadgettes"},18603:{imageUrl:"http://i.i.com.com/cnwk.1d/i/tron/cnettv/cnetLive/FD_promo_ONAIR_digitalcity.jpg",showName:"Digital City"}}},bound:{},initialize:function(A){this.setOptions(A);this.setPromoElems();this.setFranchiseIds();this.addRequestHandler();this.initDisplay();},setPromoElems:function(){var A=this.elems={};A.pcPromo=$("pcPromo");A.countdownElem=$(this.options.countdown$)||new Element("div",{id:this.options.countdown$}).inject($("pcPromo"),"before");},setFranchiseIds:function(){this.franchiseIds=(this.elems.pcPromo.getProperty("franchiseids")||"").split(",");},initDisplay:function(){var C=this.options,A=(C.broadcastStartTime)?this.findTimeDifference(C.broadcastStartTime)/60:null,B=(C.broadcastEndTime)?this.findTimeDifference(C.broadcastEndTime)/60:null;if(!A||!B){this.findNextLiveStream();return ;}if(["cnetFrontDoor","index"].contains(C.page)){if(C.broadcastStatus=="UPCOMING"){if(A&&A<=60){if(A&&A>0){this.displayPromo();this.startCountdownTimer();return ;}else{if(A<=0){C.broadcastStatus="IN_PROGRESS";}}}else{this.getArchiveVideo();return ;}}if(C.broadcastStatus=="IN_PROGRESS"){this.displayPromo();this.timer=this.findEndOfLiveStream.delay(this.getEndTimeCheck(),this);return ;}else{this.getArchiveVideo();}}else{if(C.page=="show"){if(C.broadcastStatus=="UPCOMING"){if(A&&A<=60){if(A&&A>0){this.startCountdownTimer();}}}else{if(C.broadcastStatus=="IN_PROGRESS"){if(A>-120&&A<0||B<0){this.showRestartLink();}else{this.loadOnDemandPlayer();}}}}}},startCountdownTimer:function(){var B;this.timer=$clear(this.timer);this.timeRemain=this.findTimeDifference(this.options.broadcastStartTime);if(["cnetFrontDoor","index"].contains(this.options.page)){var A="/9776-"+this.options.nodeId+"_53-"+this.options.query+".html";this.elems.showStatus.set("html",'<a href="'+A+'" class="upNext">Coming up next in <span class="timeDisplay"></span></a>');if(this.elems.cat){this.elems.cat.getElement("DIV.showStatus").set("html",'Coming up next in <span class="timeDisplay"></span>');}}else{this.elems.countdown.set("html",'Live stream starts in <span class="timeDisplay"></span>');}B=$$("span.timeDisplay");if(this.options.page=="cnetFrontDoor"){B.setStyle("display","block");}this.timer=this.displayCountdown.periodical(1000,this,[B]);},displayCountdown:function(A){A.set("text",this.getDisplayTime());if(this.timeRemain){this.timeRemain--;}else{this.startInProgressTimer();}},getDisplayTime:function(){var C=this.timeRemain,A=Math.floor(C/(3600)),B,D;C-=(A*3600);B=Math.floor(C/60);C-=(B*60);D=C%60;C=(A)?A+":":"";if(B<1){C+=(A)?"00":"";}else{if(B<10&&A){C+="0"+B;}else{C+=B;}}if(C){C+=":";}if(C&&D<10){D="0"+D.toString();}C+=D;return C;},showLiveStream:function(){$clear(this.timer);(window.universalVideo||document.universalVideo).showClipsFromPage("live","live","live");},setDataAsOptions:function(A){dbug.log("setDataAsOptions: %o",A);this.setOptions({nodeId:A.Category["@id"],query:A["@id"],broadcastStatus:A.BroadcastStatus.$,broadcastStartTime:A.BroadcastStartTime.$,broadcastEndTime:A.BroadcastEndTime.$,showName:A.FranchiseName.$,promoImg:this.getPromoImage(A)});},findNextLiveStream:function(){if(!this.bound.checkNextLiveStream){this.bound.checkNextLiveStream=this.checkNextLiveStream.bind(this);}this.getLiveStatus(this.bound.checkNextLiveStream);},checkNextLiveStream:function(A){dbug.log("checkNextLiveStream: %o",A);if(A[0]){this.setDataAsOptions(A[0]);this.initDisplay();}else{this.getArchiveVideo();}},startInProgressTimer:function(){this.showWaitaMinute();this.findStartedLiveStream();},findStartedLiveStream:function(){if(!this.bound.checkForStart){this.bound.checkForStart=this.checkForStart.bind(this);}this.getLiveStatus(this.bound.checkForStart);},checkForStart:function(A){var B=A.filter(function(C){return(C["@id"]==this.options.query);}.bind(this));if(B[0].BroadcastStatus.$=="IN_PROGRESS"){this.options.broadcastStatus="IN_PROGRESS";this.showWatchNowLink();}else{this.timer=this.findStartedLiveStream.delay(30000,this);}},showWatchNowLink:function(){this.timer=$clear(this.timer);if(this.options.page=="show"){this.elems.countdownElem.set("html","<a href=\"javascript:previousLiveClick('live', 'live', 'live');updateEpisodeTitle('"+this.options.liveEpisodeTitle+"');\">Start/restart live stream</a>");}else{this.displayPromo();}this.timer=this.findEndOfLiveStream.delay(this.getEndTimeCheck(),this);},getEndTimeCheck:function(){var A=this.findTimeDifference(this.options.broadcastStartTime),B=this.findTimeDifference(this.options.broadcastEndTime,((A<0)?null:this.options.broadcastStartTime));return(((B<120)?0:B-120)*1000).limit(30000,300000);},findEndOfLiveStream:function(){if(!this.bound.checkForEnd){this.bound.checkForEnd=this.checkForEnd.bind(this);}this.getLiveStatus(this.bound.checkForEnd);},checkForEnd:function(A){var B=A.filter(function(C){return(C["@id"]==this.options.query);}.bind(this));if(!B.length){this.liveStreamIsOver(A);}else{this.findEndOfLiveStream.delay(30000,this);}},showRestartLink:function(){clearInterval(this.timer);this.elems.countdownElem.set("html","<a href=\"javascript:previousLiveClick('live', 'live', 'live');updateEpisodeTitle('"+this.options.liveEpisodeTitle+"');\">Restart live stream</a>");},showWaitaMinute:function(){this.timer=$clear(this.timer);if(["cnetFrontDoor","index"].contains(this.options.page)){var A="/9776-"+this.options.nodeId+"_53-"+this.options.query+".html";this.elems.showStatus.set("html",'<a href="'+A+'" class="upNext">Starts shortly</a>');if(this.elems.cat){this.elems.cat.getElement("div.showStatus").set("text","Starts shortly");}}else{this.elems.countdown.set("html","Live stream will start shortly...");}},displayPromo:function(C){C=C||this.options;var B="/9776-"+C.nodeId+"_53-"+C.query+".html",A=this.elems,D='<div id="pcpWrap">';if(C.nodeId=="31050"){B="/liveatces";}D+='<div class="overlay">';D+='<div class="showName"><a href="'+B+'">'+C.franchiseName+"</a></div>";D+='<div class="showStatus"></div>';D+='<div class="watchLink"><a href="'+B+'">Watch</a></div>';D+="</div>";D+='<a href="'+B+'"><img src="'+C.promoImg+'" width="360" height="203" border="0" alt="'+C.franchiseName+'" /></a>';D+="</div>";A.pcPromo.set("html",D);A.showName=A.pcPromo.getElement(".showName");A.showStatus=A.pcPromo.getElement(".showStatus");A.cat=$("cat"+C.nodeId);if(C.broadcastStatus=="UPCOMING"){A.showStatus.set("html",'<a href="'+B+'" class="upNext">Coming up next</a>');A.showStatus.setStyle("position","relative");A.showName.setStyle("padding-top",5);if(A.cat){A.cat.getElement("div.showStatus").set("text","Coming up next");}}else{if(C.broadcastStatus=="IN_PROGRESS"){A.showStatus.set("html",'<a href="'+B+'" class="onAir">On the air now</a>');A.showStatus.setStyle("position","relative");A.showName.setStyle("padding-top",5);if(A.cat){A.cat.getElement("DIV.showStatus").set("text","On the air now");A.cat.addClass("showOnAir");}}else{A.showStatus.set("html","");A.showStatus.setStyle("position","absolute");A.showName.setStyles({"font-size":16,"padding-top":12});}}},findTimeDifference:function(A,B){return Math.round((this.makeUTCtime(A)-this.makeUTCtime(B||this.options.now))/1000);},makeUTCtime:function(B){var C=B.split(" "),A=C[0].split("-"),D=C[1].split(":");return Date.UTC(A[0],A[1]-1,A[2],D[0],D[1],Math.round(D[2]));},liveStreamIsOver:function(A){if(this.options.page=="show"){this.countdownElem.set("html","");}this.checkNextLiveStream(A);},loadOnDemandPlayer:function(){this.options.timer=setInterval(this.checkIfPlayerLoaded.bind(this),1000);},checkIfPlayerLoaded:function(){if($("universalPlayer0")){clearInterval(this.options.timer);previousLiveClick("","nodeId",this.options.nodeId);}},addRequestHandler:function(){var A=LiveStreamStatusCheck.reqs.push(this)-1;this.instanceName=this.options.instanceName||"lssc_"+A;LiveStreamStatusCheck.reqs[this.instanceName]=this;},getLiveStatus:function(A){this.addEvent("onLiveReceipt",A);this.fetchData("videoSearch","receiveLiveStatus",{videoIds:"",iod:"images,broadcast,breadcrumb,lowcache",broadcastStatus:"UPCOMING,IN_PROGRESS",orderBy:"broadcastStartTime",sortAsc:"true"});},receiveLiveStatus:function(A){var B;this.clearScript();if(A&&A.CNETResponse&&A.CNETResponse.Videos){B=$splat(A.CNETResponse.Videos.Video);B=B.filter(function(C){return !!(this.franchiseIds.contains(C.FranchiseId.$)&&this.options.showImages[C.Category["@id"]]);}.bind(this));this.fireEvent("onLiveReceipt",[B]);this.removeEvents("liveReceipt");}},fetchData:function(B,E,D){var C={viewType:"json",partTag:"cntv",callback:"LiveStreamStatusCheck.reqs."+this.instanceName+"."+E},A="?"+new Hash($merge(C,D||{})).toQueryString(),F=this.options.apiUrl+B+A;this.script=new Element("script",{type:"text/javascript",src:F}).inject(document.head);dbug.log("Script request: %s",F);},clearScript:function(){if($type(this.script)=="element"){this.script.dispose();}this.script=null;},getArchiveVideo:function(){if(!this.recentVideos){this.fetchData("resource/recentVideoByFranchiseId","parseArchiveVideo",{franchiseIds:this.franchiseIds.toString(),orderBy:"productionDate",sortDesc:"true"});}else{this.getArchivePromo();}},parseArchiveVideo:function(A){dbug.log("parseArchiveVideo: %o",A);if(A&&A.CNETResponse&&A.CNETResponse.Videos){this.recentVideos=$splat(A.CNETResponse.Videos.Video);this.getArchivePromo();}this.clearScript();},getArchivePromo:function(){dbug.log("getArchivePromo");var A,B;do{A=this.recentVideos.getRandom();}while(!this.options.showImages[A.Category["@id"]]);B={franchiseName:A.FranchiseName.$,nodeId:A.Category["@id"],query:A["@id"],promoImg:this.getPromoImage(A)};this.displayPromo(B);},getPromoImage:function(B){dbug.log("getPromoImage: %o",B);if(this.options.page="cnetFrontDoor"){if(this.options.showImages[B.Category["@id"]]){return this.options.showImages[B.Category["@id"]].imageUrl;}return null;}var A=B.Images.images.filter(function(C){return C["@width"]=="360";});return A[0].ImageURL.$;}});LiveStreamStatusCheck.reqs=[];var CBSCarousel=new Class({Implements:[Options,Events],options:{slide$$:"li.carouselSlide",slideInterval:6000,transitionDuration:"short",startIndex:0,indicatorActiveClass:"selected",indicatorInactiveClass:"off",indicatorDisplayStart:0,rotateAction:"mouseenter",rotateActionDuration:100,autoplay:true,useIndicators:true,indicatorContainerClass:"indicators",indicator$$:null,nextButtonClass:"carouselNext",prevButtonClass:"carouselPrev",pauseOnHover:true,pauseOnBlur:true},initialize:function(A,B){A=$(A);if(A.retrieve("carousel")){return false;}this.container=A;this.container.store("carousel",this);this.setOptions(B);this.slides=this.setSlides();if(this.options.useIndicators){this.setIndicators();}this.showSlide(this.options.startIndex);this.setButtons();if(this.options.pauseOnHover&&this.options.autoplay){this.setHoverPausing();}if(this.options.pauseOnBlur&&this.options.autoplay){this.setWindowPausing();}if(this.options.autoplay){this.autoplay();}this.fireEvent("onInitialize");return this;},setHoverPausing:function(){this.setBindings();this.container.addEvents({mouseenter:this.bound.stop,mouseleave:this.bound.autoplay});this.addEvent("onActiveSelect",this.bound.clearPausing);},setWindowPausing:function(){if(!this.bound){this.setBindings();}window.addEvents({blur:this.bound.stop,focus:this.bound.autoplay});},clearPausing:function(){this.container.removeEvent("mouseenter",this.bound.stop);this.container.removeEvent("mouseleave",this.bound.autoplay);window.removeEvent("blur",this.bound.stop);window.removeEvent("focus",this.bound.autoplay);this.removeEvent("onActiveSelect",this.bound.clearPausing);},setBindings:function(){this.bound={autoplay:this.autoplay.bind(this),stop:this.stop.bind(this),clearPausing:this.clearPausing.bind(this)};},setSlides:function(){slides=this.container.getElements(this.options.slide$$);slides.each(function(A,B){A.set("tween",{duration:this.options.transitionDuration,onStart:function(){if(A.getStyle("opacity")<0.1){A.setStyle("display","block");}},onComplete:function(){if(A.getStyle("opacity")<1){A.setStyle("display","none");}}});A.setStyles({display:(B==this.options.startIndex)?"block":"none",opacity:(B==this.options.startIndex)?1:0});}.bind(this));return slides;},setIndicators:function(){this.indicators=(this.options.indicator$$)?this.container.getElements(this.options.indicator$$):this.createIndicators();this.indicators.each(function(A,B){A.addEvent(this.options.rotateAction,this.activeSelect.bind(this,B));},this);},createIndicators:function(){var C=this.options,A=new Element("ul",{"class":C.indicatorContainerClass}).inject(this.container);var D=[];for(var B=0;B<this.slides.length;B++){D.push(new Element("li",{text:B+(C.indicatorDisplayStart||0)}).inject(A));}return D;},setButtons:function(){this.container.getElements("."+this.options.nextButtonClass).removeProperties("onclick","href").addEvent("click",this.activeSelect.bind(this,"next"));this.container.getElements("."+this.options.prevButtonClass).removeProperties("onclick","href").addEvent("click",this.activeSelect.bind(this,"prev"));},activeSelect:function(A){if($type(A)!="number"){A=this.getToIndex(A);}if(this.slideshowInt){this.stop();}this.showSlide(A);this.fireEvent("onActiveSelect");},getToIndex:function(A){if(A=="next"){return(this.currentIndex==this.slides.length-1)?0:this.currentIndex+1;}return((this.currentIndex==0)?this.slides.length:this.currentIndex)-1;},showSlide:function(A){if(A==this.currentIndex){return this;}$each(this.slides,function(B,C){if(C==A){if(this.options.useIndicators){this.indicators[C].swapClass(this.options.indicatorInactiveClass,this.options.indicatorActiveClass);}B.fade("in");}else{if(this.options.useIndicators){this.indicators[C].swapClass(this.options.indicatorActiveClass,this.options.indicatorInactiveClass);}B.fade("out");}}.bind(this));this.fireEvent("onShowSlide",[A,this.currentIndex]);this.currentIndex=A;return this;},autoplay:function(){if(this.slideshowInt){return this;}this.slideshowInt=this.rotate.periodical(this.options.slideInterval,this);this.fireEvent("onAutoPlay");return this;},stop:function(){this.slideshowInt=$clear(this.slideshowInt);this.fireEvent("onStop");return this;},rotate:function(){var B=this.currentIndex;var A=(B+1>=this.slides.length)?0:B+1;this.showSlide(A);this.fireEvent("onRotate",[A,B]);return this;},toElement:function(){return this.container;}});if(!window.UniversalPlayer){var UniversalPlayer={};UniversalPlayer.manager={playerIds:[],players:[],getId:function(){return this.addPlayerId("player"+this.playerIds.length);},addPlayerId:function(A){return this.playerIds[this.playerIds.push(A)-1];},addPlayer:function(A){return this.players[this.players.push(A)-1];}};var loadUniversalPlayer=function(A){if(document.location.search.contains("autoplay=true")){A=$merge((A||{}),{autoPlay:(document.location.search.contains("autoplay=true"))});}var B=function(C){UniversalPlayer.manager.addPlayer(new UniversalPlayer.Player(C));};if(A.parentElement){UniversalPlayer.manager.players.push(A.parentElement);if($(A.parentElement)){B(A);}else{window.addEvent("domready",B(A));}}else{A.parentElement=UniversalPlayer.manager.getId();document.write('<div id="'+A.parentElement+'"></div>');B(A);}};UniversalPlayer.Player=new Class({Implements:Options,options:{parentElement:"",playerType:"Universal",playerTitle:"Cnet Universal Player",autoPlay:false,externalPlayer:false,watchedVideoRotation:false,wrapperFloat:"left",localTest:false,geckoPath:null,lumiereQueryType:"orderBy",lumiereQueryValue:"productionDate+desc",apiPath:null,startVolume:30,expandTabs:false,showVideoInfo:false,hideBkg:false,hideTabs:false,hideLeftTab:false,hideHeader:false,useCurrentPageUrl:false,userAutoplay:false,displayMuteBtn:false,reviewsVideoOnly:false,hideEmailBtn:false,playOverlayText:"PLAY CNET VIDEO",adInterval:2,preRollAd:false,firstVideoPostAd:true,contentPostRollAd:false,adTest:false,adHost:null,relatedVideo:true,externalLinks:false,vendorVideo:false,siteId:PageVars.get("siteId"),pageType:PageVars.get("pageType"),nodeId:PageVars.get("nodeId"),oid:PageVars.getOid(),editionId:PageVars.get("editionId"),brandId:PageVars.get("brandId"),userIP:PageVars.get("userIP"),ncat:PageVars.get("breadcrumb"),userAgent:escape(navigator.userAgent),channelId:PageVars.get("channelId"),assetId:PageVars.get("assetId"),guid:PageVars.get("guid"),dvarMfg:"",refreshMpuEnabled:false,ePartner:"",cpnModule:"",refDomain:"",videoTitle:null,productionDate:null,lengthSecs:null,videoId:null,description:null,embedable:true,primaryNodeId:null,primaryNodePath:PageVars.get("breadcrumb"),externalItemId:null,externalVideoType:null,downloadable:null,isTranscriptAvailable:null,siteId:PageVars.get("siteId"),image53x40:null,image106x80:null,image320x240:null,relatedLinkUrls:null,relatedLinks:null,relatedLinkTexts:null,deliveryUrl:null,downloadUrl:null,initObject:window,initAction:"load"},initialize:function(A){this.setOptions(A);this.processPlayerData();this.setAutoPlayProperties();this.makeDiv();},processPlayerData:function(){if(this.options.useCurrentPageUrl){this.options.useCurrentPageUrl=document.URL;}if(Cookie.get("userVolume")!=null){this.options.startVolume=Cookie.get("userVolume");}},setAutoPlayProperties:function(){if(Cookie.get("userAutoPlay")=="disabled"){this.options.autoPlay=false;}},makeDiv:function(){var G=(this.options.playerType=="Widget")?"http://i.i.com.com/cnwk.1d/i/vid/uPlayerWidgetLoader.gif":"http://i.i.com.com/cnwk.1d/i/vid/uPlayerLoader.gif";if(this.options.playerType=="Widget"){var E=300;var H=250;var F="universalWidget";var B="0px";}else{if(this.options.playerType=="small"){var E=364;var H=280;var F="universalSmall";var B="0px";}else{if(this.options.playerType=="ces2010-large"){var E=640;var H=408;var F="ces2010/ces-large";var B="0px";}else{if(this.options.playerType=="ces2010-small"){var E=386;var H=262;var F="ces2010/ces-small";var B="0px";}else{if(this.options.playerType=="ces2010-live"){var E=460;var H=322;var F="ces2010/ces-live";var B="0px";}else{if(this.options.hideTabs==true){var E=460;var H=322;}else{var E=460;var H=342;}var D="http://i.i.com.com/cnwk.1d/i/vid/uPlayerBG.gif";var B="61px 0px 0px 8px";var F="universal";}}}}}var A=new Element("div",{id:"universalVideoWrapper"+UniversalPlayer.manager.players.length,"class":"float"+this.options.wrapperFloat,styles:{width:E,height:H,position:"relative",zIndex:"90","float":this.options.wrapperFloat}});if(this.options.hideTabs==true){if(this.options.pageType==4505){A.setStyle("borderBottom","#ffffff solid 2px");}else{A.setStyle("borderBottom","#cbcbcb solid 1px");}}A.inject(this.options.parentElement);var C=new Element("img",{id:"universalLoaderImg"+UniversalPlayer.manager.players.length,src:G,styles:{position:"absolute",zIndex:"100",margin:B}});this.checkFlashVersion(A,E,H,F,C,B);},checkFlashVersion:function(D,A,I,F,K,B){var E=8;var G;if(navigator.plugins&&navigator.mimeTypes.length){G=navigator.plugins["Shockwave Flash"];if(G&&G.description){G=G.description;}}else{if(Browser.Engine.trident){G=$try(function(){return new ActiveXObject("ShockwaveFlash.ShockwaveFlash").GetVariable("$version");});}}pluginVersion=(typeof G=="string")?parseInt(G.match(/\d+/)[0]):0;var J=pluginVersion>=E;if(!J){D.set("html","We&rsquo;ve detected that you need to upgrade or install Flash "+E+' or later to view our library of thousands of tech videos. Installing Flash is fast, free, and easy! Simply follow the instructions from your browser, or <a href="http://www.adobe.com/go/getflashplayer" id="flashVidErrorLink">click here to install/upgrade the free Flash player</a>.<br />&nbsp;<br />Thanks,<br />The CNET TV Team');D.setStyles({font:"normal 14px Arial, Helvetica, San Serif",lineHeight:"18px",color:"#000",margin:B,padding:"8px",width:A-16,height:I-16});}else{var H=this;if(this.options.initAction==false){H.makeSwf(D,A,I,F);}else{var C=$(this.options.initObject)||$$(this.options.initObject);C.addEvent(this.options.initAction,function(){H.makeSwf(D,A,I,F);});}}},makeSwf:function(K,J,Q,C){if(this.options.watchedVideoRotation==true){if(Cookie.get("cnetWatchedVideos")!=false){var G=Cookie.get("cnetWatchedVideos").split(",");for(r=0;r<G.length;r++){if(G.length>5){G.splice(0,1);}}var H=this.options.lumiereQueryValue.split(",");for(var N=0;N<G.length;N++){var D=G[N];for(var O=0;O<H.length;O++){if(D==H[O]){H.splice(O,1);H.push(D);var M=true;}}}var E=(M==true)?H:escape(this.options.lumiereQueryValue);}else{var E=escape(this.options.lumiereQueryValue);}}else{var E=escape(this.options.lumiereQueryValue);}var L=document.URL;if((L.contains(".com:")==true&&L.contains("uat")==false)||L.contains("preview1.")==true||L.contains("dev-server-test.dev.sub.classes")==true){var A=false;}else{var A=true;}if(this.options.adTest==true){var R="http://www.cnet.com/av/video/flv/universalPlayer/"+C+".swf";}else{if(L.contains("i.i.com.com/cnwk.1d")==true||L.contains("localhost")==true){var R="http://www.cnet.com/av/video/flv/universalPlayer/"+C+".swf";}else{if(L.contains("ssadev")==true||L.contains("publish.cnet.com:8100")==true){var R="http://publish.cnet.com:8100/av/video/flv/universalPlayer/"+C+".swf";}else{if(L.contains("proxy/preview.html?type=")==true){var R="http://cnettv.cnet.com/av/video/flv/universalPlayer/"+C+".swf";}else{var R="/av/video/flv/universalPlayer/"+C+".swf";}}}}if(this.options.localTest==true){var R="http://publish.cnet.com:8100/av/video/flv/universalPlayer/tests/"+C+".swf";}if(window.location.href.indexOf("playerVersion")>0){var F=Browser.getQueryStringValues().playerVersion;var R="/av/video/flv/universalPlayer/"+F+"/"+C+".swf";}if(this.options.playerType=="Reviews"){if(this.options.image53x40.contains("http://www.download.com")){this.options.image53x40=this.options.image53x40.split("http://www.download.com")[1];}if(this.options.image106x80.contains("http://www.download.com")){this.options.image106x80=this.options.image106x80.split("http://www.download.com")[1];}if(this.options.image320x240.contains("http://www.download.com")){this.options.image320x240=this.options.image320x240.split("http://www.download.com")[1];}}var P=K.getProperty("id").split("universalVideoWrapper")[1];var B=this.options.parentElement;var I=new Swiff(R,{id:"universalPlayer"+P,width:J,height:Q,container:K,params:{wMode:"transparent",bgcolor:"#EDEDED",scale:"noscale",salign:"lt",swLiveConnect:"true",allowScriptAccess:"always",allowFullScreen:"true"},vars:{ddom:Browser.getHost(),parent:true,live:A,parentElement:B,playerIteration:P,playerType:this.options.playerType,name:this.options.playerTitle,autoplay:this.options.autoPlay,externalPlayer:this.options.externalPlayer,geckoPath:this.options.geckoPath,type:this.options.lumiereQueryType,value:E,apiPath:this.options.apiPath,startVolume:this.options.startVolume,expandTabs:this.options.expandTabs,showVideoInfo:this.options.showVideoInfo,hideLeftTab:this.options.hideLeftTab,hideHeader:this.options.hideHeader,copyUrl:this.options.useCurrentPageUrl,userAutoplay:this.options.userAutoplay,displayMuteBtn:this.options.displayMuteBtn,hideTabs:this.options.hideTabs,reviewsVideoOnly:this.options.reviewsVideoOnly,hideBkg:this.options.hideBkg,hideEmailBtn:this.options.hideEmailBtn,playOverlayText:this.options.playOverlayText,adInterval:this.options.adInterval,firstVideoPreRoll:this.options.preRollAd,firstVideoPostRoll:this.options.firstVideoPostAd,contentPostRoll:this.options.contentPostRollAd,adTest:this.options.adTest,adHost:this.options.adHost,relatedVideo:this.options.relatedVideo,externalLinks:this.options.externalLinks,vendorVideo:this.options.vendorVideo,si:this.options.siteId,br:this.options.brandId,ip:this.options.userIP,ua:this.options.userAgent,cid:this.options.assetId,oid:this.options.oid,edid:this.options.editionId,nd:this.options.nodeId,pt:this.options.pageType,ncat:this.options.ncat,guid:this.options.guid,dvarMfg:this.options.dvarMfg,refreshMpuEnabled:this.options.refreshMpuEnabled,ePartner:this.options.ePartner,cpnModule:this.options.cpnModule,refDomain:this.options.refDomain,videoTitle:this.options.videoTitle,productionDate:this.options.productionDate,lengthSecs:this.options.lengthSecs,videoId:this.options.videoId,description:this.options.description,embedable:this.options.embedable,primaryNodeId:this.options.primaryNodeId,primaryNodePath:this.options.primaryNodeId,externalItemId:this.options.externalItemId,externalVideoType:this.options.externalVideoType,downloadable:this.options.downloadable,isTranscriptAvailable:this.options.isTranscriptAvailable,siteId:this.options.siteId,image53x40:this.options.image53x40,image106x80:this.options.image106x80,image320x240:this.options.image320x240,relatedLinkUrls:this.options.relatedLinkUrls,relatedLinks:this.options.relatedLinks,relatedLinkTexts:this.options.relatedLinkTexts,deliveryUrl:this.options.deliveryUrl,downloadUrl:this.options.downloadUrl}});}});var trackEvent=function(B){B=escape(B);var A="http://dw.com.com/redir?destUrl="+escape("http://i.i.com.com/cnwk.1d/b.gif?"+Math.floor(Math.random()*1000));A+="&edid="+this.options.editionId;A+="&oid="+this.options.oid;A+="&onid="+this.options.nd;A+="&siteid="+this.options.si;A+="&ptid="+this.options.pt;A+="&ctype=event";A+="&cval="+B;var C=new Image;C.src=A;dbug.log("trackEvent: &cval="+B);};var checkCookie=function(A){return Number(new Cookie(A).read().toString());};var setCookie=function(C,B,A){new Cookie(C).write(B,A);};var Swiff=new Class({Implements:[Options],options:{id:null,height:1,width:1,container:null,properties:{},params:{quality:"high",allowScriptAccess:"always",wMode:"transparent",swLiveConnect:true},callBacks:{},vars:{}},toElement:function(){return this.object;},initialize:function(L,M){this.instance="Swiff_"+$time();this.setOptions(M);M=this.options;var B=this.id=M.id||this.instance;var A=$(M.container);Swiff.CallBacks[this.instance]={};var E=M.params,G=M.vars,F=M.callBacks;var H=$extend({height:M.height,width:M.width},M.properties);var K=this;for(var D in F){Swiff.CallBacks[this.instance][D]=(function(N){return function(){return N.apply(K.object,arguments);};})(F[D]);G[D]="Swiff.CallBacks."+this.instance+"."+D;}E.flashVars=Hash.toQueryString(G);if(Browser.Engine.trident){H.classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000";E.movie=L;}else{H.type="application/x-shockwave-flash";H.data=L;}var J='<object id="'+B+'"';for(var I in H){J+=" "+I+'="'+H[I]+'"';}J+=">";for(var C in E){if(E[C]){J+='<param name="'+C+'" value="'+E[C]+'" />';}}J+="</object>";this.object=((A)?A.empty():new Element("div")).set("html",J).firstChild;},replaces:function(A){A=$(A,true);A.parentNode.replaceChild(this.toElement(),A);return this;},inject:function(A){$(A,true).appendChild(this.toElement());return this;},remote:function(){return Swiff.remote.apply(Swiff,[this.toElement()].extend(arguments));}});Swiff.CallBacks={};Swiff.remote=function(obj,fn){var rs=obj.CallFunction('<invoke name="'+fn+'" returntype="javascript">'+__flash__argumentsToXML(arguments,2)+"</invoke>");return eval(rs);};}var TabSwapper=new Class({Implements:[Options,Events],options:{selectedClass:"tabSelected",mouseoverClass:"tabOver",deselectedClass:"",rearrangeDOM:true,initPanel:0,smooth:false,smoothSize:false,maxSize:null,effectOptions:{duration:500},cookieName:null,cookieDays:999},tabs:[],sections:[],clickers:[],sectionFx:[],initialize:function(A){this.setOptions(A);this.setup();if(this.options.cookieName&&this.recall()){this.show(this.recall().toInt());}else{this.show(this.options.initPanel);}},setup:function(){var A=this.options;sections=$$(A.sections);tabs=$$(A.tabs);clickers=$$(A.clickers);tabs.each(function(C,B){this.addTab(C,sections[B],clickers[B],B);},this);return this;},addTab:function(C,D,A,B){C=$(C);A=$(A);D=$(D);if(this.tabs.indexOf(C)>=0&&C.retrieve("tabbered")&&this.tabs.indexOf(C)!=B&&this.options.rearrangeDOM){this.moveTab(this.tabs.indexOf(C),B);return this;}if(!$defined(B)){B=this.tabs.length;}if(B>0&&this.tabs[B-1]&&this.options.rearrangeDOM){C.inject(this.tabs[B-1],"after");D.inject(this.tabs[B-1].retrieve("section"),"after");}this.tabs.splice(B,0,C);A=A||C;C.addEvents({mouseout:function(){C.removeClass(this.options.mouseoverClass);}.bind(this),mouseover:function(){C.addClass(this.options.mouseoverClass);}.bind(this)});A.addEvent("click",function(){this.show(B);}.bind(this));C.store("tabbered",true);C.store("section",D);C.store("clicker",A);this.hideSection(B);return this;},removeTab:function(B){var A=this.tabs[this.now];if(this.now==B){if(B>0){this.show(B-1);}else{if(B<this.tabs.length){this.show(B+1);}}}this.now=this.tabs.indexOf(A);return this;},moveTab:function(H,G){var C=this.tabs[H];var B=C.retrieve("clicker");var E=C.retrieve("section");var A=this.tabs[G];var F=A.retrieve("clicker");var D=A.retrieve("section");this.tabs.erase(C).splice(G,0,C);C.inject(A,"before");B.inject(F,"before");E.inject(D,"before");return this;},show:function(A){if(!$chk(this.now)){this.tabs.each(function(C,B){if(A!=B){this.hideSection(B);}},this);}this.showSection(A).save(A);return this;},save:function(A){if(this.options.cookieName){Cookie.write(this.options.cookieName,A,{duration:this.options.cookieDays});}return this;},recall:function(){return(this.options.cookieName)?$pick(Cookie.read(this.options.cookieName),false):false;},hideSection:function(A){var C=this.tabs[A];if(!C){return this;}var B=C.retrieve("section");if(!B){return this;}if(B.getStyle("display")!="none"){this.lastHeight=B.getSize().y;B.setStyle("display","none");C.swapClass(this.options.deselectedClass,this.options.selectedClass);this.fireEvent("onBackground",[A,B,C]);}return this;},showSection:function(A){var E=this.tabs[A];if(!E){return this;}var B=E.retrieve("section");if(!B){return this;}var F=this.options.smooth&&(!Browser.Engine.trident4||(Browser.Engine.trident4&&B.fxOpacityOk()));if(this.now!=A){if(!E.retrieve("tabFx")){E.store("tabFx",new Fx.Morph(B,this.options.effectOptions));}var G={display:"block",overflow:"hidden"};if(F){G.opacity=0;}var D=false;if(F){D={opacity:1};}else{if(B.getStyle("opacity").toInt()<1){B.setStyle("opacity",1);if(!this.options.smoothSize){this.fireEvent("onActiveAfterFx",[A,B,E]);}}}if(this.options.smoothSize){var C=B.getDimensions().height;if($chk(this.options.maxSize)&&this.options.maxSize<C){C=this.options.maxSize;}if(!D){D={};}D.height=C;}if($chk(this.now)){this.hideSection(this.now);}if(this.options.smoothSize&&this.lastHeight){G.height=this.lastHeight;}B.setStyles(G);if(D){E.retrieve("tabFx").start(D).chain(function(){this.fireEvent("onActiveAfterFx",[A,B,E]);B.setStyle("height","auto");}.bind(this));}this.now=A;this.fireEvent("onActive",[A,B,E]);}E.swapClass(this.options.selectedClass,this.options.deselectedClass);return this;}});var CnetDoorCarousel=new Class({Implements:StyleWriter,initialize:function(){if($$(".macInteraction").length){this.createStyle("#rubicsTextAd {display:none !important;}","hideRubics");}this.carousel=new CBSCarousel("carouselMain",{slide$$:".slide",slideInterval:7000,autoplay:false,transitionDuration:700,indicatorContainerClass:"#carouselMain .thumbContainer",indicator$$:".featureButton",onShowSlide:function(A){$$(this.options.indicator$$).each(function(B,C){if(C==A){B.morph({top:-10});B.getElement("img").morph({"margin-bottom":20});}else{B.morph({top:0});B.getElement("img").morph({"margin-bottom":0});}});}});window.addEvent("domready",this.startCarousel.bind(this));},startCarousel:function(){var A=$$(".macInteraction"),C,B;A.each(function(D){var E;if(!C&&!B){if(E=D.getProperty("mac-interaction-stop")){B=true;}if(E=D.getProperty("mac-interaction-carousel")){C=E;}}});if(C){this.carousel.options.slideInterval=C.toInt();}if(!B){this.carousel.autoplay();}}});window.addEvent("domready",function(){if($$(".tabbedPromoUnit .tabs")){new TabSwapper({selectedClass:"",deselectedClass:"selected",tabs:$$("ul.tabs li"),clickers:$$("ul.tabs li a"),sections:$$(".content ul"),smooth:true});}$$(".oneAssetPromo a").each(function(A){if(!A.getProperty("href")){A.addEvent("mouseenter",function(){this.setProperty("over","true");});A.addEvent("mouseleave",function(){this.removeProperty("over");});A.addEvent("click",function(){var B=function(D){D=D.getElement("img")||D;var F=C(A),E=window.getScrollTop();return(F.top<(E+window.getHeight()))&&(F.bottom>E);},C=function(D){var F=D=$(D);var E=D.getCoordinates();if(Browser.Engine.trident){E.top=0;do{E.top+=F.offsetTop;}while(F=F.offsetParent);E.bottom=E.top+E.height;}return E;};if(A.getProperty("over")){if(B(A)){A.setProperty("href",A.getProperty("uri"));}}});}});});
   }
       
