
   if(!dbugScripts("download",["download.tron.postdl2.js"])) {
   /*	download.tron.postdl2.js - packed	*/
       var WatchList={Adder:new Class({Implements:[Options,Events],options:{container:"watchlist",pageType:"3353",referencedType:25,addManual:23,addAuto:85,viewName:".add-to-watch-list-postdl"},commands:{add:"addWatchItem",remove:"removeListItem",sync:"syncListItem",check:"syncIfWatchItemExists"},tipsTitles:[10320142,10208565,10028984,10047473,10251792,10007677,10003164,10029188,10039884,10051892,10296306,10057840,10021962,10155605,10411076,10265538,10122137,10019223,10590188],initialize:function(B,A){this.setOptions(A);this.referencedId=B;this.container=$(this.options.container);this.getPreferences();return this;},getPreferences:function(){this.prefs={autoAdd:(Cookie.read("DLWatchlistAutoAdd-SW_PS")!="false"),tipsEmail:(new Cookie("DLWatchlistAutoAdd-SW_PS-TTAlert").read()!="false"),rateEmail:(new Cookie("DLWatchlistAutoAdd-SW_PS-SYRAlert").read()!="false")};},checkTipsTitles:function(){if(window.location.href&&!window.location.href.test("also-dwnld")&&this.prefs.tipsEmail){if(this.tipsTitles.contains(this.referencedId)){return"&eventTypes=2";}}return"";},addWatchItem:function(C,B){if(this.needFBPerms()){this.checkFBPerms();}var A="cmd=addWatchItem";A+="&referencedId="+this.referencedId;if(this.options.viewName){A+="&viewName="+this.options.viewName;}A+="&referencedType="+this.options.referencedType;if(C.action){A+="&usrAction="+C.action;}A+="&eventTypes=1";if(!B){if(this.prefs.rateEmail){A+="&eventTypes=4";}A+=this.checkTipsTitles();}A+="&component";this.makeRequest({pageType:"3353",complete:this.checkResponse.bind(this),queryString:A});return this;},syncWatchItem:function(B){var A="cmd=syncIfWatchItemExists";A+="&referencedId="+this.referencedId;if(this.options.viewName){A+="&viewName="+this.options.viewName;}A+="&referencedType="+this.options.referencedType;A+="&eventTypes=1";if(!B){if(this.prefs.rateEmail){A+="&eventTypes=4";}A+=this.checkTipsTitles();}A+="&component";this.makeRequest({pageType:"3353",complete:this.checkResponse.bind(this),queryString:A});return this;},makeRequest:function(B){B=B||{};var A=PageVars.getPath({pageType:B.pageType||"3353",assetId:0,pageNumber:null});var D=25;var C=new Request({url:A,method:"get",onSuccess:B.complete,onFailure:function(){C.send.delay(D*=2);},data:B.queryString});C.send();},manualAdd:function(A){A=$(A)||null;this.addWatchItem({action:this.addManual});},needFBPerms:function(){if(!UserVars.isRemembered()&&CURS.Social.fb.isUser()&&CURS.Social.fb.isActive()){var A=false;var C=new CURS.RPS.Request({resource:"rps-regIdToEmail",data:{regId:UserVars.get("ursRegId")},async:false}).send();try{A=C.response.json.User.Email["$"];dbug.log(A);}catch(B){dbug.log("Email request failed: %o",B);return true;}dbug.log("Need email perms? %s",!!(A.match("proxymail.facebook.com")));return !!(A.match("proxymail.facebook.com"));}dbug.log("returning false");return false;},checkFBPerms:function(){try{CURS.Social.fb.ensureInit(function(){var C=Cookie.read(CURS.Social.fb.cookieName+"_permsCheck");C=(!C||C=="true")?{}:JSON.decode(C);if(!C[UserVars.get("ursRegId","string")]){FB.Connect.showPermissionDialog("email",function(){C[UserVars.get("ursRegId","string")]="true";Cookie.write(CURS.Social.fb.cookieName+"_permsCheck",JSON.encode(C),{path:"/",domain:CURS.Manager.getCookieHost(),expires:365});});}});}catch(B){var A=Cookie.read(CURS.Social.fb.cookieName+"_permsCheck");A=(!A||A=="true")?{}:JSON.decode(A);if(!A[UserVars.get("ursRegId","string")]){FB.login(function(C){A[UserVars.get("ursRegId","string")]="true";Cookie.write(CURS.Social.fb.cookieName+"_permsCheck",JSON.encode(A),{path:"/",domain:CURS.Manager.getCookieHost(),expires:365});},{perms:"email"});}}}})};WatchList.PostDL=new Class({Extends:WatchList.Adder,initialize:function(B,A){this.parent(B,A);this.jnShell=$("urs_mini_form")||$("joinNowPromo");if(!UserVars.isLoggedIn()){this.setUpRegisterPromo();}else{this.tryAutoAdd();}this.addEvent("onAdd",function(){this.jnShell.dissolve();$("watchListAutoAddOff").dissolve();$("watchListAutoAdd").reveal();}.bind(this));this.addEvent("onAlreadyAdded",function(){this.jnShell.dissolve();try{$("watchListAlreadyAdded").reveal();}catch(C){$("watchListAutoAdd").reveal();}}.bind(this));this.addEvent("onPleaseAdd",function(){this.jnShell.dissolve();$("watchListAutoAddOff").reveal();}.bind(this));return this;},checkResponse:function(A){if(A.test(/download has been added/i)||A.test(/We've added this to your/i)){this.fireEvent("onAdd");}else{if(A.test(/product is on your/i)){this.fireEvent("onAlreadyAdded");}else{if(A.test(/get update alerts/i)){this.fireEvent("onPleaseAdd");}else{dbug.log("Watchlist failed to add product. Response: %s",A);}}}},tryAutoAdd:function(){if(this.prefs.autoAdd||window.location.search.test("addWatchItem=true")){var A=(window.location.search.test("addWatchItem=true"))?this.options.addManual:this.options.addAuto;this.addWatchItem({action:A});}else{this.syncWatchItem();}},setUpRegisterPromo:function(){try{if(!this.jnShell){return false;}this.jnShell.getElement("form").addEvent("submit",function(C){C.stop();this.tryLogin(this.jnShell);}.bind(this));var A=this.jnShell.getElement("input.emailInput");A.setProperty("originalValue",A.get("value"));A.addEvent("focus",function(C){if(this.value==$(this).getProperty("originalValue")){this.value="";}});}catch(B){}this.jnShell.setStyle("display","block");},tryLogin:function(B){B=$(B);var C=B.getElement("input[name=EMAILADDR]");var A=(C.get("value")!=C.getProperty("originalValue")&&C.get("value").trim().length)?C.get("value"):"";CURS.Manager.checkLogin({registerHed:"Join CNET to track updates to this product",loginHed:"Log in to CNET to track updates to this product",appId:"133",path:PageVars.getRefreshPath({idl:"n",addWatchItem:"true",tag:"wl_add_regcnf_pdl"}),cval:"joinnow",email:A,nextAction:this.manualAdd.pass(B,this)});}});var PageRefresh=new Class({timer:null,initialize:function(){this.startTimer();},startTimer:function(){if(!this.timer){this.timer=this.redir.delay(180000,this);}},stopTimer:function(){this.timer=$clear(this.timer);},redir:function(){window.location="/"+PageVars.getOid({pageType:3055})+".html?tag=pdl-redir";}});if(DLHelp==undefined){var DLHelp={};}DLHelp.Prefs=new Class({Manager:{nextAction:$empty},Implements:Options,options:{triggerSel:".helpLink"},initialize:function(B,A){this.shell=$(B).inject(document.body);this.triggers=$$(this.options.triggerSel);this.triggers.addEvent("click",this.toggle.bind(this));this.shell.getElements(".closeModal").addEvent("click",this.hide.bind(this));this.ping=new Request({url:"/3353-20_4-0.html",method:"get"});},show:function(A){goPPDl.stopTimer();this.shell.setPosition({});this.shell.setStyle("top",window.getScrollTop()+50);this.shell.setStyle("display","block");},hide:function(){goPPDl.startTimer();this.shell.setStyle("display","none");},toggle:function(){if(this.shell.getStyle("display")=="none"){this.show();}else{this.hide();}}});var goPPDl=new PageRefresh();var startTimer=function(){if(!this.timer){this.startTimer();}}.bind(goPPDl);CURS.Manager.addEvent("onCheckLogin",goPPDl.stopTimer.bind(goPPDl));if(!UserVars.isLoggedIn()){CURS.Manager.addEvent("onLogin",startTimer);CURS.Manager.addEvent("onClose",startTimer);}window.addEvent("domready",function(){new DLHelp.Prefs("DLHelpPrefsModal");});WatchList.initialize=function(D,B){var C=0;var A=function(F,E){try{WatchList.instance=new WatchList.PostDL(F,E).addEvents({onAdd:startTimer,onAlreadyAdded:startTimer});}catch(G){if(++C<10){dbug.log("Failed watchlist adding. Trying again in 100ms: %o",G);A.delay(200);}}}.pass([D,B]);window.addEvent("domready",A);};WatchList.manualAdd=function(A){WatchList.instance.manualAdd("watchListAutoAddOff");};try{PageVars.getRefreshPath=function(A){A=A||{};return new Link(location.href).mergeQueryString($merge({refresh:new Date().getTime(),idl:"n"},A)).get("href");};}catch(e){dbug.log("PostDL getlogoutpath failed: %o",e);}
   }
       
