Exemple #1
0
        private void AddProtocolUserControl(Protocol NewProtocol)
        {
            ProtocolUserControl P = new ProtocolUserControl(NewProtocol);

            this.ProtocolPanel.Controls.Add(P);
            RefreshProtocolUserControls();
        }
Exemple #2
0
        public void RefreshProtocolUserControls()
        {
            int ProtocolsCount  = 0;
            int RuningProtocols = 0;

            foreach (Control UC in ProtocolPanel.Controls)
            {
                ProtocolUserControl PUC = (ProtocolUserControl)UC;
                if (PUC.Visible)
                {
                    ProtocolsCount++;
                    if (PUC.ProtocolStatus != Protocol.Statuses.Stopped && PUC.ProtocolStatus != Protocol.Statuses.EndedSuccessfully)
                    {
                        RuningProtocols++;
                    }
                }
            }

            for (int i = 1; i < ProtocolPanel.Controls.Count; i++)
            {
                Control LastProtocolUserControl = ProtocolPanel.Controls[i - 1];
                ProtocolPanel.Controls[i].Location = new Point(LastProtocolUserControl.Left, LastProtocolUserControl.Bottom);
            }


            ProtocolsCountToolStripStatusLabel.Text  = string.Format("Active Protocols: {0:0}", ProtocolsCount);
            RuningProtocolsToolStripStatusLabel.Text = string.Format("Runing Protocols: {0:0}", RuningProtocols);
        }
 public ProtocolParametersForm(ProtocolUserControl ParentProtocolUserControl,ProtocolParameters ProtocolParameters)
     : this()
 {
     this.ParentProtocolUserControl = ParentProtocolUserControl;
     this.FormProtocolParameters = ProtocolParameters;
     ProtocolParametersFields = ProtocolProvider.GetProtocolParametersFields(FormProtocolParameters);
 }
Exemple #4
0
 private void AddProtocolUserControl(Protocol NewProtocol)
 {
     ProtocolUserControl P = new ProtocolUserControl(NewProtocol);
     this.ProtocolPanel.Controls.Add(P);
     RefreshProtocolUserControls();
 }
 public ProtocolParametersForm(ProtocolUserControl ParentProtocolUserControl,Type ProtocolData)
     : this(ParentProtocolUserControl,ProtocolProvider.GetProtocolParameters(ProtocolData))
 {
 }
Exemple #6
0
 public ProtocolParametersForm(ProtocolUserControl ParentProtocolUserControl, ProtocolParameters ProtocolParameters) : this()
 {
     this.ParentProtocolUserControl = ParentProtocolUserControl;
     this.FormProtocolParameters    = ProtocolParameters;
     ProtocolParametersFields       = ProtocolProvider.GetProtocolParametersFields(FormProtocolParameters);
 }
Exemple #7
0
 public ProtocolParametersForm(ProtocolUserControl ParentProtocolUserControl, Type ProtocolData) : this(ParentProtocolUserControl, ProtocolProvider.GetProtocolParameters(ProtocolData))
 {
 }