On Sep 13, 2007, at 12:42 PM, [EMAIL PROTECTED] wrote:

> So...in doing a bit more searching on this list, it appears that I'm
> not alone in having issues with drag-n-drop between scrollable divs.
> Has anyone found a relatively painless solution for this?

I've done it. It involves working around the CSS issue that's at the  
root of your trouble. Instead of making the two lists sortable, just  
create two droppables. Observe the mousedown; when it occurs, move  
the selected element higher up the dom tree, outside of the  
overflow:scroll element, and create the Draggable "just in time".  
(This will involve giving it a "kick-start". Check dragdrop.js for  
which functions should be called on mousedown, which has already  
happened.) Destroy the draggable when it's dropped. There may be  
other issues to work out (like revert--although you can get around  
this by dragging a ghost instead of the original), but it'll work.

> Barring that, it appears that drag-n-drop just isn't going to be a
> very practical solution for this. I'll likely revert to a list of
> items as checkboxes with a 'move checked items to other list' button.

Instead of doing checkboxes/submit button, make it "one click." Put a  
">>" icon on each item, and make it a one-step process. If I had to  
do the project over (with the solution I used above), I might do it  
this way.  If you only have a single drop location, I suspect a one- 
click solution would be more useable. (This method might also be  
preferred if your list items are sorted.)


TAG

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to