Package org.apache.pivot.wtk
Interface MenuBarListener
-
- All Known Implementing Classes:
MenuBarListener.Adapter
,MenuBarListener.Listeners
,TerraMenuBarSkin
public interface MenuBarListener
Menu bar listener interface.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
MenuBarListener.Adapter
Deprecated.Since 2.1 and Java 8 the interface itself has default implementations.static class
MenuBarListener.Listeners
Menu bar listeners.
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default void
activeItemChanged(MenuBar menuBar, MenuBar.Item previousActiveItem)
Called when a menu bar's active item has changed.default void
itemInserted(MenuBar menuBar, int index)
Called when a menu bar item has been inserted.default void
itemsRemoved(MenuBar menuBar, int index, Sequence<MenuBar.Item> removed)
Called when menu bar items have been removed.
-
-
-
Method Detail
-
itemInserted
default void itemInserted(MenuBar menuBar, int index)
Called when a menu bar item has been inserted.- Parameters:
menuBar
- The menu bar that changed.index
- The index where a new item was inserted.
-
itemsRemoved
default void itemsRemoved(MenuBar menuBar, int index, Sequence<MenuBar.Item> removed)
Called when menu bar items have been removed.- Parameters:
menuBar
- The source of the event.index
- The starting index where items were removed.removed
- The sequence of removed items.
-
activeItemChanged
default void activeItemChanged(MenuBar menuBar, MenuBar.Item previousActiveItem)
Called when a menu bar's active item has changed.- Parameters:
menuBar
- The source of the event.previousActiveItem
- Which item was active previously.
-
-