IPaletteAction Interface

com.bea.ide.actions
IPaletteAction Interface

public interface IPaletteAction

    extends IAction

Action to be performed on drop of an item from the palette. By default, this action will also be added to the document insert menu. It is expected that the action implementation will take into account current selection when performing its document insert.

Related Topics

IPaletteItem


All Known Implementing Classes
DefaultPaletteAction
All Superinterfaces
ActionListener, EventListener, IAction, PropertyChangeListener

Field Summary

public static final String
PROP_AddToMenu
Property that stores the boolean indicating whether this palette item should be added to the insert menu.
public static final String
PROP_DataFlavors
Property that stores the array of data flavors for this palette action.
 

Method Summary

public DataFlavor[]
getDataFlavors()
Optional array of DataFlavors identifying type of palette item this action will handle.
public boolean
showOnMenu()
Optional boolean indicating whether this action should be added to the insert menu as well as the palette.
 
Methods from interface java.awt.event.ActionListener
actionPerformed
 
Methods from interface com.bea.ide.actions.IAction
actionPerformed, propertyChange
 
Methods from interface java.beans.PropertyChangeListener
propertyChange
   

Field Detail

PROP_AddToMenu

public static final String PROP_AddToMenu
Property that stores the boolean indicating whether this palette item should be added to the insert menu.


PROP_DataFlavors

public static final String PROP_DataFlavors
Property that stores the array of data flavors for this palette action.

 

Method Detail

getDataFlavors() Method

public DataFlavor[] getDataFlavors()
Optional array of DataFlavors identifying type of palette item this action will handle. If this property is set, these data flavors will be exposed to drop target implementations during a drag and can be used to accept or reject the drag at the current cursor location.


showOnMenu() Method

public boolean showOnMenu()
Optional boolean indicating whether this action should be added to the insert menu as well as the palette. If this property is not set, an insert menu item will be added.