public abstract class ActionPresenterProvider extends Object
In order to provide greater flexibility this is made as a pluggable component to allow other parts of the system to provide more enhanced visualizations.
Modifier | Constructor and Description |
---|---|
protected |
ActionPresenterProvider()
Subclass constructor.
|
Modifier and Type | Method and Description |
---|---|
abstract Component[] |
convertComponents(Component comp)
Used for implementation of
DynamicMenuContent . |
abstract JPopupMenu |
createEmptyPopup()
Creates a default empty implementation of popup menu.
|
abstract JMenuItem |
createMenuPresenter(Action action)
Creates a menu item that can present this action in a
JMenu . |
abstract JMenuItem |
createPopupPresenter(Action action)
Get a menu item that can present this action in a
JPopupMenu . |
abstract Component |
createToolbarPresenter(Action action)
Get a component that can present this action in a
JToolBar . |
static ActionPresenterProvider |
getDefault()
Gets the default implementation from lookup.
|
protected ActionPresenterProvider()
public static ActionPresenterProvider getDefault()
public abstract JPopupMenu createEmptyPopup()
public abstract JMenuItem createMenuPresenter(Action action)
JMenu
.action
- the action to representpublic abstract JMenuItem createPopupPresenter(Action action)
JPopupMenu
.action
- the action to representpublic abstract Component createToolbarPresenter(Action action)
JToolBar
.action
- the action to representpublic abstract Component[] convertComponents(Component comp)
DynamicMenuContent
.comp
- a component