bool IPreferencesService.GetPreferencesStore(Type storeOwnerType, out PreferencesStore preferencesStore) { if (storeOwnerType == null) { throw new ArgumentNullException(); } string fullName = storeOwnerType.FullName; PreferencesStore store = (PreferencesStore) this._stores[fullName]; preferencesStore = store; return (store != null); }
PreferencesStore IPreferencesService.GetPreferencesStore(Type storeOwnerType) { if (storeOwnerType == null) { throw new ArgumentNullException(); } string fullName = storeOwnerType.FullName; PreferencesStore store = (PreferencesStore) this._stores[fullName]; if (store == null) { store = new PreferencesStore(); this._stores[fullName] = store; } return store; }
public virtual void Save(PreferencesStore prefStore) { if (prefStore == null) { throw new ArgumentNullException("prefStore"); } prefStore.SetValue("ConvertTabsToSpaces", this.ConvertTabsToSpaces, true); prefStore.SetValue("ShowWhitespace", this.ShowWhitespace, false); prefStore.SetValue("ShowLineNumbers", this.ShowLineNumbers, false); prefStore.SetValue("TabSize", this.TabSize, 4); prefStore.SetValue("TrimTrailingWhitespace", this.TrimTrailingWhitespace, true); }