I'm trying to implement drag-drop for live events:

$(".handle").live("dropped", func1);
$(".drop").live("dropon", func2);

I'm unable to get it working without needing to change jQuery, but not
significantly.  Are these types of patches still going to be accepted?

The problem is that an efficient drag plugin works differently than
submit / change.  It's not just filtering other events.  Instead it's
setting up a variety of events on elements other then the element
being delegated on, and modifying the element.

Here's my method:

1.  when event.special[dragstart|dragend|dragging].setup is called,
save a reference to your callback on the delegated element's data

2.  if you are the first event listening for a given selector,
delegate on mousedown for that selector

3.  When mousedown is called, listen on the document for mousemove and
mouseup

4.  On mousemove, call dragging handlers for the current selector,
update the position of the draggable.

5.  On mouseup, call dragend handlers for the current selector.

The problem is that I can't get the original event handler passed into
live (the proxy).  Can special.live.add add the proxy into the
liveHandler data?

data.liveProxy = proxy;

This is a very minor change, but will allow for a lot of special live
events.  Thanks.
-- 
You received this message because you are subscribed to the Google Groups 
"jQuery Development" group.
To post to this group, send email to jquery-...@googlegroups.com.
To unsubscribe from this group, send email to 
jquery-dev+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/jquery-dev?hl=en.


Reply via email to