Initial Code Layering (#3788)

* working on formatting

* fixed basic lint errors; starting moving things to their appropriate location

* formatting

* update tslint to match the version of vscode we have

* remove unused code

* work in progress fixing layering

* formatting

* moved connection management service to platform

* formatting

* add missing file

* moving more servies

* formatting

* moving more services

* formatting

* wip

* moving more services

* formatting

* revert back tslint rules

* move css file

* add missing svgs
This commit is contained in:
Anthony Dresser
2019-01-25 14:52:35 -08:00
committed by GitHub
parent c8986464ec
commit ea67859de7
338 changed files with 2036 additions and 7386 deletions

View File

@@ -14,7 +14,7 @@ import URI from 'vs/base/common/uri';
import { IContextKeyService, ContextKeyExpr } from 'vs/platform/contextkey/common/contextkey';
import * as resources from 'vs/base/common/resources';
import { INotebookService, INotebookEditor } from 'sql/services/notebook/notebookService';
import { INotebookService, INotebookEditor } from 'sql/workbench/services/notebook/common/notebookService';
import { IDialogService } from 'vs/platform/dialogs/common/dialogs';
import Severity from 'vs/base/common/severity';
@@ -80,7 +80,7 @@ export class NotebookInputModel extends EditorModel {
export class NotebookInputValidator {
constructor(@IContextKeyService private readonly _contextKeyService: IContextKeyService) {}
constructor( @IContextKeyService private readonly _contextKeyService: IContextKeyService) { }
public isNotebookEnabled(): boolean {
return this._contextKeyService.contextMatchesRules(notebooksEnabledCondition);
@@ -202,14 +202,12 @@ export class NotebookInput extends EditorInput {
save(): TPromise<boolean> {
let activeEditor: INotebookEditor;
for (const editor of this.notebookService.listNotebookEditors()) {
if(editor.isActive())
{
if (editor.isActive()) {
activeEditor = editor;
}
}
if(activeEditor)
{
return TPromise.wrap(activeEditor.save().then((val) => {return val;}));
if (activeEditor) {
return TPromise.wrap(activeEditor.save().then((val) => { return val; }));
}
return TPromise.wrap(false);
}