Пример #1
0
 public ShellMenu(final Matcher<String>... matchers) {
   this.matchers = matchers;
   setMacOsMenuProperties();
   if (!isSubmenuOfMacEclipseMenu) {
     MenuLookup ml = new MenuLookup();
     menuItem = ml.lookFor(ml.getActiveShellTopMenuItems(), matchers);
   }
 }
Пример #2
0
 @Override
 public String getText() {
   if (!isSubmenuOfMacEclipseMenu) {
     MenuLookup ml = new MenuLookup();
     MenuItem i = ml.lookFor(ml.getActiveShellTopMenuItems(), matchers);
     String text = ml.getMenuItemText(i);
     return text;
   } else {
     return "&" + macEclipseMenuCommand.text;
   }
 }