public DataForm(GraphControl graph, DataItem item, MainForm mainform) { // // Required for Windows Form Designer support // InitializeComponent(); this.graph = graph; if (item == null) { newitem = true; item = new DataItem(); item.name = "Data" + index++; graph.Model.Items.Add(item); } this.item = item; temp = new DataItem(); temp.model = graph.Model; this.mainform = mainform; loadForm = new LoadDataForm(this, item); mainform.ResetMenu(); lineStyle.DropDownStyle = ComboBoxStyle.DropDownList; for (DashStyle s = DashStyle.Solid; s < DashStyle.Custom; s++) { lineStyle.Items.Add(s.ToString()); } lineStyle.SelectedIndex = 0; }
private void loadClick(object sender, System.EventArgs e) { Apply(); if (loadForm.IsDisposed) { loadForm = new LoadDataForm(this, item); } loadForm.Reset(); loadForm.Show(); loadForm.BringToFront(); }