explorers' club

explorations in dev, science, sci-fi, games, and other fun stuff!

Flex Drag n’ Drop Lib Docs uploaded


Again, just an update for the dNdLib docs:

dNdLib project home – link
dNdLib docs – link


3 thoughts on “Flex Drag n’ Drop Lib Docs uploaded

  1. Hi Justin,

    Thanks for all of your hard work on the dNdLib. It rocks!

    A couple questions though:

    1. How do I set the drag proxy source to the be the original object being dragged (in my case a button). I’d rather have a copy of the object than the default white box.

    2. I would like to capture the dragged items into an array. I would also like to create a reset function to remove all the dragged objects and return them to their originating container. How do I extend what you have done to add extra functionality for my own project? Everything is in the .swc.

    I am using buttons that are displayed through a repeater and bound to an arrayCollection as my data source.

    Any help is appreciated!


    P.S. From your bio, I see that you are into Maiden. I saw the Powerslave back in the day and it was one of the best shows I’ve ever seen.

    • 1. The drag proxy is hard coded at the moment. I had originally set it up to draw an image of the item being dragged but it had some issues when being ported over to Flex 3. You could easily grab the source code (for the time being) and modify it to you liking. At some point hopefully I will get around to adding a means to customize the drag image, just gotta find the time.

      2. The most recent release has the src, asdocs and SWC in it so you should be able to plug all that into your project and extend it. You can also grab the src from the SVN repo if you want the latest. As for returning the items to their original container, you could probably have an array storing references to all the original positions, then using the regular child methods APIs provided by Flex, you could just remove and add back to their respective owners. The dNdLib simply leverages the existing child method APIs, so it shouldn’t have any dependencies when manually adding/removing children.

      Yeah Maiden is one of my top 3 bands of all time. They, Telsa and Megadeth are(were for the latter 2) the triumvirate of metal. Powerslave is indeed a great album and they recently did their Somewhere Back in Time US tour which featured quite a bit of Powerslave. I highly recommend their last 3 albums if you haven’t checked them out in a while. Bruce is back. Up The Irons!!!!!

  2. Hi Justin,

    Thanks for the quick response. I grabbed all of your src, brought it into my project and started digging into it a bit.

    One quick success so far. I was able to trace out the label of my individual buttons in your onDragDrop method, which was cool.


    Maybe I’ll find a way to add these to an array afterall.

    Thanks for the tip on capturing the original coordinates. I’m a little unsure where to begin on that at the moment, but I’ll dig in tomorrow and see what happens.



Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s