Exemplo n.º 1
0
 public void Dispose()
 {
     form.Controls.Remove(list_box);
     if (child_folder != null)
     {
         child_folder.Dispose();
         child_folder = null;
     }
     if (child_file != null)
     {
         child_file.Dispose();
         child_file = null;
     }
 }
Exemplo n.º 2
0
        public GUI_node_folder(Form in_form, string in_path, Point in_loc)
        {
            form     = in_form;
            path     = in_path;
            location = in_loc;

            if (Is_folder_there(path))
            {
                list_box          = new ListBox();
                list_box.Location = location;
                string[] folders = ExtractFolders(path);

                foreach (string folder in folders)
                {
                    list_box.Items.Add(folder);
                }
                list_box.SelectedIndexChanged += new EventHandler(list_box_index_change);
                form.Controls.Add(list_box);
            }
            if (Is_json_there(path))
            {
                child_file = new GUI_node_file(form, path, new Point(location.X, location.Y + 130));
            }
        }