Tip
For a really practical example of drag-and-drop at work, be
sure to check out ""Drag-and-Drop with the Tree" in Chapter 15, where drag-and-drop is applied to
the problem of manipulating the Tree
dijit. The Tree
is a phenomenal piece of engineering
and dnd
only makes it
better!
After reading this chapter, you should be able to:
Construct unconstrained
Moveable
objects and drag them around on the screenDefine constraints for
Moveable
objects to control their behaviorBe able to implement
Source
andTarget
containers to create collections of items that can be dragged and dropped to/from/within one anotherCreate custom avatars to communicate with the user when a drop operation is about to occur
Use
dojo.connect
anddojo.subscribe
to receive event notifications for drag-and-drop objects
Next, we'll cover animation and special effects.
Get Dojo: The Definitive Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.