scm: remove commit method from api

This commit is contained in:
Joao Moreno
2017-01-31 11:25:07 +01:00
parent 28f2fbd05e
commit ced55cc291
6 changed files with 0 additions and 27 deletions

View File

@@ -135,7 +135,6 @@ declare module 'vscode' {
readonly onDidChange: Event<SCMResourceGroup[]>;
getOriginalResource?(uri: Uri, token: CancellationToken): ProviderResult<Uri>;
commit?(message: string, token: CancellationToken): ProviderResult<void>;
open?(resource: SCMResource, token: CancellationToken): ProviderResult<void>;
drag?(resource: SCMResource, resourceGroup: SCMResourceGroup, token: CancellationToken): ProviderResult<void>;
}

View File

@@ -242,7 +242,6 @@ export abstract class MainProcessExtensionServiceShape {
export interface SCMProviderFeatures {
label: string;
supportsCommit: boolean;
supportsOpen: boolean;
supportsDrag: boolean;
supportsOriginalResource: boolean;
@@ -390,7 +389,6 @@ export abstract class ExtHostTerminalServiceShape {
}
export abstract class ExtHostSCMShape {
$commit(id: string, message: string): TPromise<void> { throw ni(); }
$open(id: string, resourceGroupId: string, uri: string): TPromise<void> { throw ni(); }
$drag(id: string, fromResourceGroupId: string, fromUri: string, toResourceGroupId: string): TPromise<void> { throw ni(); }
$getOriginalResource(id: string, uri: URI): TPromise<URI> { throw ni(); }

View File

@@ -113,7 +113,6 @@ export class ExtHostSCM {
this._proxy.$register(providerId, {
label: provider.label,
supportsCommit: !!provider.commit,
supportsOpen: !!provider.open,
supportsDrag: !!provider.drag,
supportsOriginalResource: !!provider.getOriginalResource
@@ -162,16 +161,6 @@ export class ExtHostSCM {
});
}
$commit(providerId: string, message: string): TPromise<void> {
const provider = this._providers[providerId];
if (!provider) {
return TPromise.as(null);
}
return asWinJsPromise(token => provider.commit(message, token));
}
$open(providerId: string, resourceGroupId: string, uri: string): TPromise<void> {
const provider = this._providers[providerId];

View File

@@ -38,14 +38,6 @@ class MainThreadSCMProvider implements ISCMProvider {
this.disposables.push(scmService.registerSCMProvider(this));
}
commit(message: string): TPromise<void> {
if (!this.features.supportsCommit) {
return TPromise.as(null);
}
return this.proxy.$commit(this.id, message);
}
open(resource: ISCMResource): TPromise<void> {
if (!this.features.supportsOpen) {
return TPromise.as(null);

View File

@@ -44,10 +44,6 @@ export class GitSCMProvider implements IWorkbenchContribution, ISCMProvider, ITe
return 'git.contentprovider';
}
commit(message: string): TPromise<void> {
return TPromise.wrapError<void>('not implemented');
}
open(uri: ISCMResource): TPromise<void> {
return TPromise.wrapError<void>('not implemented');
}

View File

@@ -41,7 +41,6 @@ export interface ISCMProvider extends IDisposable {
readonly resources: ISCMResourceGroup[];
readonly onDidChange: Event<ISCMResourceGroup[]>;
commit(message: string): TPromise<void>;
open(uri: ISCMResource): TPromise<void>;
drag(from: ISCMResource, to: ISCMResourceGroup): TPromise<void>;
getOriginalResource(uri: URI): TPromise<URI>;