-
1. Re: Help with drag 'n drop
ilya_shaikovsky Sep 28, 2007 7:24 AM (in response to parki)Hmm.. demosite is designed specially to gave you simple example. You may download it and explore. Or you may try develpoers samples. All the svn links - in the wiki.
-
2. Re: Help with drag 'n drop
parki Sep 28, 2007 11:44 AM (in response to parki)Thanks Ilya - getting closer to things working - I now have a draggable component and can drop it on something else.
<h:form>
<h:panelGrid id="drag1">
<rich:dragSupport dragType="singleItems" />
<h:outputText value="Drag Me" />
</h:panelGrid>
<rich:panel styleClass="dropTargetPanel">
<f:facet name="header">
<h:outputText value="Drop" />
</f:facet>
<rich:dropSupport acceptedTypes="singleItems" ondrop="handle_drop()" />
</rich:panel>
</h:form>
Using the 'ondrop' attribute I see how to invoke a JavaScript function - can you point me to info on how to set up a Bean invocation using the 'dropListener' attribute - I'm a bit stumped here - pointing me to some docs would be great.
Thanks a bunch.
parki... -
3. Re: Help with drag 'n drop
ilya_shaikovsky Oct 1, 2007 6:58 AM (in response to parki)You should not perform anything special at client side. The request will be fired by framework itself after the dragged element with propper type will be dropped to corresponding zone.
in the Drop Listener you only need to specify the listener method from your bean. Once again I suggest you to use demosite, All the functionallity shown there with code snapshots. You may download and try freelly -
4. Re: Help with drag 'n drop
parki Oct 1, 2007 4:52 PM (in response to parki)HI Ilya:
Got everything working - very cool. I read a bit more background material on JSF in general, and it clarified what I was trying to do.
Thanks - this is fine looking stuff.
Regards,
parki...