projectviewer.action
Class OpenSelectedAction
java.lang.Object
projectviewer.action.Action
projectviewer.action.OpenSelectedAction
- All Implemented Interfaces:
- java.awt.event.ActionListener, java.lang.Cloneable, java.lang.Comparable<Action>, java.util.EventListener
public class OpenSelectedAction
- extends Action
Opens all selected file nodes. This action is only shown in the
context menu when multiple files are selected.
- Since:
- PV 3.0.0
- Author:
- Marcelo Vanzin
Method Summary |
void |
actionPerformed(java.awt.event.ActionEvent e)
|
java.lang.String |
getText()
Returns a String that will be shown as the text of the menu item or
the tooltip of the toolbar button. |
void |
prepareForNode(VPTNode node)
When a node is selected (for the toolbar button) or when the context
menu is shown (for the menu item), this method is called and the
selected node is passed, so the action can choose whether the action
will be available or not for that node. |
Methods inherited from class java.lang.Object |
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
OpenSelectedAction
public OpenSelectedAction()
getText
public java.lang.String getText()
- Description copied from class:
Action
- Returns a String that will be shown as the text of the menu item or
the tooltip of the toolbar button.
- Specified by:
getText
in class Action
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)
prepareForNode
public void prepareForNode(VPTNode node)
- Description copied from class:
Action
- When a node is selected (for the toolbar button) or when the context
menu is shown (for the menu item), this method is called and the
selected node is passed, so the action can choose whether the action
will be available or not for that node. A common action would be
disable the button or hide the menu item.
By default, does nothing.
- Overrides:
prepareForNode
in class Action
- Parameters:
node
- The selected node, or null
if multiple
nodes are selected.