Drag-n-Drop component

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Drag-n-Drop component

Emmanuel Sowah
Hi,

Does anyone has a drag and drop tapestry component to share? Are there plans
to integrate dojo's drag and drop javascript into core tapestry?
Or can someone give me some guidelines as to how to do this in tapestry with
Dojo's javascript?

Thanks,
Emmanuel
Reply | Threaded
Open this post in threaded view
|

Re: Drag-n-Drop component

Samuel Gendler
Well, at its simplest, you can just put straight dojo js code directly
in your template, a solution which requires absolutely no explicit
support from tapestry at all.

If you need the ability to reuse that code easily, then you could wrap
it up in a component, but nothing truly says you have to do that
(although it is generally recommended, if only for code leigibility
and maintenance reasons).  Without a tap component, you'll likely need
to update a hidden field or fields that you explicitly include in the
page at the time of the drop and/or fire off a request to a tapestry
service.  This things can also be done without explicit support from
tapestry. If you wrap your functionality up in a component, then you
can have your component template include the necessary hidden fields,
links, and forms. I don't know the specifics of dojo drag and drop, so
I can't steer you in the correct direction there.  If you just
implement it in a page using raw js code and hidden fields, you'll
likely discover quite quickly how it should be encapsulated into a
component.

--sam


On 12/7/06, Emmanuel Sowah <[hidden email]> wrote:

> Hi,
>
> Does anyone has a drag and drop tapestry component to share? Are there plans
> to integrate dojo's drag and drop javascript into core tapestry?
> Or can someone give me some guidelines as to how to do this in tapestry with
> Dojo's javascript?
>
> Thanks,
> Emmanuel
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]