@@ -13,7 +13,7 @@ import { EnablementState, IExtensionManagementServerService, IWorkbenchExtension
13
13
import { IExtensionIgnoredRecommendationsService , IExtensionRecommendationsService } from 'vs/workbench/services/extensionRecommendations/common/extensionRecommendations' ;
14
14
import { IWorkbenchContributionsRegistry , Extensions as WorkbenchExtensions , IWorkbenchContribution } from 'vs/workbench/common/contributions' ;
15
15
import { SyncDescriptor } from 'vs/platform/instantiation/common/descriptors' ;
16
- import { VIEWLET_ID , IExtensionsWorkbenchService , IExtensionsViewPaneContainer , TOGGLE_IGNORE_EXTENSION_ACTION_ID , INSTALL_EXTENSION_FROM_VSIX_COMMAND_ID , WORKSPACE_RECOMMENDATIONS_VIEW_ID , IWorkspaceRecommendedExtensionsView , AutoUpdateConfigurationKey , HasOutdatedExtensionsContext , SELECT_INSTALL_VSIX_EXTENSION_COMMAND_ID , LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID , ExtensionEditorTab , THEME_ACTIONS_GROUP , INSTALL_ACTIONS_GROUP , OUTDATED_EXTENSIONS_VIEW_ID , CONTEXT_HAS_GALLERY , IExtension , extensionsSearchActionsMenu , UPDATE_ACTIONS_GROUP } from 'vs/workbench/contrib/extensions/common/extensions' ;
16
+ import { VIEWLET_ID , IExtensionsWorkbenchService , IExtensionsViewPaneContainer , TOGGLE_IGNORE_EXTENSION_ACTION_ID , INSTALL_EXTENSION_FROM_VSIX_COMMAND_ID , WORKSPACE_RECOMMENDATIONS_VIEW_ID , IWorkspaceRecommendedExtensionsView , AutoUpdateConfigurationKey , HasOutdatedExtensionsContext , SELECT_INSTALL_VSIX_EXTENSION_COMMAND_ID , LIST_WORKSPACE_UNSUPPORTED_EXTENSIONS_COMMAND_ID , ExtensionEditorTab , THEME_ACTIONS_GROUP , INSTALL_ACTIONS_GROUP , OUTDATED_EXTENSIONS_VIEW_ID , CONTEXT_HAS_GALLERY , IExtension , extensionsSearchActionsMenu , UPDATE_ACTIONS_GROUP , IExtensionArg } from 'vs/workbench/contrib/extensions/common/extensions' ;
17
17
import { ReinstallAction , InstallSpecificVersionOfExtensionAction , ConfigureWorkspaceRecommendedExtensionsAction , ConfigureWorkspaceFolderRecommendedExtensionsAction , PromptExtensionInstallFailureAction , SearchExtensionsAction , SetColorThemeAction , SetFileIconThemeAction , SetProductIconThemeAction , ClearLanguageAction , ToggleAutoUpdateForExtensionAction , ToggleAutoUpdatesForPublisherAction , TogglePreReleaseExtensionAction } from 'vs/workbench/contrib/extensions/browser/extensionsActions' ;
18
18
import { ExtensionsInput } from 'vs/workbench/contrib/extensions/common/extensionsInput' ;
19
19
import { ExtensionEditor } from 'vs/workbench/contrib/extensions/browser/extensionEditor' ;
@@ -80,6 +80,7 @@ import { IStringDictionary } from 'vs/base/common/collections';
80
80
import { CONTEXT_KEYBINDINGS_EDITOR } from 'vs/workbench/contrib/preferences/common/preferences' ;
81
81
import { DeprecatedExtensionsChecker } from 'vs/workbench/contrib/extensions/browser/deprecatedExtensionsChecker' ;
82
82
import { ProgressLocation } from 'vs/platform/progress/common/progress' ;
83
+ import { IUriIdentityService } from 'vs/platform/uriIdentity/common/uriIdentity' ;
83
84
84
85
// Singletons
85
86
registerSingleton ( IExtensionsWorkbenchService , ExtensionsWorkbenchService , InstantiationType . Eager /* Auto updates extensions */ ) ;
@@ -1534,8 +1535,9 @@ class ExtensionsContributions extends Disposable implements IWorkbenchContributi
1534
1535
when : ContextKeyExpr . and ( ContextKeyExpr . equals ( 'extensionStatus' , 'installed' ) , ContextKeyExpr . has ( 'isDefaultApplicationScopedExtension' ) . negate ( ) , ContextKeyExpr . has ( 'isBuiltinExtension' ) . negate ( ) , ContextKeyExpr . equals ( 'isWorkspaceScopedExtension' , false ) ) ,
1535
1536
order : 3
1536
1537
} ,
1537
- run : async ( accessor : ServicesAccessor , id : string ) => {
1538
- const extension = this . extensionsWorkbenchService . local . find ( e => areSameExtensions ( { id } , e . identifier ) ) ;
1538
+ run : async ( accessor : ServicesAccessor , _ : string , extensionArg : IExtensionArg ) => {
1539
+ const uriIdentityService = accessor . get ( IUriIdentityService ) ;
1540
+ const extension = extensionArg . location ? this . extensionsWorkbenchService . installed . find ( e => uriIdentityService . extUri . isEqual ( e . local ?. location , extensionArg . location ) ) : undefined ;
1539
1541
if ( extension ) {
1540
1542
return this . extensionsWorkbenchService . toggleApplyExtensionToAllProfiles ( extension ) ;
1541
1543
}
0 commit comments