首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > JAVA > Eclipse开发 >

开发Eclipse插件,需给弹出菜单增加快捷键

2011-12-24 
开发Eclipse插件,需要给弹出菜单增加快捷键开发Eclipse插件,需要给弹出菜单增加快捷键查询Eclipse的帮助需

开发Eclipse插件,需要给弹出菜单增加快捷键
开发Eclipse插件,需要给弹出菜单增加快捷键
查询Eclipse的帮助需要设置commands和bindings两个扩展点。

但是无法设置成功

谁能给一个成功的sample


[解决办法]
eclipse自己的一个例子,你看一下就明白

popup的action
<action
label= "%StepIntoAction.label "
icon= "$nl$/icons/full/elcl16/stepinto_co.gif "
helpContextId= "step_into_action_context "
definitionId= "org.eclipse.debug.ui.commands.StepInto "
class= "org.eclipse.debug.internal.ui.actions.StepIntoActionDelegate "
menubarPath= "stepIntoGroup "
enablesFor= "1 "
id= "org.eclipse.debug.ui.debugview.popupMenu.stepInto ">
<selection
class= "org.eclipse.debug.core.model.IStep ">
</selection>
</action>

<!-- commands and their bindings
NOTE:
M1 = CTRL/COMMAND
M2 = SHIFT
M3 = ALT
M4 = Platform-specific fourth key
-->
commands:
<command
name= "%ActionDefinition.stepInto.name "
categoryId= "org.eclipse.debug.ui.category.run "
description= "%ActionDefinition.stepInto.description "
id= "org.eclipse.debug.ui.commands.StepInto ">
</command>

快捷键:
<extension point= "org.eclipse.ui.bindings ">
<key
sequence= "F5 "
contextId= "org.eclipse.debug.ui.debugging "
commandId= "org.eclipse.debug.ui.commands.StepInto "
schemeId= "org.eclipse.ui.defaultAcceleratorConfiguration "/>

[解决办法]
mark
[解决办法]
re

探讨
eclipse自己的一个例子,你看一下就明白

popup的action
<action
label= "%StepIntoAction.label "
icon= "$nl$/icons/full/elcl16/stepinto_co.gif "
helpContextId= "step_into_action_context "
definitionId= "org.eclipse.debug.ui.commands.StepInto "

热点排行