Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## net.sourceforge.jsxe
Class LocalizedAction

    java.lang.Object
      net.sourceforge.jsxe.LocalizedAction

Direct Known Subclasses:
  ActivityLogAction, CopyAction, CutAction, DocumentOptionsAction, FileCloseAction, FileCloseAllAction, FileExitAction, FileNewAction, FileOpenAction, FileReloadAction, FileSaveAction, FileSaveAsAction, FindAction, FindNextAction, jsxeAboutDialog, PasteAction, ToolsOptionsAction, ToolsPluginManagerAction, ValidationErrorsAction

public abstract class LocalizedAction
extends Object

An action that can be used by jsXe. These actions are registered with jsXe through ActionSets. These ActionSets can be registered with jsXe by plugins. Once an LocalizedAction is included in an ActionSet and registered with jsXe via the `addActionSet()` method, key bindings can be associated to the action via the InputManager.

Since:
  jsXe 0.5 pre1
Version:
  $Id$
Author:
  Ian Lewis (IanLewis@member.fsf.org)
See Also:
  `jsXe`, `ActionSet`, `InputManager`

Field Summary
`static String` | `INTERNAL_NAME` The internal name of the action used for retrieval from `jsXe.getAction(String)` and for storing properties related to the action.
`static String` | `MESSAGE_NAME` The message name of the action used to retrieve the localized human readable text for the action.
`static String` | `NAME` As an alternative to the MESSAGE_NAME an actual name can be used.
`static String` | `TOOLTIP_MESSAGE_NAME` The message name for the localized tooltip message that is associated with this action.

Constructor Summary
`LocalizedAction(String name)` Creates a new LocalizedAction that can be used with jsXe.

Method Summary
`String` | `getLabel()` Gets the human readable localized label for this action.
`String` | `getName()` Gets the internal name for this action.
`abstract void` | `invoke(TabbedView view, ActionEvent evt)` The method that is run when the action is invoked.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### INTERNAL_NAME

    public static final String INTERNAL_NAME

  The internal name of the action used for retrieval from `jsXe.getAction(String)` and for storing properties related to the action.

  See Also:
    Constant Field Values

### MESSAGE_NAME

    public static final String MESSAGE_NAME

  The message name of the action used to retrieve the localized human readable text for the action. The text is retrieved from the net.sourceforge.jsxe.Messages class. The text determines the menu key mnemonic as well.

  See Also:
    Constant Field Values

### NAME

    public static final String NAME

  As an alternative to the MESSAGE_NAME an actual name can be used. This should only be used in the case that the action's name is not locale specific, such as a file name or url.

  See Also:
    Constant Field Values

### TOOLTIP_MESSAGE_NAME

    public static final String TOOLTIP_MESSAGE_NAME

  The message name for the localized tooltip message that is associated with this action.

  See Also:
    Constant Field Values

Constructor Detail

### LocalizedAction

    public LocalizedAction(String name)

  Creates a new LocalizedAction that can be used with jsXe.

Parameters:
  `name` - the internal name of the action.

Method Detail

### invoke

    public abstract void invoke(TabbedView view,
                                ActionEvent evt)

  The method that is run when the action is invoked.

  Parameters:
    `view` - the view that invoked the action.
    `evt` - the ActionEvent for this event.

### getName

    public String getName()

  Gets the internal name for this action.

### getLabel

    public String getLabel()

  Gets the human readable localized label for this action. This returns the value of the property named by `getName()` suffixed with `.label`.

  Returns:
    the localized label
  See Also:
    `Messages`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD