From 5c948589f4466f4377e66fea3f75f83d66ffe31f Mon Sep 17 00:00:00 2001 From: Johannes Rieken Date: Wed, 12 Dec 2018 17:00:14 +0100 Subject: [PATCH] debt - more no tpromise in monaco.d.ts #53526 --- build/monaco/monaco.d.ts.recipe | 3 +-- .../common/standalone/standaloneBase.ts | 2 -- src/vs/editor/editor.api.ts | 1 - src/vs/monaco.d.ts | 25 +------------------ 4 files changed, 2 insertions(+), 29 deletions(-) diff --git a/build/monaco/monaco.d.ts.recipe b/build/monaco/monaco.d.ts.recipe index 356ef3ff04689..71df853a678d0 100644 --- a/build/monaco/monaco.d.ts.recipe +++ b/build/monaco/monaco.d.ts.recipe @@ -26,7 +26,6 @@ declare namespace monaco { } #include(vs/platform/markers/common/markers): MarkerTag, MarkerSeverity -#include(vs/base/common/winjs.base.d.ts): Promise #include(vs/base/common/cancellation): CancellationTokenSource, CancellationToken #include(vs/base/common/uri): URI, UriComponents #include(vs/base/common/keyCodes): KeyCode @@ -86,4 +85,4 @@ declare namespace monaco.worker { } -//dtsv=2 \ No newline at end of file +//dtsv=2 diff --git a/src/vs/editor/common/standalone/standaloneBase.ts b/src/vs/editor/common/standalone/standaloneBase.ts index 2233abd72a619..2239e8d0234a2 100644 --- a/src/vs/editor/common/standalone/standaloneBase.ts +++ b/src/vs/editor/common/standalone/standaloneBase.ts @@ -7,7 +7,6 @@ import { CancellationTokenSource } from 'vs/base/common/cancellation'; import { Emitter } from 'vs/base/common/event'; import { KeyChord, KeyMod as ConstKeyMod } from 'vs/base/common/keyCodes'; import { URI } from 'vs/base/common/uri'; -import { TPromise } from 'vs/base/common/winjs.base'; import { Position } from 'vs/editor/common/core/position'; import { Range } from 'vs/editor/common/core/range'; import { Selection } from 'vs/editor/common/core/selection'; @@ -39,7 +38,6 @@ export function createMonacoBaseAPI(): typeof monaco { SelectionDirection: standaloneEnums.SelectionDirection, MarkerSeverity: standaloneEnums.MarkerSeverity, MarkerTag: standaloneEnums.MarkerTag, - Promise: TPromise, Uri: URI, Token: Token }; diff --git a/src/vs/editor/editor.api.ts b/src/vs/editor/editor.api.ts index 4b91fda4d4588..5da1ffc609fbe 100644 --- a/src/vs/editor/editor.api.ts +++ b/src/vs/editor/editor.api.ts @@ -35,7 +35,6 @@ export const Selection = api.Selection; export const SelectionDirection = api.SelectionDirection; export const MarkerSeverity = api.MarkerSeverity; export const MarkerTag = api.MarkerTag; -export const Promise = api.Promise; export const Uri = api.Uri; export const Token = api.Token; export const editor = api.editor; diff --git a/src/vs/monaco.d.ts b/src/vs/monaco.d.ts index 086d5a9c0ed98..15bb107fb172d 100644 --- a/src/vs/monaco.d.ts +++ b/src/vs/monaco.d.ts @@ -37,29 +37,6 @@ declare namespace monaco { Error = 8 } - - export class Promise { - constructor(executor: (resolve: (value: T | PromiseLike) => void, reject: (reason: any) => void) => void); - - public then( - onfulfilled?: ((value: T) => TResult1 | PromiseLike) | null, - onrejected?: ((reason: any) => TResult2 | PromiseLike) | null): Promise; - - - public static as(value: null): Promise; - public static as(value: undefined): Promise; - public static as(value: PromiseLike): PromiseLike; - public static as>(value: SomePromise): SomePromise; - public static as(value: T): Promise; - - public static join(promises: [T1 | PromiseLike, T2 | PromiseLike]): Promise<[T1, T2]>; - public static join(promises: (T | PromiseLike)[]): Promise; - - public static wrap(value: T | PromiseLike): Promise; - - public static wrapError(error: Error): Promise; - } - export class CancellationTokenSource { readonly token: CancellationToken; cancel(): void; @@ -5568,4 +5545,4 @@ declare namespace monaco.worker { } -//dtsv=2 \ No newline at end of file +//dtsv=2