Thank you, excellent solution. I should have thought of that. However,
it still seems odd that Draggables does not have a .remove(element)
method like Droppables.

On Sep 22, 3:07 pm, Matt Foster <[EMAIL PROTECTED]> wrote:
> element.dragHandle = new Draggable(element, { //bla });
> When the element comes into your method, just reference the dragHandle
> property.
> On Sep 22, 9:45 am, Grego <[EMAIL PROTECTED]> wrote:
> > I see you are talking about the onDrop callback of Droppables, which
> > is documented at
> > I was reacting to the documentation 
> > at
> > in which the example shows a new draggable being created followed by
> > the following lines...
> > // then destroy it when you don't need it anymore
> > mydrag.destroy();
> > ... which caused me to think that - oh new draggables should be
> > cleaned up when we are done with them. Now, for me, if I create an
> > object through an API, and cleanup is expected, then I expect the API
> > to provide a cleanup method. This way I know internal structures
> > within the API are properly updated. If I remove the draggable
> > directly from the dom then internal Draggables structures will
> > reference an element that no longer exists.
> > To me, it looks like the method provided by the API, 'destroy',
> > requires information (the draggable handle) which is not conveniently
> > available - hence my suggestion for an API cleanup method that can
> > work with information that is conveniently available at drop time -
> > namely the element.
You received this message because you are subscribed to the Google Groups 
"Prototype &" group.
To post to this group, send email to
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at

Reply via email to