|
SWT LPEX v3.0.0 | |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ibm.lpex.samples.CopyLineAction
Sample action copyLine - copy selection / current line to clipboard. This action is similar to the copy default editor action, but it will copy the current element to the clipboard if there is no selection in the current view.
Here is the CopyLineAction source code.
To run this sample:
set actionClass.copyLine com.ibm.lpex.samples.CopyLineAction
action copyLineor associate it with a key:
set keyAction.c-c copyLine
Constructor Summary | |
---|---|
CopyLineAction()
|
Method Summary | |
---|---|
boolean | available(LpexView lpexView)
This method in the defined action will be called to query the availability of the action. |
void | doAction(LpexView lpexView)
This method in the defined action will be called to run the action. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public CopyLineAction()
Method Detail |
public void doAction(LpexView lpexView)
An action may be run (e.g., from the LPEX command line) with the action editor command, by selecting an associated menu item, or by activating the key or the mouse event to which the action is assigned.
public boolean available(LpexView lpexView)
When this method returns false, menu items associated with this user action will be disabled, the key or mouse event to which this action is assigned will not run it, and neither will the action command.
|
SWT LPEX v3.0.0 | |||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |