Top Fields Constructors Methods
org.freedesktop.dbus.viewer

pack-priv abstract Class TabbedSaveAction

extends AbstractAction
implements Iterable<TextFile>
Class Inheritance
All Implemented Interfaces
java.lang.Iterable
Known Direct Subclasses
org.freedesktop.dbus.viewer.SaveAllAction, org.freedesktop.dbus.viewer.SaveFileAction
Imports
java.awt.event.ActionEvent, java.io.File, javax.swing.AbstractAction, .JFileChooser, .JOptionPane, .JScrollPane, .JTabbedPane, javax.swing.text.JTextComponent

Field Summary

Modifier and TypeField and Description
private JFileChooser
chooser

File chooser component.

private static final long
protected final JTabbedPane
Inherited from javax.swing.AbstractAction:
changeSupportenabled

Constructor Summary

AccessConstructor and Description
protected
protected
TabbedSaveAction(JTabbedPane _tabbedPane, String _name)

Method Summary

Modifier and TypeMethod and Description
public final void
actionPerformed(ActionEvent
the event to be processed
_event
)

Implements java.awt.event.ActionListener.actionPerformed.

Invoked when an action occurs.

protected String

Returns:

The file name for the referenced tab
getFileName
(int
The tabbed pane index
_index
)

Get the file name for the supplied index

protected TextFile

Returns:

The text file object for the referenced tab
getTextFile
(int
The tabbed pane index
_index
)

Get the text file object associated with the supplied index

Inherited from javax.swing.AbstractAction:
addPropertyChangeListenerclonefirePropertyChangegetKeysgetPropertyChangeListenersgetValueisEnabledputValueremovePropertyChangeListenersetEnabled

Field Detail

chooserback to summary
private JFileChooser chooser

File chooser component. Make static so that previous save location is stored

serialVersionUIDback to summary
private static final long serialVersionUID
tabbedPaneback to summary
protected final JTabbedPane tabbedPane

Constructor Detail

TabbedSaveActionback to summary
protected TabbedSaveAction(JTabbedPane _tabbedPane)
TabbedSaveActionback to summary
protected TabbedSaveAction(JTabbedPane _tabbedPane, String _name)

Method Detail

actionPerformedback to summary
public final void actionPerformed(ActionEvent _event)

Implements java.awt.event.ActionListener.actionPerformed.

Doc from java.awt.event.ActionListener.actionPerformed.

Invoked when an action occurs.

Parameters
_event:ActionEvent

the event to be processed

Annotations
@Override
getFileNameback to summary
protected String getFileName(int _index)

Get the file name for the supplied index

Parameters
_index:int

The tabbed pane index

Returns:String

The file name for the referenced tab

getTextFileback to summary
protected TextFile getTextFile(int _index)

Get the text file object associated with the supplied index

Parameters
_index:int

The tabbed pane index

Returns:TextFile

The text file object for the referenced tab