Package org.eclipse.ui.internal

Examples of org.eclipse.ui.internal.ActionSetContributionItem


        // given actionSetId.
        IContributionItem[] menuItems = mgr.getItems();
        for (int j = 0; j < menuItems.length; j++) {
            IContributionItem menuItem = menuItems[j];
            if (menuItem instanceof ActionSetContributionItem) {
                ActionSetContributionItem actionSetItem = (ActionSetContributionItem) menuItem;
                if (actionSetItem.getActionSetId().equals(actionSetId)) {
                    return true;
                }
            } else if (menuItem instanceof MenuManager) {
                MenuManager childMgr = (MenuManager) menuItem;
                boolean found = containsActionSet(childMgr, actionSetId);
View Full Code Here


                ContributionManager mgr = (ContributionManager) item;
                IContributionItem[] items = mgr.getItems();
                for (int i = 0; i < items.length; i++) {
                    IContributionItem mgrItem = items[i];
                    if (mgrItem instanceof ActionSetContributionItem) {
                        ActionSetContributionItem actionSetItem = (ActionSetContributionItem) mgrItem;
                        if (actionSetItem.getActionSetId().equals(actionSetId)) {
                            IContributionItem innerItem = actionSetItem
                                    .getInnerItem();
                            if (innerItem instanceof MenuManager) {
                                MenuManager inner = (MenuManager) actionSetItem
                                        .getInnerItem();
                                ActionSetDisplayItem node = new ActionSetDisplayItem(
                                        this, inner.getId(), inner
                                                .getMenuText(), MENUITEM);
                                node.fillMenusFor(actionSetId, inner);
                            } else if (innerItem instanceof ActionSetMenuManager) {
                                ActionSetMenuManager inner = (ActionSetMenuManager) actionSetItem
                                        .getInnerItem();
                                MenuManager parentMgr = (MenuManager) inner
                                        .getParent();
                                ActionSetDisplayItem node = new ActionSetDisplayItem(
                                        this, inner.getId(), parentMgr
                                                .getMenuText(), MENUITEM);
                                node.fillMenusFor(actionSetId, parentMgr);
                            } else if (innerItem instanceof PluginActionContributionItem) {
                                PluginActionContributionItem inner = (PluginActionContributionItem) actionSetItem
                                        .getInnerItem();
                                ActionSetDisplayItem node = new ActionSetDisplayItem(
                                        this, inner.getId(), inner.getAction()
                                                .getText(), MENUITEM);
                                IAction action = inner.getAction();
View Full Code Here

TOP

Related Classes of org.eclipse.ui.internal.ActionSetContributionItem

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.