예제 #1
0
        private void btnTGIEditor_Click(object sender, EventArgs e)
        {
            CountedTGIBlockList tgiBlocksCopy = new CountedTGIBlockList(null, vpxy.TGIBlocks);
            DialogResult        dr            = TGIBlockListEditor.Show(tgiBlocksCopy);

            if (dr != DialogResult.OK)
            {
                return;
            }
            vpxy.TGIBlocks.Clear();
            vpxy.TGIBlocks.AddRange(tgiBlocksCopy.ToArray());
        }
예제 #2
0
        private void btnTGIBlockListEditor_Click(object sender, EventArgs e)
        {
            CountedTGIBlockList tgiBlocksCopy = new CountedTGIBlockList(null, tgiBlocks);
            DialogResult dr = TGIBlockListEditor.Show(tgiBlocksCopy);
            if (dr != DialogResult.OK) return;

            TGIBlock tgib = tgiBlocks == null ? null : cbTGIBlocks.SelectedIndex >= 0 && cbTGIBlocks.SelectedIndex < tgiBlocks.Count ? tgiBlocks[cbTGIBlocks.SelectedIndex] : null;
            string selectedItem = tgib == null ? "(null)" : MakeItem(tgib);
            tgiBlocks.Clear();
            tgiBlocks.AddRange(tgiBlocksCopy.ToArray());

            FillList(selectedItem);

            OnTGIBlockListChanged(this, EventArgs.Empty);
        }
예제 #3
0
        private void btnTGIBlockListEditor_Click(object sender, EventArgs e)
        {
            CountedTGIBlockList tgiBlocksCopy = new CountedTGIBlockList(null, tgiBlocks);
            DialogResult dr = TGIBlockListEditor.Show(tgiBlocksCopy);
            if (dr != DialogResult.OK) return;

            TGIBlock tgib = tgiBlocks == null ? null : cbTGIBlocks.SelectedIndex >= 0 && cbTGIBlocks.SelectedIndex < tgiBlocks.Count ? tgiBlocks[cbTGIBlocks.SelectedIndex] : null;
            string selectedItem = tgib == null ? "(null)" : MakeItem(tgib);
            tgiBlocks.Clear();
            tgiBlocks.AddRange(tgiBlocksCopy.ToArray());

            FillList(selectedItem);

            OnTGIBlockListChanged(this, EventArgs.Empty);
        }
예제 #4
0
 private void btnTGIEditor_Click(object sender, EventArgs e)
 {
     CountedTGIBlockList tgiBlocksCopy = new CountedTGIBlockList(null, vpxy.TGIBlocks);
     DialogResult dr = TGIBlockListEditor.Show(tgiBlocksCopy);
     if (dr != DialogResult.OK) return;
     vpxy.TGIBlocks.Clear();
     vpxy.TGIBlocks.AddRange(tgiBlocksCopy.ToArray());
 }