Adobe Flex 3 Help

Performing a drag and drop

Drag and drop is event driven. To configure a component as a drag initiator or as a drop target, you have to write event handlers for specific events, such as the dragDrop and dragEnter events. For more information, see Manually adding drag-and-drop support.

For some components that you often use with drag and drop, Flex provides built-in event handlers to automate much of the drag and drop operation. These controls are all subclasses of the ListBase class, and are referred to as list-based controls. For more information, see Using drag-and-drop with list-based controls.

For a move operation, meaning you move the drag data from the drag initiator to the drop target, the list-based controls can handle all of the events required by a drag-and-drop operation. However, if you want to copy the drag data to the drop target, you have to write an event handler for both list-based and nonlist-based controls. For more information, see Moving and copying data.