public void ContextMenu(Point cursorPositionInDesktop, ContextMenuEnum menuEnumPosition) { var cmdList = new List <ImpTextAndCommand>(); switch (menuEnumPosition) { case ContextMenuEnum.None: cmdList.Add(new ImpTextAndCommand("Play Next", ImpCommand.OpenNext)); cmdList.Add(new ImpTextAndCommand("Play Previous", ImpCommand.OpenPrev)); cmdList.Add(new ImpTextAndCommand("Play Random", ImpCommand.OpenRandom)); cmdList.Add(new ImpTextAndCommand("Copy to clipboard", ImpCommand.CopyName)); cmdList.Add(new ImpTextAndCommand("Shuffle playlist", ImpCommand.Shuffle)); break; case ContextMenuEnum.Playlist: cmdList.Add(new ImpTextAndCommand("Play this", ImpCommand.OpenPlaylst)); cmdList.Add(new ImpTextAndCommand("Remove selected", ImpCommand.RemoveSelected)); cmdList.Add(new ImpTextAndCommand("Sort files", ImpCommand.Sort)); cmdList.Add(new ImpTextAndCommand("Sort files by dates", ImpCommand.Sort, () => FileSortMode.Date)); cmdList.Add(new ImpTextAndCommand("Sort files by paths", ImpCommand.Sort, () => FileSortMode.Path)); cmdList.Add(new ImpTextAndCommand("Randomize file order", ImpCommand.Sort, () => FileSortMode.Random)); cmdList.Add(new ImpTextAndCommand("------------", ImpCommand.None)); cmdList.Add(new ImpTextAndCommand("Mark as watched", ImpCommand.MarkAsWatched, GetPlaylistItems)); cmdList.Add(new ImpTextAndCommand("Remove watched", ImpCommand.RemoveWatched, GetPlaylistItems)); cmdList.Add(new ImpTextAndCommand("------------", ImpCommand.None)); cmdList.Add(new ImpTextAndCommand("Open path in file browser", ImpCommand.ShowInExplorer)); cmdList.Add(new ImpTextAndCommand("Delete Selected Files", ImpCommand.DeletePlFiles)); break; case ContextMenuEnum.FileList: cmdList.Add(new ImpTextAndCommand("Play selected files", ImpCommand.PlaySelectedOpenFiles)); cmdList.Add(new ImpTextAndCommand("Add selected files", ImpCommand.AddSelectedOpenFiles)); cmdList.Add(new ImpTextAndCommand("------------", ImpCommand.None)); cmdList.Add(new ImpTextAndCommand("Mark as watched", ImpCommand.MarkAsWatched, GetFilelistItems)); cmdList.Add(new ImpTextAndCommand("Remove watched", ImpCommand.RemoveWatched, GetFilelistItems)); cmdList.Add(new ImpTextAndCommand("------------", ImpCommand.None)); cmdList.Add(new ImpTextAndCommand("Delete Selected Files", ImpCommand.DeleteOpenFiles)); break; case ContextMenuEnum.FolderList: cmdList.Add(new ImpTextAndCommand("Play Folder", ImpCommand.PlaySelectedFolderFiles)); cmdList.Add(new ImpTextAndCommand("Add files inside folder", ImpCommand.AddSelectedFolderFiles)); cmdList.Add(new ImpTextAndCommand("Add files and folders in folder", ImpCommand.AddSelectedFolderFolders)); cmdList.Add(new ImpTextAndCommand("------------", ImpCommand.None)); cmdList.Add(new ImpTextAndCommand("Remember selected folder", ImpCommand.AddSelectedFolderToPaths)); //cmdList.Add(new ImpTextAndCommand("Delete Selected Folder (NYI)", ImpCommand.DeleteOpenFolder)); break; case ContextMenuEnum.PlacesList: cmdList.Add(new ImpTextAndCommand("Play Folder", ImpCommand.PlaySelectedFolderFiles)); cmdList.Add(new ImpTextAndCommand("Add files inside folder", ImpCommand.AddSelectedFolderFiles)); cmdList.Add(new ImpTextAndCommand("Add files and folders in folder", ImpCommand.AddSelectedFolderFolders)); cmdList.Add(new ImpTextAndCommand("------------", ImpCommand.None)); cmdList.Add(new ImpTextAndCommand("Remove selected path", ImpCommand.RemoveSelectedPath)); break; default: throw new ArgumentOutOfRangeException("menuEnumPosition"); } CreateContextMenu(cursorPositionInDesktop, cmdList); }
public void ContextMenu(Point cursorPositionInDesktop, ContextMenuEnum menuPosition) { throw new NotImplementedException(); }