Ejemplo n.º 1
0
 private void destLines_SelectedIndexChanged(object sender, EventArgs e)
 {
     foreach (LineControl slc in srcLineControls)
     {
         slc.Parent.Controls.Remove(slc);
     }
     srcLineControls.Clear();
     if (destLines.SelectedIndex == -1)
     {
         destLineControl.Line = null;
         dline = null;
     }
     else
     {
         dline = mix.DestinationLines[destLines.SelectedIndex];
         destLineControl.Line             = dline;
         srcLineControlContainer.RowCount = dline.SourceLineCount;
         srcLineControlContainer.RowStyles.Clear();
         int sumHeight = 0;
         for (int i = 0; i < dline.SourceLineCount; i++)
         {
             LineControl slc = new LineControl();
             slc.Line = dline.SourceLines[i];
             srcLineControlContainer.RowStyles.Add(new RowStyle(SizeType.Absolute, slc.PreferredHeight));
             sumHeight += slc.PreferredHeight;
             srcLineControlContainer.Controls.Add(slc, 0, i);
             srcLineControls.Add(slc);
             slc.Dock = DockStyle.Fill;
         }
         srcLineControlContainer.Height = sumHeight;
     }
     UpdateMux();
 }
Ejemplo n.º 2
0
 private void destLines_SelectedIndexChanged(object sender, EventArgs e)
 {
     foreach (LineControl slc in srcLineControls)
     {
         slc.Parent.Controls.Remove(slc);
     }
     srcLineControls.Clear();
     if (destLines.SelectedIndex == -1)
     {
         destLineControl.Line = null;
         dline = null;
     }
     else
     {
         dline = mix.DestinationLines[destLines.SelectedIndex];
         destLineControl.Line = dline;
         srcLineControlContainer.RowCount = dline.SourceLineCount;
         srcLineControlContainer.RowStyles.Clear();
         int sumHeight = 0;
         for (int i = 0; i < dline.SourceLineCount; i++)
         {
             LineControl slc = new LineControl();
             slc.Line = dline.SourceLines[i];
             srcLineControlContainer.RowStyles.Add(new RowStyle(SizeType.Absolute, slc.PreferredHeight));
             sumHeight += slc.PreferredHeight;
             srcLineControlContainer.Controls.Add(slc, 0, i);
             srcLineControls.Add(slc);
             slc.Dock = DockStyle.Fill;
         }
         srcLineControlContainer.Height = sumHeight;
     }
     UpdateMux();
 }
Ejemplo n.º 3
0
 public VolumePanel(LineControl lc, int channel)
 {
     this.lc = lc;
     this.channel = channel;
     this.MouseDown += new MouseEventHandler(VolumePanel_MouseDown);
     this.MouseUp += new MouseEventHandler(VolumePanel_MouseUp);
     this.MouseMove += new MouseEventHandler(VolumePanel_MouseMove);
 }
Ejemplo n.º 4
0
 public VolumePanel(LineControl lc, int channel)
 {
     this.lc         = lc;
     this.channel    = channel;
     this.MouseDown += new MouseEventHandler(VolumePanel_MouseDown);
     this.MouseUp   += new MouseEventHandler(VolumePanel_MouseUp);
     this.MouseMove += new MouseEventHandler(VolumePanel_MouseMove);
 }