Conversation
0c1d85b to
cddae89
Compare
wewoor
reviewed
Jun 25, 2021
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
简介
主要变更
Provider中initWorkbenchActions的方法,改成通过 extension 的方式注册extensionService中新增registerAction方法,用户通过该方法注册 ActionkeybindingHelper,提供 query 和 convert 方法id查找对应的全局命令,目前判断是否是全局的方式是通过是否有 when 属性判断,如果无则代表无时无刻都可以执行的命令,则理解为全局命令ISimplyKeybinding类型转为字符串以供展示id,因为 query 要通过id来查找注册的全局命令,这就使得如果注册的 id 和 menu id 如果不保持一致的话,会导致找不到命令,所以有一个强制要求,就是menu的id需要和注册的全局事件的id保持一致components/menu仅负责渲染,所以要求传入的数据是处理好的数据,已经带有keybinding。故在 activityBar 和 menuBar 中对 data 进行转化,使得barData => menuData。activate(extensionCtx){}拿到extensionCtxRelated Issues
Closed #162