Interface DynamicSubmenuListener

  • All Superinterfaces:
    EventListener, MenuListener, PopupMenuListener

    public interface DynamicSubmenuListener
    extends MenuListener, PopupMenuListener
    An extension of MenuListener that is used to describe dynamic submenus. This interface allows the top name of the dynamic menu to be set and allows the menu to be enabled or disabled based on the state of the system.

    Module: work-swing-api

    To use this in your app, include the following dependency in your POM:

    <dependency>
        <groupId>org.cytoscape</groupId>
        <artifactId>work-swing-api</artifactId>
    </dependency>

    Cytoscape Backwards Compatibility (API Interface): We expect that this interface will be used but not implemented by developers using this interface. As such, we reserve the right to add methods to the interface as part of minor version upgrades. We will not remove methods for any changes other than major version upgrades.
    • Method Detail

      • setMenuTitle

        void setMenuTitle​(String name)
        Sets the name of the top level menu.
        Parameters:
        name - The name to use for the top level menu.
      • setEnabled

        void setEnabled​(boolean enableState)
        Enables or disables the dynamically created menus.
        Parameters:
        enableState - Whether to enable or disable the menu.