javax.swing.plaf.basic

Class BasicTreeUI.TreeIncrementAction

public class BasicTreeUI.TreeIncrementAction extends AbstractAction

TreeIncrementAction is used to handle up/down actions. Selection is moved up or down based on direction.
Field Summary
protected intdirection
Specifies the direction to adjust the selection by.
Constructor Summary
TreeIncrementAction(int dir, String name)
Creates a new TreeIncrementAction.
Method Summary
voidactionPerformed(ActionEvent e)
Invoked when an action occurs.
booleanisEnabled()
Returns true if the action is enabled.

Field Detail

direction

protected int direction
Specifies the direction to adjust the selection by.

Constructor Detail

TreeIncrementAction

public TreeIncrementAction(int dir, String name)
Creates a new TreeIncrementAction.

Parameters: dir up or down, -1 for up, 1 for down name is the name of the direction

Method Detail

actionPerformed

public void actionPerformed(ActionEvent e)
Invoked when an action occurs.

Parameters: e is the event that occured

isEnabled

public boolean isEnabled()
Returns true if the action is enabled.

Returns: true if the action is enabled.