Exemplo n.º 1
0
        //private readonly Settings _appSettings;


        /// <summary>
        /// Initializes a new instance of the <see cref="MainForm"/> class.
        /// </summary>
        public MainForm()
        {
            InitializeComponent();
            var settingsProvider = new AppSettingsProvider();

            _applicationState = settingsProvider.LoadSettings <AppSettingsModel>();

            if (_applicationState == null)
            {
                _applicationState = new AppSettingsModel
                {
                    AutoScrollText   = true,
                    BaudRate         = 115200,
                    EnableTimestamps = true,
                    Status           = ConnectionStatus.None
                };
            }
        }