Defaults toggleWhitespace.enabled to true

Turns off whitespace toggling if already 'none'
This commit is contained in:
Eric Amodio
2017-06-09 16:31:35 -04:00
parent 9ae4cc36a1
commit badd999db1
3 changed files with 23 additions and 13 deletions

View File

@@ -60,10 +60,11 @@ import { WhitespaceController } from './whitespaceController';
this.whitespaceController && await this.whitespaceController.restore();
}
async reset() {
async reset(whitespaceController: WhitespaceController | undefined) {
await this.clear();
this._config = workspace.getConfiguration().get<IConfig>(ExtensionKey)!;
this.whitespaceController = whitespaceController;
await this.provideAnnotation(this.editor === undefined ? undefined : this.editor.selection.active.line);
}