Esempio n. 1
0
        private void add_Click(object sender, EventArgs e)
        {
            var dlg = new AddFolderDialog();

            if (dlg.ShowDialog(this) == DialogResult.OK)
            {
                var it = new FileExplorerConfig.FavoriteFolder
                {
                    Directory = dlg.Path,
                    Name      = dlg.FolderName,
                    Mask      = dlg.Mask
                };
                dirList.Items.Add(it);
                PopulateDirs();
            }
        }
Esempio n. 2
0
        private void add_Click(object sender, EventArgs e)
        {
            var dlg = new AddFolderDialog();

            if (dlg.ShowDialog(this) == DialogResult.OK)
            {
                var it = new FileExplorerConfig.FavoriteFolder
                {
                    Directory = dlg.Path,
                    Name = dlg.FolderName,
                    Mask = dlg.Mask
                };
                dirList.Items.Add(it);
                PopulateDirs();
            }
        }
Esempio n. 3
0
        private void edit_Click(object sender, EventArgs e)
        {
            var selItem = (FileExplorerConfig.FavoriteFolder)dirList.SelectedItem;

            var dlg = new AddFolderDialog
            {
                Path       = selItem.Directory,
                FolderName = selItem.Name,
                Mask       = selItem.Mask
            };

            if (dlg.ShowDialog(this) == DialogResult.OK)
            {
                selItem.Directory = dlg.Path;
                selItem.Name      = dlg.FolderName;
                selItem.Mask      = dlg.Mask;
                PopulateDirs();
            }
        }
Esempio n. 4
0
        private void ShowProperties()
        {
            if (treeView.SelectedNode != null)
            {
                var n = treeView.SelectedNode;
                var ff = n.Tag as FileExplorerConfig.FavoriteFolder;

                if (ff != null)
                {
                    var dlg = new AddFolderDialog
                    {
                        Path = ff.Directory,
                        FolderName = ff.Name,
                        Mask = ff.Mask
                    };

                    if (dlg.ShowDialog(WB.Form) == DialogResult.OK)
                    {
                        ff.Directory = dlg.Path;
                        ff.Name = dlg.FolderName;
                        ff.Mask = dlg.Mask;
                        treeView.RefreshNode(n);
                        n.Text = ff.Name;
                    }
                }
            }
        }
Esempio n. 5
0
        private void edit_Click(object sender, EventArgs e)
        {
            var selItem = (FileExplorerConfig.FavoriteFolder)dirList.SelectedItem;

            var dlg = new AddFolderDialog
            {
                Path = selItem.Directory,
                FolderName = selItem.Name,
                Mask = selItem.Mask
            };

            if (dlg.ShowDialog(this) == DialogResult.OK)
            {
                selItem.Directory = dlg.Path;
                selItem.Name = dlg.FolderName;
                selItem.Mask = dlg.Mask;
                PopulateDirs();
            }
        }