by trixmoto » Mon Jan 13, 2014 7:42 am
My "Randomise Playlist" script adds an item to the tree's context menu, and uses a it's own "ShowMenu" function to determine whether or not it should be visible...
Code: Select all
Set itm = SDB.UI.AddMenuItem(SDB.UI.Menu_Pop_Tree,1,0)
itm.Caption = "Randomise Playlist"
itm.OnClickFunc = "ItmClick"
itm.UseScript = Script.ScriptPath
itm.IconIndex = 25
itm.Visible = False
Set SDB.Objects("RandomisePlaylistMenu") = itm
Call Script.RegisterEvent(SDB,"OnChangedSelection","ShowMenu")
My "Randomise Playlist" script adds an item to the tree's context menu, and uses a it's own "ShowMenu" function to determine whether or not it should be visible...
[code] Set itm = SDB.UI.AddMenuItem(SDB.UI.Menu_Pop_Tree,1,0)
itm.Caption = "Randomise Playlist"
itm.OnClickFunc = "ItmClick"
itm.UseScript = Script.ScriptPath
itm.IconIndex = 25
itm.Visible = False
Set SDB.Objects("RandomisePlaylistMenu") = itm
Call Script.RegisterEvent(SDB,"OnChangedSelection","ShowMenu")[/code]