java.lang.Object
org.eclipse.jface.action.ContributionItem
org.apache.uima.caseditor.editor.contextmenu.ModeMenu
All Implemented Interfaces:
org.eclipse.jface.action.IContributionItem

public class ModeMenu extends org.eclipse.jface.action.ContributionItem
Creates the mode context sub menu.
  • Constructor Summary

    Constructors
    Constructor
    Description
    ModeMenu(TypeSystem typeSystem, AnnotationEditor editor)
    Initializes a new instance.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Adds the listener.
    void
    fill(org.eclipse.swt.widgets.Menu menu, int index)
    Fills the menu with type entries.
    protected void
    insertAction(Type type, org.eclipse.swt.widgets.Menu parentMenu)
    Implementing classes must implement this method to insert actions into the type menu.
    void
    Removes the listener.

    Methods inherited from class org.eclipse.jface.action.ContributionItem

    dispose, fill, fill, fill, getId, getParent, isDirty, isDynamic, isEnabled, isGroupMarker, isSeparator, isVisible, saveWidgetState, setId, setParent, setVisible, toString, update, update

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • ModeMenu

      public ModeMenu(TypeSystem typeSystem, AnnotationEditor editor)
      Initializes a new instance.
      Parameters:
      typeSystem - the type system
      editor - the editor
  • Method Details

    • addListener

      public void addListener(IModeMenuListener listener)
      Adds the listener.
      Parameters:
      listener - the listener
    • removeListener

      public void removeListener(IModeMenuListener listener)
      Removes the listener.
      Parameters:
      listener - the listener
    • insertAction

      protected void insertAction(Type type, org.eclipse.swt.widgets.Menu parentMenu)
      Implementing classes must implement this method to insert actions into the type menu.
      Parameters:
      type - the type
      parentMenu - the parent menu
    • fill

      public void fill(org.eclipse.swt.widgets.Menu menu, int index)
      Fills the menu with type entries.
      Specified by:
      fill in interface org.eclipse.jface.action.IContributionItem
      Overrides:
      fill in class org.eclipse.jface.action.ContributionItem
      Parameters:
      menu - the menu
      index - the index