public class AnimTreeChooseAction extends TreeChooseAction
TreeChooseAction
that updates an animation label.Constructor and Description |
---|
AnimTreeChooseAction(@NotNull java.lang.String text,
@NotNull javax.swing.text.JTextComponent textComponent,
@NotNull javax.swing.AbstractButton icon,
@NotNull AnimationObjects animationObjects,
@NotNull FaceObjectProviders faceObjectProviders,
@NotNull javax.swing.ImageIcon noFaceSquareIcon,
@NotNull javax.swing.ImageIcon unknownSquareIcon)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
void |
actionPerformed(@NotNull java.awt.event.ActionEvent e) |
protected @NotNull AnimTreeChooseAction |
clone() |
void |
setEnabled(boolean newValue) |
void |
updateIconLabel()
Updates the icon of
icon to reflect the current animation name. |
getFaceName
public AnimTreeChooseAction(@NotNull @NotNull java.lang.String text, @NotNull @NotNull javax.swing.text.JTextComponent textComponent, @NotNull @NotNull javax.swing.AbstractButton icon, @NotNull @NotNull AnimationObjects animationObjects, @NotNull @NotNull FaceObjectProviders faceObjectProviders, @NotNull @NotNull javax.swing.ImageIcon noFaceSquareIcon, @NotNull @NotNull javax.swing.ImageIcon unknownSquareIcon)
text
- the text for the buttontextComponent
- the text component that holds the current animation
nameicon
- the label showing the iconanimationObjects
- the animation objects providing the animation
names treefaceObjectProviders
- the face object providers for looking up
facesnoFaceSquareIcon
- the image icon for no animationsunknownSquareIcon
- the image icon for undefined animationspublic void actionPerformed(@NotNull @NotNull java.awt.event.ActionEvent e)
actionPerformed
in interface java.awt.event.ActionListener
actionPerformed
in class TreeChooseAction
public final void updateIconLabel()
icon
to reflect the current animation name.@NotNull protected @NotNull AnimTreeChooseAction clone()
clone
in class TreeChooseAction
public void setEnabled(boolean newValue)
setEnabled
in interface javax.swing.Action
setEnabled
in class javax.swing.AbstractAction