Package org.jitterbit.application.ui.menu

Examples of org.jitterbit.application.ui.menu.MenuManager


  private void installDisplaySettingsShortcut() {
      Action action = new AbstractAction() {

            @Override
            public void actionPerformed(ActionEvent e) {
                MenuManager mgr = m_TreeMapper.getView().getMenuManager();
                Menu menu = mgr.getMenu(InterchangeMenus.MAP_AREA_SETTINGS);
                JPopupMenu popup = new JPopupMenu();
                menu.populate(popup);
                m_TreeMapper.showPopupMenu(popup);
            }
      };
View Full Code Here


        this.appWin = appWin;
        menuExtensionManagers = Maps.newHashMap();
    }

    public void buildMenu(List<ViewShell> shells) {
        MenuManager menuMgr = appWin.getMenuManager();
        Menu viewMenu = menuMgr.getMenu(ApplicationWindowMenus.VIEW);
        if (viewMenu == null) {
            // HACK: The application does not have a View menu. Ideally, this method
            // should not be called at all in that case.
            return;
        }
View Full Code Here

            mgr.addExtension(extension);
        }
    }

    private void populateMenus() {
        MenuManager menus = appWin.getMenuManager();
        for (MenuExtensionManager extMgr : menuExtensionManagers.values()) {
            extMgr.populateMenu(menus);
        }
    }
View Full Code Here

    private void checkEnabledState() {
        menu.setEnabled(RecentlyClosedEditorsPreference.INSTANCE.get() > 0);
    }

    public void contributeToWindowsMenu(ApplicationWindow appWin) {
        MenuManager mgr = appWin.getMenuManager();
        Menu windowsMenu = mgr.getMenu(ApplicationWindowMenus.WINDOWS);
        MenuContribution contrib = new MenuContribution("Windows.RecentlyClosed");
        contrib.addItem(menu);
        windowsMenu.addExtension(MenuExtensionPoint.EXTENSION_POINT_1, contrib);
    }
View Full Code Here

TOP

Related Classes of org.jitterbit.application.ui.menu.MenuManager

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.