Author: vkukharchuk
Date: 2007-09-05 05:09:23 -0400 (Wed, 05 Sep 2007)
New Revision: 2756
Added:
trunk/docs/userguide/en/src/main/docbook/included/dropListener.desc.xml
trunk/docs/userguide/en/src/main/docbook/included/dropListener.xml
Log:
http://jira.jboss.com/jira/browse/RF-809
Added: trunk/docs/userguide/en/src/main/docbook/included/dropListener.desc.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/dropListener.desc.xml
(rev 0)
+++ trunk/docs/userguide/en/src/main/docbook/included/dropListener.desc.xml 2007-09-05
09:09:23 UTC (rev 2756)
@@ -0,0 +1,22 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<section>
+ <sectioninfo>
+ <keywordset>
+ <keyword>dropListener</keyword>
+ </keywordset>
+ </sectioninfo>
+
+ <section>
+ <title>Description</title>
+ <para>The <emphasis
role="bold"><property><rich:dropListener></property></emphasis>
+ represents an action listener method that will be notified after drop operation.
+ </para>
+ </section>
+
+ <section>
+ <title>Key Features</title>
+ <itemizedlist>
+ <listitem>Allows to define some drop listeners for components with "Drag
and Drop" support</listitem>
+ </itemizedlist>
+ </section>
+</section>
Added: trunk/docs/userguide/en/src/main/docbook/included/dropListener.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/dropListener.xml
(rev 0)
+++ trunk/docs/userguide/en/src/main/docbook/included/dropListener.xml 2007-09-05 09:09:23
UTC (rev 2756)
@@ -0,0 +1,111 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<chapter>
+ <table>
+ <title>Component identification parameters </title>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>Name</entry>
+ <entry>Value</entry>
+ </row>
+ </thead>
+ <tbody>
+
+ <row>
+ <entry>listener-class</entry>
+ <entry>org.richfaces.event.DropListener</entry>
+ </row>
+ <row>
+ <entry>event-class</entry>
+ <entry>org.richfaces.event.DropEvent</entry>
+ </row>
+
+ <row>
+ <entry>tag-class</entry>
+ <entry>org.richfaces.taglib.DropListenerTag</entry>
+ </row>
+
+ </tbody>
+ </tgroup>
+ </table>
+
+
+ <section>
+ <title>Creating on a page</title>
+ <para>Simple Component definition on a page:</para>
+
+ <para>
+ <emphasis role="bold">Example:</emphasis>
+ </para>
+
+ <programlisting role="XML"><![CDATA[...
+ <rich:dropListener type="demo.Bean"/>
+...
+]]></programlisting>
+ </section>
+
+ <section>
+ <title>Dynamical creation of a component from Java code</title>
+ <para>
+ <emphasis role="bold">Example:</emphasis></para>
+ <programlisting role="JAVA"><![CDATA[package demo;
+
+public class ImplBean implements org.richfaces.event.DropListener{
+ ...
+}
+]]></programlisting>
+
+ <programlisting role="JAVA"><![CDATA[
+import demo.ImplBean;
+...
+ImplBean myListener = new ImplBean();
+...
+]]></programlisting>
+
+ </section>
+
+ <section>
+ <title>Key attributes and ways of usage</title>
+
+<para>
+The <property><rich:dropListener></property> is used as nested
tag with components like
+<property><rich:dropSupport></property>,
<property><rich:tree></property> and
<property><rich:treeNode></property>.
+</para>
+<para>
+Attribute
<emphasis><property>"type"</property></emphasis>
defines the fully qualified Java class name for listener.
+This class should implement org.richfaces.event.DropListener interface.
+</para>
+
+ <para>
+ <emphasis role="bold">The typical variant of
using:</emphasis>
+ </para>
+
+ <programlisting role="XML"><![CDATA[...
+<rich:panel style="width:100px;height:100px;">
+ <f:facet name="header">Drop Zone</f:facet>
+ <rich:dropSupport acceptedTypes="text">
+ <rich:dropListener type="demo.ListenerBean"/>
+ </rich:dropSupport>
+</rich:panel>
+...
+]]></programlisting>
+
+ <para>
+ <emphasis role="bold">Java bean source:</emphasis>
+ </para>
+
+ <programlisting role="JAVA"><![CDATA[package demo;
+
+import org.richfaces.event.DropEvent;
+
+public class ListenerBean implements org.richfaces.event.DropListener{
+...
+ public void processDrop(DropEvent arg0){
+ //Custom Developer Code
+ }
+...
+}
+]]></programlisting>
+ </section>
+
+</chapter>
\ No newline at end of file