Example usage for org.eclipse.jface.action IMenuManager dispose

List of usage examples for org.eclipse.jface.action IMenuManager dispose

Introduction

In this page you can find the example usage for org.eclipse.jface.action IMenuManager dispose.

Prototype

void dispose();

Source Link

Document

Disposes of this contribution item.

Usage

From source file:org.bonitasoft.studio.contract.ui.property.constraint.edit.editor.ContractConstraintEditor.java

License:Open Source License

@Override
public void editorContextMenuAboutToShow(final IMenuManager menu) {
    menu.dispose();
}

From source file:org.bonitasoft.studio.groovy.ui.viewer.BonitaGroovyEditor.java

License:Open Source License

public void editorContextMenuAboutToShow(IMenuManager menu) {
    menu.dispose();
}

From source file:org.eclipse.wst.sse.ui.tests.TestStructuredTextEditor.java

License:Open Source License

public void testEditorContextMenuAboutToShow() {
    IMenuManager menu = new MenuManager();
    fEditor.editorContextMenuAboutToShow(menu);
    assertTrue("Unable to prepare for context menu about to show", true);
    menu.dispose();
    menu = null;//w w w . j  av a 2 s  .c  o  m
}

From source file:org.kalypso.ui.editor.actions.FeatureSelectionActionGroup.java

License:Open Source License

private void updateToolbar() {
    if (m_toolbarSubManager == null)
        m_toolbarSubManager = createSubToolbarManager(m_actionBars.getToolBarManager());

    if (m_toolbarSubManager == null)
        return;//w  w w .ja  v  a 2s.  com

    m_toolbarSubManager.removeAll();

    if (m_part == null)
        return;

    // TODO: also refaktor in external class

    /* first, fill the actions into a fake manager */
    final IMenuManager fakeManager = new MenuManager();
    ObjectActionContributorManager.getManager().contributeObjectActions(m_part, fakeManager, m_provider);

    translateIntoToolbar(fakeManager, m_toolbarSubManager);

    /* release the fake manager */
    fakeManager.removeAll();
    fakeManager.dispose();

    m_toolbarSubManager.update(true);
}