Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 312556 - [actions] cannot bind keyboard shortcut to "Use as Source Folder" command (and other buildpath actions)
Summary: [actions] cannot bind keyboard shortcut to "Use as Source Folder" command (an...
Status: CLOSED WONTFIX
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 3.6   Edit
Hardware: PC Linux
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: JDT-UI-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-05-12 05:25 EDT by heekyu CLA
Modified: 2010-05-12 07:11 EDT (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description heekyu CLA 2010-05-12 05:25:32 EDT
Build Identifier: 20100218-1602

I can add selected folders to source folder along with
right click -> Build Path -> Use as Source Path.
I want to do this action with keyboard shortcut, but there is no way to assign a key to this command.
I looked into related source codes a little of time.
It seems to be able to assign keys to commands which are configured with "org.eclipse.ui.commands" extension point. "Use as Source Path" is not a command of this type and so cannot assign key bindings.

I want to know whether my analysis is correct and get solution or workaround.

I'll be waiting your answer.
Thank you.

Reproducible: Always

Steps to Reproduce:
1. explained all in Details
Comment 1 Markus Keller CLA 2010-05-12 06:46:30 EDT
Yes, we currently don't have commands for all the build path actions from GenerateBuildPathActionGroup.

Fix would be to define them in the plugin.xml, add constants to IJavaEditorActionDefinitionIds, and set the command ids via Action#setActionDefinitionId(String).
Comment 2 heekyu CLA 2010-05-12 07:11:59 EDT
OK, I understood totally.
Thank you for your kind answer.
If plan to fix the code according to your comments, it will be helpful that add comments about that in this Issue.