/// <summary> /// /// </summary> void ShowPortSettings() { var form = new SPSettingsForm(); form.Owner = this; form.IsShowAvailablePorts = App.CurrentConfig.IsShowAvailablePorts; if (form.ShowModal(this.isHub.ComPort.Port)) { //this.port = form.SerialPort; this.isHub.ComPort.SetPortSettings(form.SP); Log.Add("Параметры COM-порта изменены"); App.CurrentConfig.IsShowAvailablePorts = form.IsShowAvailablePorts; } }
/// <summary> /// /// </summary> void ShowPortSettings() { var form = new SPSettingsForm(); form.Owner = this; if (form.ShowModal(this.spConnection.Port)) { //this.port = form.SerialPort; this.spConnection.SetPortSettings(form.SP); Log.Add("Параметры COM-порта успешно изменены"); } }
void System.Windows.Markup.IComponentConnector.Connect(int connectionId, object target) { switch (connectionId) { case 1: this._this = ((SPLib.SPSettingsForm)(target)); return; case 2: #line 31 "..\..\SPSettingsForm.xaml" ((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.CommandBinding_Executed); #line default #line hidden return; case 3: #line 32 "..\..\SPSettingsForm.xaml" ((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.CommandBinding_Executed); #line default #line hidden return; case 4: #line 33 "..\..\SPSettingsForm.xaml" ((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.CommandBinding_Executed); #line default #line hidden return; case 5: #line 34 "..\..\SPSettingsForm.xaml" ((System.Windows.Input.CommandBinding)(target)).Executed += new System.Windows.Input.ExecutedRoutedEventHandler(this.CommandBinding_Executed); #line default #line hidden return; case 6: this.gMain = ((System.Windows.Controls.Grid)(target)); return; case 7: this.cbPort = ((System.Windows.Controls.ComboBox)(target)); return; case 8: this.cbBaudRate = ((System.Windows.Controls.ComboBox)(target)); return; case 9: this.cbDataBits = ((System.Windows.Controls.ComboBox)(target)); return; case 10: this.cbParity = ((System.Windows.Controls.ComboBox)(target)); return; case 11: this.cbStopBits = ((System.Windows.Controls.ComboBox)(target)); return; case 12: this.tbReadTimeout = ((Xceed.Wpf.Toolkit.IntegerUpDown)(target)); return; case 13: this.tbWriteTimeout = ((Xceed.Wpf.Toolkit.IntegerUpDown)(target)); return; case 14: this.cbIsAvailablePorts = ((System.Windows.Controls.CheckBox)(target)); return; case 15: this.bApply = ((System.Windows.Controls.Button)(target)); return; case 16: this.bCancel = ((System.Windows.Controls.Button)(target)); return; case 17: this.bTest = ((System.Windows.Controls.Button)(target)); return; case 18: this.pbCircular = ((SPLib.CircularProgressBar)(target)); return; } this._contentLoaded = true; }