Я пытаюсь разработать плагин Eclipse, который будет запускать определенные цели в виде команд, привязываемых ключами.
Вот plugin.xml
:
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
<extension point="org.eclipse.ui.commands">
<category name="Custom Launcher" id="Eclipse_Keybound_Launch_Plugin.commands.category"/>
<command
categoryId="Eclipse_Keybound_Launch_Plugin.commands.category"
defaultHandler="eclipse_keybound_launch_plugin.handlers.CustomLaunchCommandHandler"
description="Launch/terminate then relaunch a custom target in debug mode"
id="Eclipse_Keybound_Launch_Plugin.commands.terminateLaunch"
name="Launch">
<commandParameter
id="Eclipse Keybound Launch Plugin.launchTarget"
name="target"
optional="false"
/>
</command>
</extension>
<extension point="org.eclipse.ui.bindings">
<key commandId="Eclipse_Keybound_Launch_Plugin.commands.terminateLaunch"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
contextId="org.eclipse.ui.contexts.window"
sequence="M1+6">
<parameter id="Eclipse Keybound Launch Plugin.launchTarget" value="RunMe"/>
</key>
</extension>
<extension point="org.eclipse.ui.bindings">
<key commandId="Eclipse_Keybound_Launch_Plugin.commands.terminateLaunch"
schemeId="org.eclipse.ui.defaultAcceleratorConfiguration"
contextId="org.eclipse.ui.contexts.window"
sequence="M1+7">
<parameter id="Eclipse Keybound Launch Plugin.launchTarget" value="RunMeAlso"/>
</key>
</extension>
</plugin>
Для полноты вот каквыглядит в расширении:
![enter image description here](https://i.stack.imgur.com/JHSC3.png)
Плагин работает, когда я проверяю его;значение параметра доступно в ExecutionEvent
.Однако это значение не отображается в настройках предпочтений / ключей:
![enter image description here](https://i.stack.imgur.com/OrQoj.png)
Почему это так?Что мне нужно сделать, чтобы Eclipse показывал не только имя (target:
), но и значения параметров (в данном случае RunMe
и RunMeAlso
)?
Обратите внимание, что яс использованием Eclipse SDK Версия: 3.6.1, идентификатор сборки: M20100909-0800.