public void DragDrop(DragEventArgs e)
        {
            var fileNames = e.Data.GetData("FileNameW") as string[];

            if (fileNames == null || fileNames.Length == 0)
                return;

            var profile = new SelectProfile();

            if (profile.ShowDialog(_view) == DialogResult.OK)
            {
                AddFileNameToList(fileNames[0], profile.SelectedProfile);
            }
        }
Пример #2
0
        public void ChangeProfile(MouseEventArgs e)
        {
            if ((e.Button & MouseButtons.Right) == MouseButtons.Right)
            {
                var selectedItem = _view.GetSelectedItems().FirstOrDefault();

                if (selectedItem == null)
                    return;

                var dlg = new SelectProfile();

                if (dlg.ShowDialog(_view) == DialogResult.OK)
                {
                    _view.SetListViewItem(selectedItem, Columns.Profile, dlg.SelectedProfile);
                }
            }
        }