mirror of
https://github.com/microsoft/vscode.git
synced 2026-04-30 13:31:07 +01:00
Reduce usage of extensionFolderPath
This commit is contained in:
@@ -14,7 +14,6 @@ import { IDialogService } from 'vs/platform/dialogs/common/dialogs';
|
||||
import { INotificationService } from 'vs/platform/notification/common/notification';
|
||||
import { once } from 'vs/base/common/event';
|
||||
import { ICommandService } from 'vs/platform/commands/common/commands';
|
||||
import { IEnvironmentService } from 'vs/platform/environment/common/environment';
|
||||
import { dispose } from 'vs/base/common/lifecycle';
|
||||
|
||||
@extHostNamedCustomer(MainContext.MainThreadMessageService)
|
||||
@@ -24,8 +23,7 @@ export class MainThreadMessageService implements MainThreadMessageServiceShape {
|
||||
extHostContext: IExtHostContext,
|
||||
@INotificationService private readonly _notificationService: INotificationService,
|
||||
@ICommandService private readonly _commandService: ICommandService,
|
||||
@IDialogService private readonly _dialogService: IDialogService,
|
||||
@IEnvironmentService private readonly _environmentService: IEnvironmentService
|
||||
@IDialogService private readonly _dialogService: IDialogService
|
||||
) {
|
||||
//
|
||||
}
|
||||
@@ -79,7 +77,7 @@ export class MainThreadMessageService implements MainThreadMessageServiceShape {
|
||||
}
|
||||
|
||||
const secondaryActions: IAction[] = [];
|
||||
if (extension && extension.extensionFolderPath !== this._environmentService.extensionDevelopmentPath) {
|
||||
if (extension && !extension.isUnderDevelopment) {
|
||||
secondaryActions.push(new ManageExtensionAction(extension.id, nls.localize('manageExtension', "Manage Extension"), this._commandService));
|
||||
}
|
||||
|
||||
|
||||
@@ -146,7 +146,7 @@ export function createApiFactory(
|
||||
// We only inform once, it is not a warning because we just want to raise awareness and because
|
||||
// we cannot say if the extension is doing it right or wrong...
|
||||
let checkSelector = (function () {
|
||||
let done = initData.environment.extensionDevelopmentPath !== extension.extensionFolderPath;
|
||||
let done = (!extension.isUnderDevelopment);
|
||||
function informOnce(selector: vscode.DocumentSelector) {
|
||||
if (!done) {
|
||||
console.info(`Extension '${extension.id}' uses a document selector without scheme. Learn more about this: https://go.microsoft.com/fwlink/?linkid=872305`);
|
||||
|
||||
Reference in New Issue
Block a user