jcreek.cke.command
Class PrintAction

java.lang.Object
  extended byjavax.swing.AbstractAction
      extended byjcreek.cke.command.CreekAction
          extended byjcreek.cke.command.PrintAction
All Implemented Interfaces:
javax.swing.Action, java.awt.event.ActionListener, java.lang.Cloneable, java.util.EventListener, java.beans.PropertyChangeListener, java.io.Serializable

public class PrintAction
extends CreekAction
implements java.beans.PropertyChangeListener

Implements the print file action used to print the current graph document to a hardcopy printer.

Version:
Author:
See Also:
Serialized Form

Field Summary
 
Fields inherited from class javax.swing.AbstractAction
changeSupport, enabled
 
Fields inherited from interface javax.swing.Action
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
PrintAction()
          Creates a new PrintAction object with the default action command string of "print".
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent event)
          Performs the print action.
 void propertyChange(java.beans.PropertyChangeEvent e)
           
 
Methods inherited from class jcreek.cke.command.CreekAction
getDocument, getModel, getString, getView, getWindow, noCurrentDocument
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PrintAction

public PrintAction()
Creates a new PrintAction object with the default action command string of "print".

Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent event)
Performs the print action. This asks the current document to discard any changes that have been made. Possibly displays an error dialog if the print fails.

Specified by:
actionPerformed in interface java.awt.event.ActionListener
Parameters:
event - action event

propertyChange

public void propertyChange(java.beans.PropertyChangeEvent e)
Specified by:
propertyChange in interface java.beans.PropertyChangeListener


Created at IDI, NTNU by the Artificial Intelligence and Learning group