var RSSfeed="http://news.google.com/?output=rss";var NewsHeader="vds radio News headlines. .";var NewsFooter="Thank you for listening vds radio News headlines. See you next time.";var vdsp;var vds;var urls=new Array();var title=new Array();var bodyText=new Array();var current;var allReadOutFlag=0;$(document).ready(function(){try{vdsp=new VoiceDeliveryPlayer("vdsp");vds=new VoiceDelivery(vdsp,"vds");vds.setRate(0);vds.setCast("KateENf")}catch(A){alert("Cannot Create Object.")}});function output(){$("#parent1").wslide({width:500,height:700,autolink:false,col:1,duration:800})}function readout(A){if(allReadOutFlag==0){vdsp.setVolume(1);vdsp.speakStop();vds.speak($(A).text())}}function readAllNews(){location.href="#parent1-4"}function readAll(){var B=NewsHeader;for(var A=0;A<10;A++){B+=title[A];B+=". .";B+=bodyText[A];B+="."}B+=NewsFooter;vdsp.speakStop();vds.speak(B)}function shutup(){vdsp.speakStop();allReadOutFlag=0}function readAll2(){current=0;allReadOutFlag=1;$("[class^=indexList]").css({"list-style":"none"});$('a[href="#parent1-1"]').trigger("click");$("#index-parent1-1").css({"list-style":"url(radioOn.png)"});vdsp.speakStop();vds.speak(NewsHeader+title[current]+". ."+bodyText[current]+".")}function vdsSpeakFinishCallback(A){current++;if(current<10){$("#index-parent1-"+current).css({"list-style":"none"});var C=current-1;$("#index-parent1-"+C).css({"list-style":"none"});var B=current+1;$("#index-parent1-"+B).css({"list-style":"url(radioOn.png)"});$('a[href="#parent1-'+B+'"]').trigger("click");vds.speak(title[current]+". ."+bodyText[current]+".")}else{if(current==10){vds.speak(NewsFooter);$('a[href="#parent1-1"]').trigger("click");allReadOutFlag=0;$("[class^=indexList]").css({"list-style":"none"})}}}google.load("feeds","1");google.setOnLoadCallback(feedInit);function feedInit(){var A=new google.feeds.Feed(RSSfeed);A.setNumEntries(10);A.load(displayFeed)}function displayFeed(G){var C=$("#parent1");var D=$("#index");if(!G.error){numOfArticles=G.feed.entries.length;D.append('<ul id="indexUL">');var F=$("#indexUL");for(var E=0;E<G.feed.entries.length;E++){var H=G.feed.entries[E];title[E]=(H.title).replace("&#39;","'");bodyText[E]=H.content;urls[E]=H.link;var I=E+1;var J="'gn"+E+"'";var B="parent1-"+I;F.append('<li class="indexList" id="index-'+B+'"><a href="#'+B+'">'+title[E]+"</a></li>");C.append("<li><div class='articleAll' id='gn"+E+"'>"+bodyText[E]+"</div></li>");$('embed[src*="youtube"]').attr("height",266);$('embed[src*="youtube"]').attr("width",335);var A="vds"+E;$("font:nth-child(6)",$("#gn"+E)).attr({size:"+10"});$("font:nth-child(6)",$("#gn"+E)).wrap("<div class='article' id='"+B+"-vds'></div>");bodyText[E]=$("#"+B+"-vds").text()}D.append("</ul>");output()}else{root.appendChild(document.createTextNode("Fetching RSS feed failure"))}};