提交 ff822422 编写于 作者: I isidor

explorer: copy path and copy relative path to their own groups

上级 b555eb88
......@@ -115,7 +115,7 @@ const PASTE_FILE_ID = 'filesExplorer.paste';
KeybindingsRegistry.registerCommandAndKeybindingRule({
id: PASTE_FILE_ID,
weight: KeybindingWeight.WorkbenchContrib + explorerCommandsWeightBonus,
when: ContextKeyExpr.and(FilesExplorerFocusCondition, ExplorerResourceNotReadonlyContext),
when: ContextKeyExpr.and(FilesExplorerFocusCondition, ExplorerResourceNotReadonlyContext, FileCopiedContext),
primary: KeyMod.CtrlCmd | KeyCode.KEY_V,
handler: pasteFileHandler
});
......@@ -441,20 +441,20 @@ MenuRegistry.appendMenuItem(MenuId.ExplorerContext, {
command: {
id: PASTE_FILE_ID,
title: PASTE_FILE_LABEL,
precondition: FileCopiedContext
precondition: ContextKeyExpr.and(ExplorerResourceNotReadonlyContext, FileCopiedContext)
},
when: ExplorerFolderContext
});
MenuRegistry.appendMenuItem(MenuId.ExplorerContext, {
group: '5_cutcopypaste',
group: '6_copypath',
order: 30,
command: copyPathCommand,
when: ResourceContextKey.IsFileSystemResource
});
MenuRegistry.appendMenuItem(MenuId.ExplorerContext, {
group: '5_cutcopypaste',
group: '6_copypath',
order: 30,
command: copyRelativePathCommand,
when: ResourceContextKey.IsFileSystemResource
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册