Merge from vscode 64980ea1f3f532c82bb6c28d27bba9ef2c5b4463 (#7206)

* Merge from vscode 64980ea1f3f532c82bb6c28d27bba9ef2c5b4463

* fix config changes

* fix strictnull checks
This commit is contained in:
Anthony Dresser
2019-09-15 22:38:26 -07:00
committed by GitHub
parent fa6c52699e
commit ea0f9e6ce9
1226 changed files with 21541 additions and 17633 deletions

View File

@@ -22,6 +22,7 @@ import { KeybindingWeight } from 'vs/platform/keybinding/common/keybindingsRegis
import { registerColor } from 'vs/platform/theme/common/colorRegistry';
import { registerThemingParticipant, themeColorFromId } from 'vs/platform/theme/common/themeService';
import { MenuRegistry, MenuId } from 'vs/platform/actions/common/actions';
import { EditorOption } from 'vs/editor/common/config/editorOptions';
const overviewRulerBracketMatchForeground = registerColor('editorOverviewRuler.bracketMatchForeground', { dark: '#A0A0A0', light: '#A0A0A0', hc: '#A0A0A0' }, nls.localize('overviewRulerBracketMatchForeground', 'Overview ruler marker color for matching brackets.'));
@@ -104,7 +105,7 @@ export class BracketMatchingController extends Disposable implements editorCommo
this._lastVersionId = 0;
this._decorations = [];
this._updateBracketsSoon = this._register(new RunOnceScheduler(() => this._updateBrackets(), 50));
this._matchBrackets = this._editor.getConfiguration().contribInfo.matchBrackets;
this._matchBrackets = this._editor.getOption(EditorOption.matchBrackets);
this._updateBracketsSoon.schedule();
this._register(editor.onDidChangeCursorPosition((e) => {
@@ -130,7 +131,7 @@ export class BracketMatchingController extends Disposable implements editorCommo
this._updateBracketsSoon.schedule();
}));
this._register(editor.onDidChangeConfiguration((e) => {
this._matchBrackets = this._editor.getConfiguration().contribInfo.matchBrackets;
this._matchBrackets = this._editor.getOption(EditorOption.matchBrackets);
if (!this._matchBrackets && this._decorations.length > 0) {
// Remove existing decorations if bracket matching is off
this._decorations = this._editor.deltaDecorations(this._decorations, []);
@@ -332,4 +333,4 @@ MenuRegistry.appendMenuItem(MenuId.MenubarGoMenu, {
title: nls.localize({ key: 'miGoToBracket', comment: ['&& denotes a mnemonic'] }, "Go to &&Bracket")
},
order: 2
});
});