Fixed other context menus using this context

This commit is contained in:
digeff
2020-10-21 17:05:24 -07:00
parent 580ac9765d
commit bce86a137e
7 changed files with 56 additions and 13 deletions

View File

@@ -14,6 +14,7 @@ import { ILogService } from 'vs/platform/log/common/log';
import { IRawFileQuery, ISearchCompleteStats, IFileQuery, IRawTextQuery, IRawQuery, ITextQuery, IFolderQuery } from 'vs/workbench/services/search/common/search';
import { URI, UriComponents } from 'vs/base/common/uri';
import { TextSearchManager } from 'vs/workbench/services/search/common/textSearchManager';
import { ExtHostCommands } from 'vs/workbench/api/common/extHostCommands';
export interface IExtHostSearch extends ExtHostSearchShape {
registerTextSearchProvider(scheme: string, provider: vscode.TextSearchProvider): IDisposable;
@@ -37,8 +38,21 @@ export class ExtHostSearch implements ExtHostSearchShape {
constructor(
@IExtHostRpcService private extHostRpc: IExtHostRpcService,
@IURITransformerService protected _uriTransformer: IURITransformerService,
@ILogService protected _logService: ILogService
) { }
@ILogService protected _logService: ILogService,
commands: ExtHostCommands,
) {
commands.registerArgumentProcessor({
processArgument: arg => {
if (arg.renderableMatch !== undefined) {
const filteredProperties = { ...arg };
delete filteredProperties.renderableMatch;
return filteredProperties;
} else {
return arg;
}
}
});
}
protected _transformScheme(scheme: string): string {
return this._uriTransformer.transformOutgoingScheme(scheme);