Revert "Revert "Remove typings and replace missing methods with vscodes (#8217)"" (#8242)

* Revert "Revert "Remove typings and replace missing methods with vscodes (#8217)" (#8240)"

This reverts commit e801a04bcf.

* fix runtime error

* add tests for chartview
This commit is contained in:
Anthony Dresser
2019-11-06 15:00:34 -08:00
committed by GitHub
parent df6b6ded33
commit 564f78b6f6
185 changed files with 670 additions and 43395 deletions

View File

@@ -11,7 +11,7 @@ import { IConfigurationService, IConfigurationChangeEvent } from 'vs/platform/co
import { dispose, Disposable, DisposableStore } from 'vs/base/common/lifecycle';
import { Registry } from 'vs/platform/registry/common/platform';
import { ResourceMap } from 'vs/base/common/map';
import { coalesce } from 'vs/base/common/arrays';
import { coalesce, firstIndex } from 'vs/base/common/arrays';
// {{SQL CARBON EDIT}}
import { QueryInput } from 'sql/workbench/parts/query/common/queryInput';
@@ -740,7 +740,7 @@ export class EditorGroup extends Disposable {
if (editor instanceof QueryInput && editor.matchInputInstanceType(FileEditorInput) && !editor.isDirty() && await editor.inputFileExists() === false && this.editors.length > 1) {
// remove from editors list so that they do not get restored
this.editors.splice(n, 1);
let index = this.mru.findIndex(e => e.matches(editor));
let index = firstIndex(this.mru, e => e.matches(editor));
// remove from MRU list otherwise later if we try to close them it leaves a sticky active editor with no data
this.mru.splice(index, 1);