Adobe Flex / as3: how to implement custom drag and drop pointers

Our product team requested custom cursors during drag and drop operations. They provided me with three images for implementation:

  • Open-Hand-Grabber.png : Displayed when the user hovers over an item that they can drag.
  • Closed-Hand-Grabber.png : item is being dragged
  • Closed capture-no-drop : item is dragged over an area where it cannot be dropped

I have included these images in my Flex application, and now I'm trying to implement the desired behavior.

My first thought was to listen to the drag / drop events and set the cursors using the CursorManager.setCursor () method. This solution seems very code intensive, and I believe there should be an easier way to hide the various states of the drag / drop cursor.

Any ideas?

+4
source share
1 answer

Browse the various cursor styles available in the DragManager class:

copyCursor

defaultDragImageSkin

linkCursor

moveCursor

rejectCursor

http://livedocs.adobe.com/flex/3/langref/mx/managers/DragManager.html

+5
source

All Articles