Use gwt-dnd with UIBinder

64 views
Skip to first unread message

pascal

unread,
Aug 15, 2014, 9:32:44 AM8/15/14
to gwt...@googlegroups.com
Hi,
i am working on a project using gwtp and gwtbootstrap3. I read the getting started guide and checked some examples, but i am still not sure if its possible and if yes, how to use gwt-dnd with uibinder. It would be great, if you can give me some hints or examples how to use them.
Cheers :-)
pascal  

Asier Cd.

unread,
Nov 3, 2014, 7:53:14 AM11/3/14
to gwt...@googlegroups.com
Hi

It's very easy. In your .xml file add the boundary panel and the widget container

      <g:AbsolutePanel ui:field="boundaryPanel" addStyleNames="mt10 mb10">
       
<g:ScrollPanel addStyleNames="{style.scrollPanel}">
         
<g:VerticalPanel ui:field="containerPanel" spacing="2"/>
       
</g:ScrollPanel>
     
</g:AbsolutePanel>


Then, in your view create the drag controller, the handler, the container and the drop controller, as shown in the examples.

You can initialize them in your view's constructor or defer it's creation to another method called from your presenter if you need to access the UiHandlers.

Regards.
Reply all
Reply to author
Forward
0 new messages