tecgraf.javautils.pdfviewer.core.actions
Class PDFAbstractDocumentOpenAwareAction

java.lang.Object
  extended by javax.swing.AbstractAction
      extended by tecgraf.javautils.pdfviewer.core.actions.PDFAbstractDocumentOpenAwareAction
All Implemented Interfaces:
ActionListener, Serializable, Cloneable, EventListener, Action, PDFDocumentOpenCloseListener
Direct Known Subclasses:
PDFAbstractPageChangeAction, PDFCloseAction, PDFFitHeightAction, PDFFitWholePageAction, PDFFitWidthAction, PDFShowThumbnailsAction, PDFZoomInAction, PDFZoomOutAction

public abstract class PDFAbstractDocumentOpenAwareAction
extends AbstractAction
implements PDFDocumentOpenCloseListener

Ação básica que fica inibida/desabilitada de acordo com a existência de um doucmento aberto.

Author:
Tecgraf
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, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON
 
Constructor Summary
PDFAbstractDocumentOpenAwareAction(PDFCorePanel pdfCorePanel, Icon icon)
          Construtor
 
Method Summary
 void documentClosed(PDFCorePanel source)
          Indica que um documento PDF foi fechado
 void documentOpened(PDFCorePanel source)
          Indica que um documento PDF foi aberto
protected  PDFCorePanel getPDFCorePanel()
          Consulta o painel básico associado.
 
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
 
Methods inherited from interface java.awt.event.ActionListener
actionPerformed
 

Constructor Detail

PDFAbstractDocumentOpenAwareAction

public PDFAbstractDocumentOpenAwareAction(PDFCorePanel pdfCorePanel,
                                          Icon icon)
Construtor

Parameters:
pdfCorePanel - painel básico.
icon - ícone da ação
Method Detail

getPDFCorePanel

protected PDFCorePanel getPDFCorePanel()
Consulta o painel básico associado.

Returns:
o painel

documentOpened

public void documentOpened(PDFCorePanel source)
Indica que um documento PDF foi aberto

Specified by:
documentOpened in interface PDFDocumentOpenCloseListener
Parameters:
source - PDFCorePanel origem do evento

documentClosed

public void documentClosed(PDFCorePanel source)
Indica que um documento PDF foi fechado

Specified by:
documentClosed in interface PDFDocumentOpenCloseListener
Parameters:
source - PDFCorePanel origem do evento


Copyright © 2015 Tecgraf/PUC-Rio. All rights reserved.