T - the type of the action commandpublic abstract class AbstractActiveContextSensitiveFXAction<T> extends AbstractFXAction implements ActiveContextSensitive, AutoCloseable
ActiveContextSensitive FXActions.accelerator, displayName, enabled, graphicFactory| Constructor and Description |
|---|
AbstractActiveContextSensitiveFXAction(Class<T> type)
Creates a new instance of this class.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
protected abstract void |
contextChanged(ContextEvent<T> event)
The callback method which gets called when the content for the action
command type in the active context changes.
|
Context |
getActiveContext()
Gets the active context.
|
Class<T> |
getType()
Gets the type of the action command
|
void |
setActiveContext(Context activeContext)
Sets the active context.
|
acceleratorProperty, displayNameProperty, enabledProperty, getAccelerator, getDisplayName, getGraphicFactory, graphicFactoryProperty, isEnabled, setAccelerator, setDisplayName, setEnabled, setGraphicFactoryclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waithandlepublic void setActiveContext(Context activeContext)
setActiveContext in interface ActiveContextSensitiveactiveContext - the active contextprotected abstract void contextChanged(ContextEvent<T> event)
T myActionCommand = getActiveContext().find(contextEvent.getType());event - the context eventpublic void close()
close in interface AutoCloseablepublic Context getActiveContext()
ActiveContextSensitiveCopyright © 2012–2018 Drombler. All rights reserved.