Exemple #1
0
        private void contextMenuStrip1_ItemClicked(object sender, ToolStripItemClickedEventArgs e)
        {
            var ai                = e.ClickedItem;
            var menuAction        = ai.Tag.ToString();
            var mclickedMusicItem = (MusicItem)(GetCurrentGrid()).CurrentRow.DataBoundItem;

            if (menuAction == "usb")
            {
                DbController.AddToUsbList(mclickedMusicItem);
            }
            if (menuAction == "plst")
            {
                DbController.AddToPlayList(mclickedMusicItem);
            }
            if (menuAction == "dir")
            {
                var dir = Path.GetDirectoryName(mclickedMusicItem.FullFileName);
                DirectoryHandler.OpenContaingFolder(dir);
                return;
            }
            //DbController.Update(mclickedMusicItem);

            currentIndex = null;
            RefreshGrid();
        }