void InitialiseGeneral() { txtOutputFolder.Text = EM_AppContext.Instance.GetUserSettingsAdministrator().Get().OutputFolder; txtInputFolder.Text = EM_AppContext.Instance.GetUserSettingsAdministrator().Get().InputFolder; string closeWithLastMainform = EM_AppContext.Instance.GetUserSettingsAdministrator().Get().CloseInterfaceWithLastMainform; chkCloseWithLastCountry.Checked = closeWithLastMainform == string.Empty || closeWithLastMainform == DefPar.Value.YES; chkStoreViewSettings.Checked = ViewKeeper.GetKeepMode(); }
void btnOK_Click(object sender, EventArgs e) { if (!StoreAutoSave()) { return; } if (!StoreVersionControl()) { return; } StoreWarnings(); StoreGeneral(); EM_AppContext.Instance.GetUserSettingsAdministrator().SaveCurrentSettings(true); ViewKeeper.SetKeepMode(chkStoreViewSettings.Checked); DialogResult = DialogResult.Cancel; Close(); }
internal void StoreViewSettings() { try { _userSettingsAdministrator.Get().ViewSettings = ViewKeeper.GetStoreString(); _userSettingsAdministrator.SaveCurrentSettings(false); } catch { } }
internal void InitViewKeeper() { ViewKeeper.Init(_userSettingsAdministrator.Get().ViewSettings); }