Skip to content

Instantly share code, notes, and snippets.

@britter
Last active December 16, 2015 10:49
Show Gist options
  • Save britter/5422624 to your computer and use it in GitHub Desktop.
Save britter/5422624 to your computer and use it in GitHub Desktop.
Example for creating a static sub menu in an Eclipse RCP application
MenuManager parent = new MenuManager("Root menu");
MenuManager sub = new MenuManager("Sub menu");
IAction one = new Action(){};
one.setText("one");
IAction two = new Action(){};
two.setText("two");
IAction one = new Action(){};
three.setText("three");
sub.add(one);
sub.add(two);
sub.add(three);
parent.add(sub);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment