I've implemented draggable links before, but it required that I extend
the Draggable class, to enable this behavior. Basically it requires
overriding the endDrag method, but doing nothing in that method. Here
is example code:
YourNameSpace.Draggable = Class.create();
Object.extend(Object.extend(YourNameSpace.Draggable.prototype,
Draggable.prototype), {
endDrag: function(event) {
}
});
Then whenever you create a new draggable, instead of doing: new
Draggable(...) you should do: new YourNameSpace.Draggable(...)
I haven't tested this code though and no longer have a public website
that utilizes this feature, so there's no guarantee this will work as
desired.
-justin
On 4/13/07, arthur <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I'm trying do use drag&drop with items which are also links.
>
> I've seen on this mailing list, that is a recurent question for a long
> time :
>
> Draggable Link any solution available?
> <http://groups.google.com/group/rubyonrails-spinoffs/browse_thread/
> thread/2f4183d0c74a393d/d196a08ed93ada94>
>
> Is there somewhere an example in using mouseUp/mouseDown event and
> delay to differenciate a drag from a click ?
>
> If not, can someone explain it here, and perhaps I will make a little
> page to explain it (BTW do you know a good place to hold that page (in
> the google group, on the script.aculo.us wiki ?)
>
> I'm just beggining in javascript, so any help will be very
> appreciated !
>
> Arthur
>
>
> >
>
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---