| org.netbeans.modules.visualweb.palette.api.CodeClipDragAndDropHandler
CodeClipDragAndDropHandler | public class CodeClipDragAndDropHandler extends DragAndDropHandler (Code) | | |
Method Summary | |
public boolean | canDrop(Lookup targetCategory, DataFlavor[] flavors, int dndAction) Parameters: targetCategory - Lookup of the category under the drop cursor. Parameters: flavors - Supported DataFlavors. Parameters: dndAction - Drop action type. | public void | customize(ExTransferable exTransferable, Lookup lookup) Add your own custom DataFlavor as need to suppor drag-over a different
parts of editor area. | public boolean | doDrop(Lookup targetCategory, Transferable item, int dndAction, int dropIndex) Perform the drop operation and add the dragged item into the given category.
Parameters: targetCategory - Lookup of the category that accepts the drop. Parameters: item - Transferable holding the item being dragged. Parameters: dndAction - Drag'n'drop action type. Parameters: dropIndex - Zero-based position where the dragged item should be dropped. |
CodeClipDragAndDropHandler | public CodeClipDragAndDropHandler()(Code) | | Creates a new instance of CodeClipDragAndDropHandler
|
canDrop | public boolean canDrop(Lookup targetCategory, DataFlavor[] flavors, int dndAction)(Code) | | Parameters: targetCategory - Lookup of the category under the drop cursor. Parameters: flavors - Supported DataFlavors. Parameters: dndAction - Drop action type. True if the given category can accept the item being dragged. |
customize | public void customize(ExTransferable exTransferable, Lookup lookup)(Code) | | Add your own custom DataFlavor as need to suppor drag-over a different
parts of editor area.
Parameters: t - Item's default Transferable. Parameters: item - Palette item's Lookup. |
doDrop | public boolean doDrop(Lookup targetCategory, Transferable item, int dndAction, int dropIndex)(Code) | | Perform the drop operation and add the dragged item into the given category.
Parameters: targetCategory - Lookup of the category that accepts the drop. Parameters: item - Transferable holding the item being dragged. Parameters: dndAction - Drag'n'drop action type. Parameters: dropIndex - Zero-based position where the dragged item should be dropped. True if the drop has been successful, false otherwise. |
|
|