Пример #1
0
        private void ShowConfigDevicesDialog()
        {
            var cform = new DevicesConfigForm(this, this._devices.ToArray());

            if (cform.ShowConfig() == DialogResult.OK)
            {
                this._devices.Clear();
                this._devices.AddRange(cform.GetDevices());
                this.cbDevice.Items.Clear();
                this.cbDevice.Items.AddRange(this._devices.ToArray());
                if (this.cbDevice.Items.Count > 0)
                {
                    this.cbDevice.SelectedIndex = 0;
                }
            }
        }
Пример #2
0
 private void ShowConfigDevicesDialog()
 {
     var cform = new DevicesConfigForm(this, this._devices.ToArray());
     if (cform.ShowConfig() == DialogResult.OK)
     {
         this._devices.Clear();
         this._devices.AddRange(cform.GetDevices());
         this.cbDevice.Items.Clear();
         this.cbDevice.Items.AddRange(this._devices.ToArray());
         if (this.cbDevice.Items.Count > 0)
             this.cbDevice.SelectedIndex = 0;
     }
 }