
(function($,Edge,compId){var Composition=Edge.Composition,Symbol=Edge.Symbol;
//Edge symbol: 'stage'
(function(symbolName){Symbol.bindElementAction(compId,symbolName,"document","compositionReady",function(sym,e){var holeCount=0;var slide=-410;var headline;var headlinetxt=sym.getSymbol("styleHead").$("headlineTxt").css("pointer-events","none");var stand;var standtxt=sym.getSymbol("styleHead").$("standTxt").css("pointer-events","none");var source;var sourcetxt=sym.getSymbol("styleBase").$("sourceTxt").css("pointer-events","none");var winner;var winnertxt=sym.getSymbol("winnersMc").$("winner").css("pointer-events","none");var course;var coursetxt=sym.getSymbol("winnersMc").$("course0").css("pointer-events","none");var menuTxt=[];menuTxt[0]=sym.$("menuTxt0").css({"pointer-events":"none",});menuTxt[1]=sym.$("menuTxt1").css({"pointer-events":"none"});menuTxt[2]=sym.$("menuTxt2").css({"pointer-events":"none"});var menuArr=[];var btnNo=0;for(var b=0;b<3;b++){sym.getSymbol("menuBtnsMc").getSymbol("menuBtn"+b).$("menuIcon").attr("src","images/menuIcon"+b+".png");}
var txt=[];txt[0]=sym.$("txt0").css({"pointer-events":"none",});txt[1]=sym.$("txt1").css({"pointer-events":"none"});txt[2]=sym.$("txt2").css({"pointer-events":"none"});txt[3]=sym.$("txt3").css({"pointer-events":"none"});txt[4]=sym.getSymbol("cardMc").$("txt4").css({"pointer-events":"none"});txt[5]=sym.getSymbol("cardMc").$("txt5").css({"pointer-events":"none"});txt[6]=sym.getSymbol("cardMc").$("txt6").css({"pointer-events":"none"});txt[7]=sym.getSymbol("cardMc").$("txt7").css({"pointer-events":"none"});txt[8]=sym.getSymbol("cardMc").$("txt8").css({"pointer-events":"none"});txt[9]=sym.getSymbol("cardMc").$("txt9").css({"pointer-events":"none"});txt[10]=sym.getSymbol("cardMc").$("txt10").css({"pointer-events":"none"});txt[11]=sym.getSymbol("cardMc").$("txt11").css({"pointer-events":"none"});txt[12]=sym.$("txt12").css({"pointer-events":"none"});txt[13]=sym.$("txt13").css({"pointer-events":"none"});txt[14]=sym.getSymbol("holesMc").$("txt14").css({"pointer-events":"none"});txt[15]=sym.$("txt15").css({"pointer-events":"none"});txt[16]=sym.$("txt16").css({"pointer-events":"none"});txt[17]=sym.$("txt17").css({"pointer-events":"none"});txt[18]=sym.$("txt18").css({"pointer-events":"none"});txt[19]=sym.$("txt19").css({"pointer-events":"none"});txt[20]=sym.$("txt20").css({"pointer-events":"none"});txt[21]=sym.$("txt21").css({"pointer-events":"none"});txt[22]=sym.$("txt22").css({"pointer-events":"none"});txt[23]=sym.$("txt23").css({"pointer-events":"none"});txt[24]=sym.$("txt24").css({"pointer-events":"none"});txt[25]=sym.$("txt25").css({"pointer-events":"none"});txt[26]=sym.$("txt26").css({"pointer-events":"none"});txt[27]=sym.$("txt27").css({"pointer-events":"none"});txt[28]=sym.$("txt28").css({"pointer-events":"none"});txt[29]=sym.$("txt29").css({"pointer-events":"none"});txt[30]=sym.$("txt30").css({"pointer-events":"none"});txt[31]=sym.$("txt31").css({"pointer-events":"none"});txt[32]=sym.getSymbol("winnersMc").$("txt32").css({"pointer-events":"none"});txt[33]=sym.getSymbol("winnersMc").$("txt33").css({"pointer-events":"none"});txt[34]=sym.getSymbol("winnersMc").$("txt34").css({"pointer-events":"none"});txt[35]=sym.getSymbol("winnersMc").$("txt35").css({"pointer-events":"none"});var txtArr=[];$.ajax({type:"GET",url:"GN32080.xml",dataType:"xml",success:function(xml){custonCol=$(xml).find('customColour').text();sym.getSymbol("styleHead").$("headerBox").css("background-color",custonCol);headline=$(xml).find('headline').text();headlinetxt.html(headline);stand=$(xml).find('stand').text();standtxt.html(stand);source=$(xml).find('source').text();sourcetxt.html(source);for(var i=0;i<3;i++){menuArr[i]=$(xml).find('menuTxt'+i).text();menuTxt[i].html(menuArr[i]);}
for(var i=0;i<36;i++){txtArr[i]=$(xml).find('txt'+i).text();txt[i].html(txtArr[i]);}}});menuArray=[];for(var h=0;h<3;h++){var menuBtnSymbols=sym.getSymbol("menuBtnsMc").getSymbol("menuBtn"+h);menuBtnSymbols.setVariable("menuId",h);menuArray.push(menuBtnSymbols);}
$.each(menuArray,function(count,menuInTheArray){var menuBtnItem=$(menuInTheArray);var menuBtnElement=menuInTheArray.getSymbolElement();menuBtnElement.bind("click",{menuId:count},menuBtnClick);menuBtnElement.bind("touchstart",{menuId:count},menuBtnClick);menuBtnElement.bind("mouseover",{menuId:count},menuShow);menuBtnElement.bind("mouseout",{menuId:count},menuHide);})
function resetmenu(){for(var h=0;h<menuArray.length;h++){menuArray[h].$("btnClick").fadeOut(0);menuArray[h].$("btnOver").fadeOut(0);}}
resetmenu();function menuBtnClick(e){resetmenu();var menuMenu_id=(e.data.menuId);sym.getSymbol("menuBtnsMc").getSymbol("menuBtn"+menuMenu_id).$("btnClick").fadeIn(0);btnNo=menuMenu_id;if(menuMenu_id==0){sym.$("winnersMc").stop().animate({left:900},500,'easeOutCubic');sym.$("holesMc").stop().animate({left:390},500,'easeOutCubic');sym.$("cardMc").stop().animate({left:900},500,'easeOutCubic');sym.$("navBtns").stop().animate({left:730},500,'easeOutCubic');}
if(menuMenu_id==1){sym.$("holesMc").stop().animate({left:900},500,'easeOutCubic');sym.$("winnersMc").stop().animate({left:900},500,'easeOutCubic');sym.$("cardMc").stop().animate({left:460},500,'easeOutCubic');sym.$("navBtns").stop().animate({left:2000},500,'easeOutCubic');}
if(menuMenu_id==2){sym.$("winnersMc").stop().animate({left:0},500,'easeOutCubic');}}
function menuShow(e){var menuMenu_id=(e.data.menuId);sym.getSymbol("menuBtnsMc").getSymbol("menuBtn"+menuMenu_id).$("btnOver").fadeIn(0);btnNo=menuMenu_id;menuTxttxt.html(menuTxt[btnNo]);}
function menuHide(e){var menuMenu_id=(e.data.menuId);sym.getSymbol("menuBtnsMc").getSymbol("menuBtn"+menuMenu_id).$("btnOver").fadeOut(0);sym.getSymbol("menuBtnsMc").$("menuTxt").empty();}
sym.getSymbol("menuBtnsMc").getSymbol("menuBtn0").$("btnClick").fadeIn(0);var slide=-410;stageBtnArray=[];for(var h=0;h<18;h++){var stageBtnBtnSymbols=sym.getSymbol("roundBtnsMc").getSymbol("roundBtn"+h);stageBtnBtnSymbols.setVariable("stageBtnId",h);stageBtnArray.push(stageBtnBtnSymbols);}
$.each(stageBtnArray,function(count,stageBtnInTheArray){var stageBtnBtnItem=$(stageBtnInTheArray);var stageBtnBtnElement=stageBtnInTheArray.getSymbolElement();stageBtnBtnElement.bind("click",{stageBtnId:count},stageBtnBtnClick);stageBtnBtnElement.bind("touchstart",{stageBtnId:count},stageBtnBtnClick);stageBtnBtnElement.bind("mouseover",{stageBtnId:count},stageBtnShow);stageBtnBtnElement.bind("mouseout",{stageBtnId:count},stageBtnHide);})
function stageBtnBtnClick(e){resetAllBtn();var stageBtnstageBtn_id=(e.data.stageBtnId);holeCount=stageBtnstageBtn_id;resetcardBtn();btnClick();}
function stageBtnShow(e){var stageBtnstageBtn_id=(e.data.stageBtnId);sym.getSymbol("roundBtnsMc").getSymbol("roundBtn"+stageBtnstageBtn_id).$("btnOver").fadeIn(0);}
function stageBtnHide(e){var stageBtnstageBtn_id=(e.data.stageBtnId);sym.getSymbol("roundBtnsMc").getSymbol("roundBtn"+stageBtnstageBtn_id).$("btnOver").fadeOut(0);}
function resetAllBtn(){for(var h=0;h<stageBtnArray.length;h++){stageBtnArray[h].$("btnClick").fadeOut(0);stageBtnArray[h].$("btnOver").fadeOut(0);}}
resetAllBtn();sym.getSymbol("roundBtnsMc").getSymbol("roundBtn0").$("btnClick").fadeIn(0);for(var n=0;n<18;n++){sym.getSymbol("holesMc").getSymbol("allHolesMc").$("hole"+(n+1)).stop().animate({left:-slide*n},0);}
for(var h=0;h<18;h++){sym.getSymbol("roundBtnsMc").getSymbol("roundBtn"+h).$("txt").html(h+1);sym.getSymbol("cardMc").getSymbol("cardBtn"+h).$("noTxt").html(h+1);}
function btnClick(){resetAllBtn();sym.getSymbol("roundBtnsMc").getSymbol("roundBtn"+holeCount).$("btnClick").fadeIn(0);sym.getSymbol("holesMc").$("allHolesMc").stop().animate({left:slide*holeCount},500,'easeOutCubic');sym.getSymbol("holesMc").$("holeNo").html(holeCount+1);sym.getSymbol("cardMc").getSymbol("cardBtn"+holeCount).$("btnClick").fadeIn(0);sym.getSymbol("holesMc").$("txt14").empty();sym.getSymbol("holesMc").$("txt14").append(txtArr[holeCount+14]);if(holeCount<=0){sym.getSymbol("navBtns").$("btnBack").fadeOut(0);}else{sym.getSymbol("navBtns").$("btnBack").fadeIn(0);}
if(holeCount>=17){sym.getSymbol("navBtns").$("btnNext").fadeOut(0);}else{sym.getSymbol("navBtns").$("btnNext").fadeIn(0);}}
btnClick();sym.getSymbol("navBtns").$("btnNext").on("click",function(){e.stopPropagation();e.preventDefault();resetcardBtn();holeCount++;btnClick();sym.getSymbol("navBtns").getSymbol("btnBack").$("btnOver").fadeOut(0);});sym.getSymbol("navBtns").$("btnNext").on("mouseover",function(){sym.getSymbol("navBtns").getSymbol("btnNext").$("btnOver").fadeIn(200);});sym.getSymbol("navBtns").$("btnNext").on("mouseout",function(){sym.getSymbol("navBtns").getSymbol("btnNext").$("btnOver").fadeOut(200);});sym.getSymbol("navBtns").$("btnBack").on("click",function(){e.stopPropagation();e.preventDefault();resetcardBtn();holeCount--;btnClick();sym.getSymbol("btnNext").$("btnOver").fadeOut(0);});sym.getSymbol("navBtns").$("btnBack").on("mouseover",function(){sym.getSymbol("navBtns").getSymbol("btnBack").$("btnOver").fadeIn(200);});sym.getSymbol("navBtns").$("btnBack").on("mouseout",function(){sym.getSymbol("navBtns").getSymbol("btnBack").$("btnOver").fadeOut(200);});sym.getSymbol("navBtns").getSymbol("btnNext").$("btnOver").fadeOut(0);sym.getSymbol("navBtns").getSymbol("btnBack").$("btnOver").fadeOut(0);cardBtnArray=[];for(var j=0;j<18;j++){var cardBtnSymbols=sym.getSymbol("cardMc").getSymbol("cardBtn"+j);cardBtnSymbols.setVariable("cardBtnId",j);cardBtnArray.push(cardBtnSymbols);}
$.each(cardBtnArray,function(count,cardBtnInTheArray){var cardBtnItem=$(cardBtnInTheArray);var cardBtnElement=cardBtnInTheArray.getSymbolElement();cardBtnElement.bind("click",{cardBtnId:count},cardBtnClick);cardBtnElement.bind("touchstart",{cardBtnId:count},cardBtnClick);cardBtnElement.bind("mouseover",{cardBtnId:count},cardBtnShow);cardBtnElement.bind("mouseout",{cardBtnId:count},cardBtnHide);})
function cardBtnClick(e){var cardBtn_id=(e.data.cardBtnId);holeCount=cardBtn_id;resetcardBtn();btnClick();}
function resetcardBtn(){for(var j=0;j<cardBtnArray.length;j++){cardBtnArray[j].$("btnClick").fadeOut(0);cardBtnArray[j].$("btnOver").fadeOut(0);}}
resetcardBtn();function cardBtnShow(e){var cardBtn_id=(e.data.cardBtnId);sym.getSymbol("cardMc").getSymbol("cardBtn"+cardBtn_id).$("btnOver").fadeIn(0);}
function cardBtnHide(e){var cardBtn_id=(e.data.cardBtnId);sym.getSymbol("cardMc").getSymbol("cardBtn"+cardBtn_id).$("btnOver").fadeOut(0);}
sym.getSymbol("cardMc").getSymbol("cardBtn0").$("btnOver").fadeIn(0);for(var b=0;b<10;b++){sym.getSymbol("winnersMc").getSymbol("winnersBtn"+b).$("txt").html(b+2004)}
winnersBtnArray=[];for(var w=0;w<10;w++){var winnersBtnSymbols=sym.getSymbol("winnersMc").getSymbol("winnersBtn"+w);winnersBtnSymbols.setVariable("winnersBtnId",w);winnersBtnArray.push(winnersBtnSymbols);}
$.each(winnersBtnArray,function(count,winnersBtnInTheArray){var winnersBtnItem=$(winnersBtnInTheArray);var winnersBtnElement=winnersBtnInTheArray.getSymbolElement();winnersBtnElement.bind("click touchstart",{winnersBtnId:count},winnersBtnClick);winnersBtnElement.bind("mouseover",{winnersBtnId:count},winnersBtnShow);winnersBtnElement.bind("mouseout",{winnersBtnId:count},winnersBtnHide);})
function resetwinnersBtn(){for(var k=0;k<winnersBtnArray.length;k++){winnersBtnArray[k].$("btnClick").fadeOut(0);winnersBtnArray[k].$("btnOver").fadeOut(0);}}
resetwinnersBtn();function winnersBtnClick(e){sym.getSymbol("winnersMc").$("table").empty()
resetwinnersBtn();var winnersBtn_id=(e.data.winnersBtnId);sym.getSymbol("winnersMc").getSymbol("winnersBtn"+winnersBtn_id).$("btnClick").fadeIn(0);sym.getSymbol("winnersMc").$("winPic").attr("src","images/w"+(winnersBtn_id+2004)+".jpg");getYear(2004+winnersBtn_id);}
function winnersBtnShow(e){var winnersBtn_id=(e.data.winnersBtnId);sym.getSymbol("winnersMc").getSymbol("winnersBtn"+winnersBtn_id).$("btnOver").fadeIn(0);}
function winnersBtnHide(e){var winnersBtn_id=(e.data.winnersBtnId);sym.getSymbol("winnersMc").getSymbol("winnersBtn"+winnersBtn_id).$("btnOver").fadeOut(0);}
sym.getSymbol("winnersMc").getSymbol("winnersBtn9").$("btnClick").fadeIn(0);function getYear(year){$.ajax({type:"GET",url:year+"_results.xml",dataType:"xml",success:function(xml){winner=$(xml).find('winner').text();winnertxt.html(winner);course=$(xml).find('course').text();coursetxt.html(course);var htmlOutput='';htmlOutput+='<table width="100%" border="0" cellpadding="3" cellspacing="0">';var playerName;var playerScore;var playerPrize;$('Ranked',xml).each(function(i){playerName=$(this).find("person").text();playerScore=$(this).find("score").text();playerPrize=$(this).find("prize").text();var playerdata=winnersTable(playerName,playerScore,playerPrize);htmlOutput=htmlOutput+playerdata;});htmlOutput+='</table>';sym.getSymbol("winnersMc").$("table").append(htmlOutput);sym.getSymbol("winnersMc").$("table tr:odd").css({"text-align":"left","background-color":"#accdec","color":"#000000","font":"13px Pragmatica-web, sans-serif"});sym.getSymbol("winnersMc").$("table tr:even").css({"text-align":"left","background-color":"#e0e7f5","color":"#000000","font":"13px Pragmatica-web, sans-serif"});sym.getSymbol("winnersMc").$("table tr:first-child").css({"text-align":"left","font-weight":"bold","background-color":"#e60000","color":"#ffffff","font":"13px, Pragmatica-web, sans-serif"});}});function winnersTable(playerName,playerScore,playerPrize){output='';output+='<tr>';output+='<td style="width:40%;font-weight: bold;">'+playerName+'</td>';output+='<td style="width:40%;">'+playerScore+'</td>';output+='<td style="width:20%;font-weight: bold;">'+playerPrize+'</td>';output+='</tr>';return output;}}
getYear(2013);sym.getSymbol("winnersMc").$("winPic").attr("src","images/w2013.jpg");});
//Edge binding end 

// VIDEO BTN 1 =========================================================

// VIDEO BTN 2 =========================================================
})("stage");
//Edge symbol end:'stage'

//=========================================================

//Edge symbol: 'StyleBase'
(function(symbolName){})("StyleBase");
//Edge symbol end:'StyleBase'

//=========================================================

//Edge symbol: 'styleHead_1'
(function(symbolName){})("styleHead");
//Edge symbol end:'styleHead'

//=========================================================

//Edge symbol: 'menuBtn_2'
(function(symbolName){})("menuBtn");
//Edge symbol end:'menuBtn'

//=========================================================

//Edge symbol: 'Preloader'
(function(symbolName){})("Preloader");
//Edge symbol end:'Preloader'

//=========================================================

//Edge symbol: 'menuBtnsMc'
(function(symbolName){})("menuBtnsMc");
//Edge symbol end:'menuBtnsMc'

//=========================================================

//Edge symbol: 'cardBtn'
(function(symbolName){})("cardBtn");
//Edge symbol end:'cardBtn'

//=========================================================

//Edge symbol: 'stroke'
(function(symbolName){})("stroke");
//Edge symbol end:'stroke'

//=========================================================

//Edge symbol: 'tableMc'
(function(symbolName){})("tableMc");
//Edge symbol end:'tableMc'

//=========================================================

//Edge symbol: 'roundBtnsMc'
(function(symbolName){})("roundBtnsMc");
//Edge symbol end:'roundBtnsMc'

//=========================================================

//Edge symbol: 'roundBtn'
(function(symbolName){})("roundBtn");
//Edge symbol end:'roundBtn'

//=========================================================

//Edge symbol: 'allHolesMc'
(function(symbolName){})("allHolesMc");
//Edge symbol end:'allHolesMc'

//=========================================================

//Edge symbol: 'holesMc'
(function(symbolName){})("holesMc");
//Edge symbol end:'holesMc'

//=========================================================

//Edge symbol: 'arrowBtn'
(function(symbolName){})("arrowBtn");
//Edge symbol end:'arrowBtn'

//=========================================================

//Edge symbol: 'btnBackHiiden'
(function(symbolName){})("btnBackHiiden");
//Edge symbol end:'btnBackHiiden'

//=========================================================

//Edge symbol: 'navBtns'
(function(symbolName){})("navBtns");
//Edge symbol end:'navBtns'

//=========================================================

//Edge symbol: 'winnersMc'
(function(symbolName){})("winnersMc");
//Edge symbol end:'winnersMc'

//=========================================================

//Edge symbol: 'winnersBtn'
(function(symbolName){})("winnersBtn");
//Edge symbol end:'winnersBtn'
})(jQuery,AdobeEdge,"GraphicNews32080");