O'Reilly logo

Getting Started with Eclipse Juno by Vinicius H. S. Durelli, Rafael Medeiros Teixeira, Rodrigo Fraxino Araujo

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Contributing to the platform's menus and toolbars

In the example that we used to illustrate how to declare and implement an extension point, we created a plugin that adds a button to the Eclipse toolbar. Now, let's take a more careful look at how this button was added there, as well as find out how we could add elements to other parts of the Eclipse interface.

Actions versus commands

The first thing we should know is that there are two different ways of contributing to menus in the Eclipse UI: actions and commands. The action way that we used in the previous example might look simpler at first, but simplicity has a price here; as you can see, logic and interface are closely tied, which might lead to code replication if you want to add, for example, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required