public class DefaultActions
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CLOSE |
static java.lang.String |
COPY |
static java.lang.String |
CUT |
static java.lang.String |
EXIT |
static java.lang.String |
NEW |
static java.lang.String |
OPEN |
static java.lang.String |
PASTE |
static java.lang.String |
PRINT |
static java.lang.String |
QUIT |
static java.lang.String |
SAVE |
static java.lang.String |
SAVE_AS |
Constructor and Description |
---|
DefaultActions() |
Modifier and Type | Method and Description |
---|---|
static javax.swing.Action |
closeAction(Application app)
Create an action named "Close" that closes the current
document.
|
static javax.swing.Action |
copyAction(Application app)
Create an action named "Copy" that copies the current selection from
the current document and places it into the application's clipboard.
|
static javax.swing.Action |
cutAction(Application app)
Create an action named "Cut" that cuts the current selection from
the current document and places it into the application's clipboard.
|
static javax.swing.Action |
exitAction(Application app)
Create an action named "Exit" that tries to close all the
open documents, and if all of them are closed successfully,
then exits Java.
|
static javax.swing.Action |
newAction(Application app)
Create an action named "New" that creates a new
document.
|
static javax.swing.Action |
openAction(Application app)
Create an action named "Open" that opens a new
document.
|
static javax.swing.Action |
pasteAction(Application app)
Create an action named "Paste" that pastes the current selection from
the current document and places it into the application's clipboard.
|
static javax.swing.Action |
printAction(Application app)
Create an action named "Print" that prints the current
document to the printer, if it implements the Printable or
Pageable interface.
|
static javax.swing.Action |
quitAction(Application app)
Deprecated.
The standard windows term is "Exit," so use exitAction()
|
static javax.swing.Action |
saveAction(Application app)
Create an action named "Save" that saves the current
document.
|
static javax.swing.Action |
saveAsAction(Application app)
Create an action named "Save As" that saves the current
document to a different location.
|
public static final java.lang.String COPY
public static final java.lang.String CLOSE
public static final java.lang.String CUT
public static final java.lang.String EXIT
public static final java.lang.String NEW
public static final java.lang.String OPEN
public static final java.lang.String PASTE
public static final java.lang.String PRINT
public static final java.lang.String QUIT
public static final java.lang.String SAVE
public static final java.lang.String SAVE_AS
public static javax.swing.Action copyAction(Application app)
public static javax.swing.Action closeAction(Application app)
public static javax.swing.Action cutAction(Application app)
public static javax.swing.Action exitAction(Application app)
public static javax.swing.Action newAction(Application app)
public static javax.swing.Action openAction(Application app)
public static javax.swing.Action printAction(Application app)
public static javax.swing.Action pasteAction(Application app)
@Deprecated public static javax.swing.Action quitAction(Application app)
public static javax.swing.Action saveAction(Application app)
public static javax.swing.Action saveAsAction(Application app)