mirror of
https://github.com/ckaczor/azuredatastudio.git
synced 2026-01-14 09:59:47 -05:00
Task contribution (#742)
* work in progress * set up necessary code. need to work on getting it working * formatting * work in progress * work in progress * formatting * work in progress * work in progress * work in progress * formatting * needs a lot of work regarding how we do actions vs how extensions do actions * formatting * use connection profile for actions * change action to be
This commit is contained in:
@@ -9,11 +9,12 @@ import {
|
||||
createExtHostContextProxyIdentifier as createExtId,
|
||||
ProxyIdentifier
|
||||
} from 'vs/workbench/services/thread/common/threadService';
|
||||
import { TPromise } from 'vs/base/common/winjs.base';
|
||||
import { IDisposable } from 'vs/base/common/lifecycle';
|
||||
|
||||
import * as sqlops from 'sqlops';
|
||||
|
||||
import { TPromise } from 'vs/base/common/winjs.base';
|
||||
import { IDisposable } from 'vs/base/common/lifecycle';
|
||||
import { ITaskHandlerDescription } from 'sql/platform/tasks/common/tasks';
|
||||
|
||||
export abstract class ExtHostAccountManagementShape {
|
||||
$autoOAuthCancelled(handle: number): Thenable<void> { throw ni(); }
|
||||
@@ -421,6 +422,7 @@ export const SqlMainContext = {
|
||||
MainThreadSerializationProvider: createMainId<MainThreadSerializationProviderShape>('MainThreadSerializationProvider'),
|
||||
MainThreadResourceProvider: createMainId<MainThreadResourceProviderShape>('MainThreadResourceProvider'),
|
||||
MainThreadModalDialog: createMainId<MainThreadModalDialogShape>('MainThreadModalDialog'),
|
||||
MainThreadTasks: createMainId<MainThreadTasksShape>('MainThreadTasks'),
|
||||
MainThreadDashboardWebview: createMainId<MainThreadDashboardWebviewShape>('MainThreadDashboardWebview')
|
||||
};
|
||||
|
||||
@@ -432,6 +434,7 @@ export const SqlExtHostContext = {
|
||||
ExtHostSerializationProvider: createExtId<ExtHostSerializationProviderShape>('ExtHostSerializationProvider'),
|
||||
ExtHostResourceProvider: createExtId<ExtHostResourceProviderShape>('ExtHostResourceProvider'),
|
||||
ExtHostModalDialogs: createExtId<ExtHostModalDialogsShape>('ExtHostModalDialogs'),
|
||||
ExtHostTasks: createExtId<ExtHostTasksShape>('ExtHostTasks'),
|
||||
ExtHostDashboardWebviews: createExtId<ExtHostDashboardWebviewsShape>('ExtHostDashboardWebviews')
|
||||
};
|
||||
|
||||
@@ -449,6 +452,16 @@ export interface ExtHostModalDialogsShape {
|
||||
$onClosed(handle: number): void;
|
||||
}
|
||||
|
||||
export interface ExtHostTasksShape {
|
||||
$executeContributedTask<T>(id: string, ...args: any[]): Thenable<T>;
|
||||
$getContributedTaskHandlerDescriptions(): TPromise<{ [id: string]: string | ITaskHandlerDescription }>;
|
||||
}
|
||||
|
||||
export interface MainThreadTasksShape extends IDisposable {
|
||||
$registerTask(id: string): TPromise<any>;
|
||||
$unregisterTask(id: string): TPromise<any>;
|
||||
}
|
||||
|
||||
export interface ExtHostDashboardWebviewsShape {
|
||||
$registerProvider(widgetId: string, handler: (webview: sqlops.DashboardWebview) => void): void;
|
||||
$onMessage(handle: number, message: any): void;
|
||||
|
||||
Reference in New Issue
Block a user