I'm trying to remake my top level menu to only have three items showing: Movies, Youtube, Pandora.
I've got the movies working with the folowing code (based on MediaFolder plugin):
- Code: Select all
var myMovies = new Menu("All Movies","$$All Movies","/osd/image/villa/home_video_main_icon_n.png",
"/osd/image/villa/home_video_main_icon_f.png", true);
myMovies.handler = function(){
Menu.Top["$$Video"]["$$Local Drives"]["$$All Video"].handler()
};
Menu.Top.addChild(myMovies);
Building on the above, I've been able to set it to go to YouTubes Top Rated with the following code:
- Code: Select all
var myYoutube = new Menu("My Youtube","$$YouTube Top Rated","/osd/image/villa/home_video_youtube_sub_icon_n.png",
"/osd/image/villa/home_video_youtube_sub_icon_f.png", true);
myYoutube.handler = function(){
Menu.Top["$$Video"]["$$YouTube"]["$$Top Rated"].handler()
// Menu.Top["$$Video"]["$$YouTube"].handler() //this doesn't work and crashes the osd
};
Menu.Top.addChild(myYoutube);
I would like to have a YouTube Icon on the front screen that when clicked, brought up the YouTube submenu.
And I've tried the following with Pandora, to no good end:
- Code: Select all
var myPandora = new Menu("My Pandora","$$Pandora","/osd/image/villa/home_pandora_icon_n.png",
"/osd/image/villa/home_pandora_icon_f.png", true);
myPandora.handler = function(){
Menu.Top["$$Music"]["$$Pandora"]["$$user@gmail.com"].handler()
};
// myPandora.addChild(Menu.Top["$$Music"]["$$Pandora"]); // This crashes the osd
Menu.Top.addChild(myPandora);
I'm sure I'm just not getting the big picture with how the menus work, but haven't been able to figure it out from previous posts or by looking at code from other plugins.
Thanks for the help,
Travis