Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [e4-dev] Programmatically adding a command to a tool item

Hi Kai,

On Fri, Mar 23, 2012 at 7:47 AM, Toedter, Kai <kai.toedter@xxxxxxxxxxx> wrote:

Hi All,


I am currently making last preparations for EclipseCon. To get my personal MinMax Addon running I need to bind a command to a tool item (with a parameter). Here is my source:


MCommand command = MCommandsFactory.INSTANCE.createCommand();


command.setCommandName("Restore Stack");



You need to use command.getParameters() to add the matching MCommandParameter definition.


// application.getCommands().add(command);

I assume you are adding the command and handler to the application, right?


Paul Webster
Hi floor.  Make me a sammich! - GIR

Back to the top