Beispiel #1
0
        private void btnAdd_Click(object sender, EventArgs e)
        {
            SegmentConfig S = new SegmentConfig();

            PCM.Segments.Add(S);
            frmSegmentSettings frmSS = new frmSegmentSettings();

            frmSS.EditSegment(PCM, PCM.Segments.Count - 1);
            if (frmSS.ShowDialog(this) == DialogResult.OK)
            {
                InitMe();
            }
        }
Beispiel #2
0
        private void btnEdit_Click(object sender, EventArgs e)
        {
            if (listSegments.SelectedItems.Count == 0)
            {
                return;
            }
            frmSegmentSettings frmSS = new frmSegmentSettings();
            int CurrentSel           = (int)listSegments.SelectedItems[0].Tag;

            frmSS.EditSegment(PCM, CurrentSel);
            if (frmSS.ShowDialog(this) == DialogResult.OK)
            {
                InitMe();
            }
        }
Beispiel #3
0
        private void btnCopy_Click(object sender, EventArgs e)
        {
            if (listSegments.SelectedItems.Count == 0)
            {
                return;
            }
            int           CurrentSel = (int)listSegments.SelectedItems[0].Tag;
            SegmentConfig S          = PCM.Segments[CurrentSel];

            PCM.Segments.Add(S);
            frmSegmentSettings frmSS = new frmSegmentSettings();

            frmSS.EditSegment(PCM, PCM.Segments.Count - 1);
            if (frmSS.ShowDialog(this) == DialogResult.OK)
            {
                InitMe();
            }
        }