public interface EditActionHandler
ResourceWorkspace.getEditActionHandler()
Modifier and Type | Method and Description |
---|---|
void |
addChangeListener(javax.swing.event.ChangeListener listener)
Add a change listener that will be notified when this handler's responses to the "can-" functions will have
changed.
|
boolean |
canCopy()
Can this edit action handler handle the copy action, given its current selection? Note that if this and
canDelete() both return true, the cut action will also be enabled. |
boolean |
canDelete()
Can this edit action handler handle the delete action, given its current selection? Note that if this and
canCopy() both return true, the cut action will also be enabled. |
boolean |
canPaste(java.awt.datatransfer.Clipboard clipboard)
Can this action handler handle a paste given the data flavors currently available in the clipboard?
|
java.awt.datatransfer.Transferable |
doCopy()
Called when the copy action is performed.
|
java.awt.datatransfer.Transferable |
doCut()
Called when the cut action is performed.
|
void |
doDelete()
Called when the delete action is performed
|
void |
doPaste(java.awt.datatransfer.Transferable clipboardContents)
Called when the paste action is performed
|
void |
removeChangeListener(javax.swing.event.ChangeListener listener) |
void addChangeListener(javax.swing.event.ChangeListener listener)
void removeChangeListener(javax.swing.event.ChangeListener listener)
boolean canDelete()
canCopy()
both return true, the cut action will also be enabled.boolean canCopy()
canDelete()
both return true, the cut action will also be enabled.boolean canPaste(java.awt.datatransfer.Clipboard clipboard)
void doDelete()
java.awt.datatransfer.Transferable doCopy()
Transferable
, or null if the copy failed. Will be added to the
system clipboard.java.awt.datatransfer.Transferable doCut()
Transferable
, or null if the cut failed. Will be added to the
system clipboard.void doPaste(java.awt.datatransfer.Transferable clipboardContents)
clipboardContents
- The current contents of the clipboard to paste.