| | |
| | | using System; |
| | | using HMI.Base; |
| | | using HMI.Core.Api; |
| | | using HMI.Core.Util; |
| | | using HMI.UI.Util; |
| | | using System; |
| | | using System.Collections.ObjectModel; |
| | | using System.ComponentModel; |
| | | using System.Runtime.CompilerServices; |
| | | using System.Windows; |
| | | using System.Windows.Controls; |
| | | using HMI.Base; |
| | | using HMI.Core.Api; |
| | | using HMI.UI.Util; |
| | | using log4net; |
| | | |
| | | namespace HMI.SettingControl |
| | | { |
| | |
| | | Content = d.SettingControl |
| | | }); |
| | | } |
| | | tabControl.SelectedIndex = 0; |
| | | Loaded -= UserControl_Loaded; |
| | | } |
| | | |
| | |
| | | try |
| | | { |
| | | manager.SaveConfig(); |
| | | this.Success(this.lang("App.SaveSuccess")); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | MsgBoxHelper.Error(this, $"保存{tabItem.Header}配置失败!{ex.Message}"); |
| | | MsgBoxHelper.Error(this, $"{tabItem.Header}{this.lang("App.SaveFailed")}: {ex.Message}"); |
| | | } |
| | | } |
| | | } |
| | | this.Success("保存成功"); |
| | | } |
| | | |
| | | private void SaveCurrentConfig() |
| | |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | MsgBoxHelper.Error(this, $"保存配置失败!{ex.Message}"); |
| | | MsgBoxHelper.Error(this, $"{this.lang("App.SaveFailed")}: {ex.Message}"); |
| | | } |
| | | } |
| | | } |
| | |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | MsgBoxHelper.Error(this, $"保存配置失败!{ex.Message}"); |
| | | MsgBoxHelper.Error(this, $"{this.lang("App.SaveFailed")}: {ex.Message}"); |
| | | } |
| | | } |
| | | } |