JBoss Rich Faces SVN: r13703 - in trunk/docs/realworld_app_guide/en/src/main/docbook: modules and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: atsebro
Date: 2009-04-20 11:41:57 -0400 (Mon, 20 Apr 2009)
New Revision: 13703
Modified:
trunk/docs/realworld_app_guide/en/src/main/docbook/master.xml
trunk/docs/realworld_app_guide/en/src/main/docbook/modules/hiw.xml
Log:
RF-5768: Real World Demo Application Tutorial Update for 3.3.1 release
Modified: trunk/docs/realworld_app_guide/en/src/main/docbook/master.xml
===================================================================
--- trunk/docs/realworld_app_guide/en/src/main/docbook/master.xml 2009-04-20 15:41:34 UTC (rev 13702)
+++ trunk/docs/realworld_app_guide/en/src/main/docbook/master.xml 2009-04-20 15:41:57 UTC (rev 13703)
@@ -4,6 +4,7 @@
<!ENTITY intro SYSTEM "modules/intro.xml">
<!ENTITY application_overview SYSTEM "modules/application_overview.xml">
<!ENTITY getting_started SYSTEM "modules/getting_started.xml">
+ <!ENTITY hiw SYSTEM "modules/hiw.xml">
]>
@@ -32,9 +33,9 @@
</bookinfo>
<toc/>
&intro;
- &application_overview;
+ &application_overview;
&getting_started;
-
+ &hiw;
</book>
Modified: trunk/docs/realworld_app_guide/en/src/main/docbook/modules/hiw.xml
===================================================================
--- trunk/docs/realworld_app_guide/en/src/main/docbook/modules/hiw.xml 2009-04-20 15:41:34 UTC (rev 13702)
+++ trunk/docs/realworld_app_guide/en/src/main/docbook/modules/hiw.xml 2009-04-20 15:41:57 UTC (rev 13703)
@@ -12,9 +12,9 @@
<section>
<title>Used components</title>
- <para>Below there is a list of components used in "Photo album".</para>
+ <para>Below there is a list of components used in <property>Photo Album Demo</property>.</para>
<table>
- <title>Components used in "Photo album"</title>
+ <title>Components used in "Photo Album Demo"</title>
<tgroup cols="2">
<thead>
<row>
@@ -90,4 +90,323 @@
</table>
</section>
+ <section>
+ <title>Albums representation</title>
+
+ <section>
+ <title>Building the <rich:tree> on the page</title>
+
+ <para>
+ The <emphasis role="bold"><property><rich:tree></property></emphasis> component is designed for hierarchical data presentation and is used to build a tree structure. The component also supports built-in drag and drop functionality.
+ </para>
+ <para>
+ The <emphasis role="bold"><property><rich:tree></property></emphasis> component in the <property>Photo Album Demo</property> application helps to represent and implement inherently the "Shelves—Albums—Photos" hierarchy.
+ Shelf is the highest possible level in the tree hierarchy.
+ Shelfs are used to group thematic albums and may contain as many albums as needed.
+ Photos are not represented in the tree because it can be a great number of them and it can make a tree clumsy.
+ Photos are rendered in the center of the screen (hereinafter referred to as a watching area).
+ </para>
+
+ <para>
+ Implicitly, the <emphasis role="bold"><property><rich:tree></property></emphasis> component takes one the main place in the <property>Photo Album Demo</property> and is tightly bounded with the application logic.
+ There are several ways to implement the <emphasis role="bold"><property><rich:tree></property></emphasis>.
+ In the current application the <emphasis role="bold"><property><rich:tree></property></emphasis> is designed using a model tag <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis>.
+ </para>
+ <para>
+ The <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> component accepts a collection of elements, which are allowed to include lists, arrays, maps, XML NodeList or NamedNodeMap, and iterates through it.
+ The <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> component repeats a hierarchical tree structure on a <code>xhtml</code> or <code>jsp</code> page in a component tree and can be nested without any limitations.
+ The code snippet below schematically shows the idea of how a tree can be built on a page with the help of adaptors:
+ </para>
+
+ <programlisting role="XML"><![CDATA[<rich:tree>
+ <rich:treeNodesAdaptor>
+ <rich:treeNode />
+
+ <rich:treeNodesAdaptor>
+ <rich:treeNode />
+
+ <rich:treeNodesAdaptor>
+ <rich:treeNode />
+ ...
+ </rich:treeNodesAdaptor>
+ </rich:treeNodesAdaptor>
+ </rich:treeNodesAdaptor>
+</rich:tree>]]></programlisting>
+
+ <para>
+ When using <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> component there is no need to specify
+ the <emphasis><property>"value"</property></emphasis> and <emphasis><property>"var"</property></emphasis> attributes for the <emphasis role="bold"><property><rich:tree></property></emphasis>.
+ The values for nodes to render are passed directly into the corresponding adaptor and the component performs all the necessary iterative work
+ (vizit the <ulink url="http://livedemo.exadel.com/richfaces-demo/richfaces/treeNodesAdaptor.jsf?..."><rich:treeNodesAdaptor> page</ulink> on the RichFacesLiveDemo for more details).
+ </para>
+
+ <para>
+ Implementation of the <emphasis role="bold"><property><rich:tree></property></emphasis> in the application is very close to the model shown above.
+ The <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> component has <nodes> attribute.
+ The top <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> in the <emphasis role="bold"><property><rich:tree></property></emphasis> in the Phot Album Demo application is responsible for shelfs rendering.
+ Its <emphasis><property>"nodes"</property></emphasis> attribute refers to <emphasis><property>getShelfs()</property></emphasis> method of the <code>ShelfManager</code> class and gets the collection of shelfs associated with the current user including all shared shelfs in the system.
+ Take a look at this method:
+ </para>
+
+ <programlisting role="JAVA"><![CDATA[public List<Shelf> getShelfs(){
+ if(shelfs == null){
+ shelfs = shelfAction.getShelfs(user);
+ }
+ return shelfs;
+} ]]></programlisting>
+
+ <para>
+ After the <emphasis><property>"nodes"</property></emphasis> attribute of the <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis>, which is responsible for shelves rendering, receives the collection of shelves,
+ the iteration process switches to the nested <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis>, which is responsible for albums.
+ The "albums" <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> <emphasis><property>"nodes"</property></emphasis> attribute refers in its turn to the <code>albums</code> field of the <code>Shelf</code> class
+ and takes a collection of all albums associated with the current shelf.
+ The "albums" <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> renders all albums that belong to the current iterating shelf and then switches back to the "shelf" <emphasis role="bold"><property><rich:treeNodesAdaptor></property></emphasis> to render and iterate the next shelf in the shelves collection received earlier.
+ Here is how it looks in the <code>webapp/includes/index/tree.xhtml</code> file:
+ </para>
+
+ <programlisting role="XML"><![CDATA[<rich:tree id="tree" switchType="client" treeNodeVar="treeNode" showConnectingLines="false" dragIndicator="dragIndicator" ajaxSubmitSelection="false"
+ adviseNodeOpened="#{treeManager.adviseNodeSelected}"
+ adviseNodeSelected="#{treeManager.adviseNodeSelected}"
+ iconCollapsed="/img/shell/tree_icon_plus.png"
+ iconExpanded="/img/shell/tree_icon_minus.png">
+ <rich:treeNodesAdaptor nodes="#{shelfManager.getShelfs()}" var="shelf">
+ <rich:treeNode reRender="mainArea" selectedClass="tree-selected-node">
+ <f:facet name="icon">
+ <h:graphicImage style="border: none" value="/img/shell/tree_icon_shelf.png">
+ <a4j:support reRender="tree, mainArea" event="onclick" actionListener="#{controller.showShelf(shelf)}" similarityGroupingId="sel" />
+ </h:graphicImage>
+ </f:facet>
+ <rich:dropSupport id="shelfDND" acceptedTypes="album" dropValue="#{shelf}" dropListener="#{dndManager.processDrop}" reRender="mainArea, tree" />
+ <ui:include src="/includes/contextMenu/CMForShelf.xhtml" >
+ <ui:param name="shelf" value="#{shelf}" />
+ </ui:include>
+ <a4j:outputPanel>
+ <h:outputText value="#{shelf.name}" />
+ <h:outputText value=" :: " />
+ <strong>#{shelf.unvisitedImages.size()}</strong> new
+ <a4j:support reRender="tree, mainArea" event="onclick" actionListener="#{controller.showShelf(shelf)}" similarityGroupingId="sel" />
+ </a4j:outputPanel>
+ </rich:treeNode>
+
+ <rich:treeNodesAdaptor var="album" nodes="#{shelf.albums}">
+ <rich:treeNode reRender="mainArea" dragType="album" dragValue="#{album}" dropValue="#{album}" acceptedTypes="image, album"
+ selectedClass="tree-selected-node" icon="img/shell/tree_icon_album.png">
+ <f:facet name="iconLeaf">
+ <h:graphicImage style="border: none" value="img/shell/tree_icon_album.png">
+ <a4j:support reRender="tree, mainArea" event="onclick" actionListener="#{controller.showAlbum(album)}" similarityGroupingId="sel" />
+ </h:graphicImage>
+ </f:facet>
+ <ui:include src="/includes/contextMenu/CMForAlbum.xhtml" >
+ <ui:param name="album" value="#{album}" />
+ </ui:include>
+ <rich:dndParam name="label" type="drag" value="#{album.name}" />
+ <a4j:outputPanel>
+ <h:outputText value="#{album.name}" />
+ <h:outputText value=" :: " />
+ <strong>#{album.unvisitedImages.size()}</strong> new
+ <a4j:support reRender="tree, mainArea" event="onclick" actionListener="#{controller.showAlbum(album)}" similarityGroupingId="sel" />
+ </a4j:outputPanel>
+ <rich:dropSupport id="php" acceptedTypes="image" dropValue="#{album}" dropListener="#{dndManager.processDrop}" reRender="mainArea, tree" />
+ </rich:treeNode>
+ </rich:treeNodesAdaptor>
+ </rich:treeNodesAdaptor>
+</rich:tree>]]></programlisting>
+
+ <para>
+ The illustration below shows how the Shelves—Albums heirarchy is rendered on the page.
+ </para>
+
+ <figure>
+ <title>Shelves and albums nodes rendered with the help of the <rich:treeNodesAdaptor></title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/tree.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+</section>
+
+ <section>
+ <title>Drag-and-drop inside the <rich:tree></title>
+ <para>
+ Drag and drop features supported in the Photo Album Demo application are not so complicated as it may seem from the first view.
+ In this application we can mark out two types of drag-and-drop: one type takes place only inside the tree (between tree nodes) and another one — between the watching area and the tree.
+ The difference is not considerable enough to describe two types separately, but also not at all insignificant to be omitted here.
+ </para>
+
+ <para>
+ Let's examine drag-and-drop inside tree. The tree related components (<emphasis role="bold"><property><rich:tree></property></emphasis> and <emphasis role="bold"><property><rich:treeNode></property></emphasis>)
+ have their own attributes that provide drag-and-drop functionality. These attributes can be divided into two groups: those which provide drag (dragValue, dragListener, dragIndicator, dragType attributes) and those which provide drop operations (dropValue, dropListener, acceptedTypes, typeMapping).
+ </para>
+
+ <note>
+ <title>
+ Note:
+ </title>
+ <para>
+ Due to "Shelves—Albums—Photos" paradigm we can say that photos could be moved between albums, albums could be moved between shelves.
+ To avoid a mishmash, it's not allowed to place photos directly in shelves as well as nesting shelves inside shelves or albums inside albums.
+ </para>
+ </note>
+
+ <para>
+ All albums or images (<property>drag-and-drop zones</property> in terms of RichFaces drag-and-drop), which are assumed to be dragged, must be marked somehow in the application code.
+ For albums that are represented as tree nodes we will use previously mentioned <property>drag group</property> attributes:
+ </para>
+ <programlisting role="XML"><![CDATA[<rich:treeNodesAdaptor var="album" nodes="#{shelf.albums}">
+ <rich:treeNode dragType="album"
+ dragValue="#{album}"
+ dropValue="#{album}"
+ acceptedTypes="image, album" />
+ …
+</rich:treeNodesAdaptor>
+]]></programlisting>
+
+ <para>
+ To provide drop functionality for the marked albums we should mark shelves as drop zones in the application code too.
+ For this purpose we add the <emphasis role="bold"><property>rich:dropSupport</property></emphasis> component to the "shelf" node:
+ </para>
+ <programlisting role="XML"><![CDATA[<rich:treeNodesAdaptor nodes="#{shelfManager.getShelfs()}" var="shelf">
+ <rich:treeNode
+ <rich:dropSupport id="shelfDND"
+ acceptedTypes="album"
+ dropValue="#{album}"
+ dropListener="#{dndManager.processDrop}"
+ reRender="mainArea">
+ </rich:dropSupport>
+ …
+ </rich:treeNode>
+</rich:treeNodeAdaptor>]]></programlisting>
+
+ <para>
+ The <emphasis><property>"acceptedType"</property></emphasis> attribute tells the "shelf" node what types of dragged zones (albums in this case) it can accept.
+ The value for the <emphasis><property>"acceptedType"</property></emphasis> attribute corresponds the album <emphasis><property>"dragType"</property></emphasis> attribute.
+ The method binding that will process drag-and-drop operation should be pointed via <emphasis><property>"dropListener"</property></emphasis> attribute of the <emphasis role="bold"><property>rich:tree</property></emphasis>.
+ This method is shown in th e listing below:
+ </para>
+ <programlisting role="JAVA"><![CDATA[...
+public void processDrop(DropEvent dropEvent) {
+ Dropzone dropzone = (Dropzone) dropEvent.getComponent();
+ Object dragValue = dropEvent.getDragValue();
+ Object dropValue = dropzone.getDropValue();
+ if(dragValue instanceof Image){
+ if(!((Album)dropValue).getOwner().getLogin().equals(user.getLogin())){
+ Events.instance().raiseEvent(Constants.ADD_ERROR_EVENT, Constants.DND_PHOTO_ERROR);
+ return;
+ }
+ handleImage((Image)dragValue, (Album)dropValue);
+ }else if(dragValue instanceof Album){
+ if(!((Shelf)dropValue).getOwner().getLogin().equals(user.getLogin())){
+ Events.instance().raiseEvent(Constants.ADD_ERROR_EVENT, Constants.DND_ALBUM_ERROR);
+ return;
+ }
+ handleAlbum((Album)dragValue, (Shelf)dropValue);
+ }
+}
+...]]></programlisting>
+ <para>
+ The illustration below shows how the described above drag-and-drop features are rendered in the Photo Album Demo.
+ </para>
+ <figure>
+ <title>Dragging the "Flora" album from "Sport" shelf into the "Nature" (left) and the tree after drag-and-drop (right).</title>
+ <mediaobject>
+ <imageobject>
+ <imagedata fileref="images/dnd.png"/>
+ </imageobject>
+ </mediaobject>
+ </figure>
+
+ </section>
+
+ </section>
+
+ <section>
+ <title>Upload images</title>
+ <para>The implementation of <emphasis role="bold"><property><rich:fileUpload></property></emphasis> in the Phot Album Demo uses the embedded Flash module that adds extra functionality to the component.
+ Here are the additional features that the Flash module provides:
+ </para>
+ <itemizedlist>
+ <listitem><para>Multiple files choosing;</para></listitem>
+ <listitem><para>Specification of permitted file types in the "Open File" dialog window;</para></listitem>
+ <listitem><para>A number of additional entry object properties.</para></listitem>
+ </itemizedlist>
+
+ <para>
+ The photos uploading functionality is realized on the <code>/includes/fileUpload/fileUploader.xhtml page</code>. Let's have a look at this page to find out how the uploader is imlemented:
+ </para>
+
+ <programlisting role="XML"><![CDATA[<rich:fileUpload style="margin : 0px 0px 20px 0px; width : 504px; height : 200px; background : #f1f1f1; border : 1px solid #A1A1A1"
+ id="fileUpload"
+ allowFlash="true"
+ immediateUpload="false"
+ acceptedTypes="jpg,jpeg"
+ maxFilesQuantity="100"
+ autoclear="true"
+ fileUploadListener="#{fileUploadManager.listener}" >
+ <a4j:support event="onuploadcomplete" reRender="filesPanel, tree" />
+ <a4j:support event="onfileuploadcomplete" />
+ </rich:fileUpload>]]></programlisting>
+
+ <para>
+ The "<emphasis><property>FileUploadListener</property></emphasis>" attribute is binded with <code>fileUploadManager.listener</code> method which makes the main job on the upload.
+ Below is the <code>fileUploadManager.listener</code> method:
+ </para>
+ <programlisting role="JAVA"><![CDATA[public void listener(UploadEvent event) throws Exception {
+ UploadItem item = event.getUploadItem();
+ Image image = constructImage(item);
+ try {
+ extractMetadata(item, image);
+ } catch (Exception e1) {
+ addError(item, image, Constants.FILE_PROCESSING_ERROR);
+ return;
+ }
+ image.setAlbum(model.getSelectedAlbum());
+ if(image.getAlbum() == null){
+ addError(item, image, Constants.NO_ALBUM_TO_DOWNLOAD_ERROR);
+ return;
+ }
+ try{
+ if(imageAction.isImageWithThisPathExist(image)){
+ image.setPath(generateNewPath(image.getPath()));
+ }
+ imageAction.addImage(image);
+ }catch(Exception e){
+ addError(item, image, Constants.IMAGE_SAVING_ERROR);
+ return;
+ }
+ if(!fileManager.addImage(image.getFullPath(), item.getFile().getPath())){
+ addError(item, image, Constants.FILE_SAVE_ERROR);
+ return;
+ }
+ fileWrapper.getFiles().add(image);
+ Events.instance().raiseEvent(Constants.IMAGE_ADDED_EVENT, image);
+ item.getFile().delete();
+}]]></programlisting>
+
+<para>
+ When a photo is added into the uploader, the first thing it does is saving this photo in the file system.
+ The uploaded files are stored in the temporary folder in the computer file system.
+ For this purpose the value of the <code>createTempFile</code> parameter in <code>Ajax4jsf Filter</code> section should be set to <code>true</code>.
+ Below in the <code>Web.xml</code> file Ajax filter section:
+</para>
+
+ <programlisting role="XML"><![CDATA[...
+<init-param>
+ <param-name>createTempFiles</param-name>
+ <param-value>true</param-value>
+</init-param>
+...]]></programlisting>
+
+ <para>
+ Then the uploader creates an <code>Image</code> object and extracts all image metadata such as Camera name, Image size etc.
+ Then it sets an album and generates a new path to it.
+ The system should save six different sizes of the photo.
+ After the photo was added into the data base the system removes a temporary file created for storage.
+ </para>
+
+
+ </section>
+
+
</chapter>
15 years, 9 months
JBoss Rich Faces SVN: r13702 - trunk/docs/realworld_app_guide/en/src/main/resources/images.
by richfaces-svn-commits@lists.jboss.org
Author: atsebro
Date: 2009-04-20 11:41:34 -0400 (Mon, 20 Apr 2009)
New Revision: 13702
Added:
trunk/docs/realworld_app_guide/en/src/main/resources/images/dnd.png
trunk/docs/realworld_app_guide/en/src/main/resources/images/tree.png
Log:
RF-5768: Real World Demo Application Tutorial Update for 3.3.1 release
Added: trunk/docs/realworld_app_guide/en/src/main/resources/images/dnd.png
===================================================================
(Binary files differ)
Property changes on: trunk/docs/realworld_app_guide/en/src/main/resources/images/dnd.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/docs/realworld_app_guide/en/src/main/resources/images/tree.png
===================================================================
(Binary files differ)
Property changes on: trunk/docs/realworld_app_guide/en/src/main/resources/images/tree.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
15 years, 9 months
JBoss Rich Faces SVN: r13701 - trunk/ui/pickList/src/main/java/org/richfaces/component.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2009-04-20 11:17:31 -0400 (Mon, 20 Apr 2009)
New Revision: 13701
Modified:
trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java
Log:
https://jira.jboss.org/jira/browse/RF-6865
Modified: trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java
===================================================================
--- trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java 2009-04-20 14:58:26 UTC (rev 13700)
+++ trunk/ui/pickList/src/main/java/org/richfaces/component/UIPickList.java 2009-04-20 15:17:31 UTC (rev 13701)
@@ -95,7 +95,7 @@
public String getAsString(FacesContext context, UIComponent component,
Object value) {
- return (String) value;
+ return value != null ? value.toString() : "";
}
};
15 years, 9 months
JBoss Rich Faces SVN: r13700 - trunk/cdk/maven-archetype-theme/src/main/resources/archetype-resources.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2009-04-20 10:58:26 -0400 (Mon, 20 Apr 2009)
New Revision: 13700
Modified:
trunk/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml
Log:
Theme archetype: JSF dependencies added
Modified: trunk/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml
===================================================================
--- trunk/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml 2009-04-20 14:55:55 UTC (rev 13699)
+++ trunk/cdk/maven-archetype-theme/src/main/resources/archetype-resources/pom.xml 2009-04-20 14:58:26 UTC (rev 13700)
@@ -48,5 +48,20 @@
<artifactId>richfaces-impl</artifactId>
<version>3.3.1-SNAPSHOT</version>
</dependency>
+
+ <!-- Required for JSF -->
+ <dependency>
+ <groupId>javax.el</groupId>
+ <artifactId>el-api</artifactId>
+ <version>1.0</version>
+ <scope>provided</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>javax.faces</groupId>
+ <artifactId>jsf-api</artifactId>
+ <version>1.2_12</version>
+ <scope>provided</scope>
+ </dependency>
</dependencies>
</project>
15 years, 9 months
JBoss Rich Faces SVN: r13699 - trunk/test-applications/richfaces-docs/web/src/main/webapp.
by richfaces-svn-commits@lists.jboss.org
Author: msorokin
Date: 2009-04-20 10:55:55 -0400 (Mon, 20 Apr 2009)
New Revision: 13699
Modified:
trunk/test-applications/richfaces-docs/web/src/main/webapp/richPage.xhtml
Log:
updated the file
Modified: trunk/test-applications/richfaces-docs/web/src/main/webapp/richPage.xhtml
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/webapp/richPage.xhtml 2009-04-20 14:55:34 UTC (rev 13698)
+++ trunk/test-applications/richfaces-docs/web/src/main/webapp/richPage.xhtml 2009-04-20 14:55:55 UTC (rev 13699)
@@ -6,7 +6,7 @@
<rich:page sidebarPosition="left" sidebarWidth="300"
- theme="simple" title="advisory" markupType="" pageTitle="Gleb is back" contentType="text/html; charset=UTF-8" >
+ theme="" title="advisory" markupType="" pageTitle="Gleb is back" contentType="text/html; charset=UTF-8" >
<f:facet name="pageHeader" >
<title>Page Title 2</title>
@@ -19,11 +19,23 @@
</ui:include>
</f:facet>
+
+ <f:facet name="subheader" >
+<p>Subheader</p>
+
+ </f:facet>
<f:facet name="sidebar">
<ui:include src="layout/mainMenu.xhtml" />
</f:facet>
<p>body content</p>
+ <ul>
+<li>Some text</li>
+<li>Some text</li>
+<li>Some text</li>
+<li>Some text</li>
+<li>Some text</li>
+ </ul>
<f:facet name="footer">
footer content
15 years, 9 months
JBoss Rich Faces SVN: r13698 - trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF.
by richfaces-svn-commits@lists.jboss.org
Author: msorokin
Date: 2009-04-20 10:55:34 -0400 (Mon, 20 Apr 2009)
New Revision: 13698
Removed:
trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/.pages.xml.spdia
Modified:
trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/
trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/components.xml
trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/faces-config.xml
trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/web.xml
Log:
updated files
Property changes on: trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF
___________________________________________________________________
Name: svn:ignore
+ .faces-config.xml.jsfdia
Deleted: trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/.pages.xml.spdia
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/.pages.xml.spdia 2009-04-20 14:54:12 UTC (rev 13697)
+++ trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/.pages.xml.spdia 2009-04-20 14:55:34 UTC (rev 13698)
@@ -1,59 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<diagram model-entity="SeamPagesDiagram">
- <item ID="*" NAME="*" PATH="*" SHAPE="24,17,0,0" TYPE="page" model-entity="SeamPagesDiagramItem">
- <output ID="/home.xhtml" NAME="output" PATH="/home.xhtml"
- TARGET="#xhome.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item ID="org.jboss.seam.framework.EntityNotFoundException"
- NAME="exception:org.jboss.seam.framework.EntityNotFoundException"
- PATH="org.jboss.seam.framework.EntityNotFoundException"
- SHAPE="24,121,0,0" TYPE="exception" model-entity="SeamPagesDiagramItem">
- <output ID="/error.xhtml" NAME="output" PATH="/error.xhtml"
- TARGET="#xerror.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item ID="javax.persistence.EntityNotFoundException"
- NAME="exception:javax.persistence.EntityNotFoundException"
- PATH="javax.persistence.EntityNotFoundException" SHAPE="24,225,0,0"
- TYPE="exception" model-entity="SeamPagesDiagramItem">
- <output ID="/error.xhtml" NAME="output" PATH="/error.xhtml"
- TARGET="#xerror.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item ID="javax.persistence.OptimisticLockException"
- NAME="exception:javax.persistence.OptimisticLockException"
- PATH="javax.persistence.OptimisticLockException" SHAPE="24,329,0,0"
- TYPE="exception" model-entity="SeamPagesDiagramItem">
- <output ID="/error.xhtml" NAME="output" PATH="/error.xhtml"
- TARGET="#xerror.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item ID="org.jboss.seam.security.AuthorizationException"
- NAME="exception:org.jboss.seam.security.AuthorizationException"
- PATH="org.jboss.seam.security.AuthorizationException"
- SHAPE="24,433,0,0" TYPE="exception" model-entity="SeamPagesDiagramItem">
- <output ID="/error.xhtml" NAME="output" PATH="/error.xhtml"
- TARGET="#xerror.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item ID="org.jboss.seam.security.NotLoggedInException"
- NAME="exception:org.jboss.seam.security.NotLoggedInException"
- PATH="org.jboss.seam.security.NotLoggedInException" SHAPE="24,745,0,0"
- TYPE="exception" model-entity="SeamPagesDiagramItem">
- <output ID="/login.xhtml" NAME="output" PATH="/login.xhtml"
- TARGET="#xlogin.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item ID="javax.faces.application.ViewExpiredException"
- NAME="exception:javax.faces.application.ViewExpiredException"
- PATH="javax.faces.application.ViewExpiredException" SHAPE="24,537,0,0"
- TYPE="exception" model-entity="SeamPagesDiagramItem">
- <output ID="/error.xhtml" NAME="output" PATH="/error.xhtml"
- TARGET="#xerror.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item NAME="exception:" SHAPE="24,641,0,0" TYPE="exception" model-entity="SeamPagesDiagramItem">
- <output ID="/error.xhtml" NAME="output" PATH="/error.xhtml"
- TARGET="#xerror.xhtml" model-entity="SeamPagesDiagramItemOutput"/>
- </item>
- <item NAME="#xhome.xhtml" PATH="/home.xhtml" SHAPE="344,17,0,0"
- TYPE="page" model-entity="SeamPagesDiagramItem"/>
- <item NAME="#xlogin.xhtml" PATH="/login.xhtml" SHAPE="344,745,0,0"
- TYPE="page" model-entity="SeamPagesDiagramItem"/>
- <item NAME="#xerror.xhtml" PATH="/error.xhtml" SHAPE="472,121,0,0"
- TYPE="page" model-entity="SeamPagesDiagramItem"/>
-</diagram>
Modified: trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/components.xml
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/components.xml 2009-04-20 14:54:12 UTC (rev 13697)
+++ trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/components.xml 2009-04-20 14:55:34 UTC (rev 13698)
@@ -22,18 +22,18 @@
conversation-timeout="120000"
conversation-id-parameter="cid"/>
- <persistence:managed-persistence-context name="entityManager"
- auto-create="true"
- persistence-unit-jndi-name="java:/helloworldEntityManagerFactory"/>
-
+
<drools:rule-base name="securityRules">
<drools:rule-files>
<value>/security.drl</value>
</drools:rule-files>
</drools:rule-base>
- <security:identity security-rules="#{securityRules}" authenticate-method="#{authenticator.authenticate}" remember-me="true"/>
+ <security:identity security-rules="#{securityRules}"
+ authenticate-method="#{authenticator.authenticate()}" remember-me="true"/>
+
+
<event type="org.jboss.seam.security.notLoggedIn">
<action execute="#{redirect.captureCurrentView}"/>
</event>
Modified: trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/faces-config.xml
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/faces-config.xml 2009-04-20 14:54:12 UTC (rev 13697)
+++ trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/faces-config.xml 2009-04-20 14:55:34 UTC (rev 13698)
@@ -132,13 +132,16 @@
<managed-bean-class>org.docs.tree.Shelf</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>
</managed-bean>
-
-<managed-bean>
+ <managed-bean>
<managed-bean-name>hujations</managed-bean-name>
<managed-bean-class>org.docs.tree.Hujations</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>
-
+ <managed-bean>
+ <managed-bean-name>authentification</managed-bean-name>
+ <managed-bean-class>org.docs.authentification.Authentification</managed-bean-class>
+ <managed-bean-scope>request</managed-bean-scope>
+ </managed-bean>
<application>
<view-handler>com.sun.facelets.FaceletViewHandler</view-handler>
<locale-config>
@@ -150,4 +153,5 @@
<supported-locale>tr</supported-locale>
</locale-config>
</application>
+ <!-- JSF-security method-->
</faces-config>
Modified: trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/web.xml
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/web.xml 2009-04-20 14:54:12 UTC (rev 13697)
+++ trunk/test-applications/richfaces-docs/web/src/main/webapp/WEB-INF/web.xml 2009-04-20 14:55:34 UTC (rev 13698)
@@ -121,6 +121,35 @@
+<security-constraint>
+ <web-resource-collection>
+ <web-resource-name>Protected Pages</web-resource-name>
+ <url-pattern>/isuserinrole.xhtml</url-pattern>
+ </web-resource-collection>
+ <auth-constraint>
+ <role-name>admin</role-name>
+ </auth-constraint>
+</security-constraint>
+<login-config>
+<auth-method>FORM</auth-method>
+<realm-name>openldap</realm-name>
+<form-login-config>
+<form-login-page>/login.xhtml</form-login-page>
+<form-error-page>/noauth.xhtml</form-error-page>
+</form-login-config>
+</login-config>
+
+<security-role>
+<role-name>user</role-name>
+</security-role>
+
+<security-role>
+<role-name>admin</role-name>
+</security-role>
+
+
+
+
</web-app>
15 years, 9 months
JBoss Rich Faces SVN: r13697 - trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/fileUpload.
by richfaces-svn-commits@lists.jboss.org
Author: msorokin
Date: 2009-04-20 10:54:12 -0400 (Mon, 20 Apr 2009)
New Revision: 13697
Modified:
trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/fileUpload/FileUpload.java
Log:
updated the FileUpload
Modified: trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/fileUpload/FileUpload.java
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/fileUpload/FileUpload.java 2009-04-20 14:53:35 UTC (rev 13696)
+++ trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/fileUpload/FileUpload.java 2009-04-20 14:54:12 UTC (rev 13697)
@@ -10,11 +10,11 @@
import java.util.List;
import org.richfaces.event.UploadEvent;
import org.richfaces.model.UploadItem;
+import org.richfaces.model.UploadItem;
-
public class FileUpload {
@@ -50,6 +50,7 @@
public void fileUploadListener(UploadEvent event) throws Exception {
UploadItem upload = event.getUploadItem();
+
if (upload.isTempFile()) {
File file = upload.getFile();
System.out.println(upload.getFileName());
15 years, 9 months
JBoss Rich Faces SVN: r13696 - trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree.
by richfaces-svn-commits@lists.jboss.org
Author: msorokin
Date: 2009-04-20 10:53:35 -0400 (Mon, 20 Apr 2009)
New Revision: 13696
Modified:
trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Shelf.java
trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Tree.java
Log:
updated files
Modified: trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Shelf.java
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Shelf.java 2009-04-20 14:13:13 UTC (rev 13695)
+++ trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Shelf.java 2009-04-20 14:53:35 UTC (rev 13696)
@@ -10,4 +10,5 @@
public class Shelf {
public Shelf() {
}
+
}
Modified: trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Tree.java
===================================================================
--- trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Tree.java 2009-04-20 14:13:13 UTC (rev 13695)
+++ trunk/test-applications/richfaces-docs/web/src/main/java/org/docs/tree/Tree.java 2009-04-20 14:53:35 UTC (rev 13696)
@@ -36,6 +36,9 @@
public Tree() {
+
+
+
stationRoot.setData("KickRadio");
stationNodes.addChild(0, stationRoot);
15 years, 9 months
JBoss Rich Faces SVN: r13695 - trunk/docs/userguide/en/src/main/docbook/modules.
by richfaces-svn-commits@lists.jboss.org
Author: msorokin
Date: 2009-04-20 10:13:13 -0400 (Mon, 20 Apr 2009)
New Revision: 13695
Modified:
trunk/docs/userguide/en/src/main/docbook/modules/RFCarchitectover.xml
Log:
https://jira.jboss.org/jira/browse/RF-6455
Corrected some info
Modified: trunk/docs/userguide/en/src/main/docbook/modules/RFCarchitectover.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/modules/RFCarchitectover.xml 2009-04-20 13:48:22 UTC (rev 13694)
+++ trunk/docs/userguide/en/src/main/docbook/modules/RFCarchitectover.xml 2009-04-20 14:13:13 UTC (rev 13695)
@@ -3768,7 +3768,7 @@
</section>
<section>
- <title>Identifing User Roles</title>
+ <title>Identifying User Roles</title>
<para>RichFaces provides a function to check whether the logged-in user belongs to a certain <property>user role</property>. The function is <code>rich:isUserInRole(Object)</code>, it takes a String, a comma-separated list String, Collection etc. as arguments and returns a boolean value.
</para>
15 years, 9 months
JBoss Rich Faces SVN: r13694 - in trunk/samples/richfaces-demo/src/main: resources/org/richfaces/demo/common and 3 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: ilya_shaikovsky
Date: 2009-04-20 09:48:22 -0400 (Mon, 20 Apr 2009)
New Revision: 13694
Modified:
trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/layout/Bean.java
trunk/samples/richfaces-demo/src/main/resources/org/richfaces/demo/common/components.properties
trunk/samples/richfaces-demo/src/main/webapp/richfaces/calendar/examples/functions.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/colorPicker/usage/sample.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/layouts/usage.xhtml
Log:
layouts demo draft finished.
Modified: trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/layout/Bean.java
===================================================================
--- trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/layout/Bean.java 2009-04-20 13:29:19 UTC (rev 13693)
+++ trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/layout/Bean.java 2009-04-20 13:48:22 UTC (rev 13694)
@@ -21,9 +21,9 @@
private String theme = "simple";
- private int width=960;
+ private int width=1024;
- private int sidebarWidth=260;
+ private int sidebarWidth=200;
/**
* @return the position
Modified: trunk/samples/richfaces-demo/src/main/resources/org/richfaces/demo/common/components.properties
===================================================================
--- trunk/samples/richfaces-demo/src/main/resources/org/richfaces/demo/common/components.properties 2009-04-20 13:29:19 UTC (rev 13693)
+++ trunk/samples/richfaces-demo/src/main/resources/org/richfaces/demo/common/components.properties 2009-04-20 13:48:22 UTC (rev 13694)
@@ -92,4 +92,4 @@
editor=richInputs, Editor, /images/ico_Editor.gif, /images/cn_Editor.gif, editor.html, jbossrichfaces/freezone/docs/tlddoc/rich/editor.html, jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIEditor.html, /richfaces/editor.jsf
queue=ajaxSupport, Queue, /images/ico_common.gif, /images/cn_Queue.gif, Queue.html, jbossrichfaces/freezone/docs/tlddoc/rich/queue.html, jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIQueue.html, /richfaces/queue.jsf
colorPicker= richInputs, Color Picker, /images/ico_ColorPicker.gif, /images/cn_ColorPicker.gif, ColorPicker.html, jbossrichfaces/freezone/docs/tlddoc/rich/colorPicker.html, jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIColorPicker.html, /richfaces/colorPicker.jsf, new
-layouts=richMisc, Layouts, /images/ico_Layouts.gif, /images/cn_Layouts.gif, Layouts.html, jbossrichfaces/freezone/docs/tlddoc/rich/Page.html, jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIPage.html, /richfaces/layouts.jsf, new
\ No newline at end of file
+layouts=richMisc, Semantic Layouts, /images/ico_Layouts.gif, /images/cn_Layouts.gif, Layouts.html, jbossrichfaces/freezone/docs/tlddoc/rich/Page.html, jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIPage.html, /richfaces/layouts.jsf, new
\ No newline at end of file
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/calendar/examples/functions.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/calendar/examples/functions.xhtml 2009-04-20 13:29:19 UTC (rev 13693)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/calendar/examples/functions.xhtml 2009-04-20 13:48:22 UTC (rev 13694)
@@ -11,6 +11,7 @@
}
.weekendBold{
font-weight:bold;
+ font-style: italic;
}
</style>
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/colorPicker/usage/sample.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/colorPicker/usage/sample.xhtml 2009-04-20 13:29:19 UTC (rev 13693)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/colorPicker/usage/sample.xhtml 2009-04-20 13:48:22 UTC (rev 13694)
@@ -10,7 +10,7 @@
<rich:paint2D id="painter" width="300" height="120"
data="#{paintData}" format="png" paint="#{paintBean.paint}" >
</rich:paint2D>
- <h:panelGroup>
+ <h:panelGroup>
<h:outputText value="Change text color " />
<rich:colorPicker colorMode="hex" value="#{paintData.color}">
<a4j:support event="onchange" reRender="painter"/>
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/layouts/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/layouts/usage.xhtml 2009-04-20 13:29:19 UTC (rev 13693)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/layouts/usage.xhtml 2009-04-20 13:48:22 UTC (rev 13694)
@@ -5,15 +5,25 @@
xmlns:f="http://java.sun.com/jsf/core"
xmlns:a4j="http://richfaces.org/a4j"
xmlns:rich="http://richfaces.org/rich">
- <ui:composition template="/templates/component-sample.xhtml">
- <ui:define name="sample">
- <p>
- Description
- </p>
-
- <h:outputLink target="blank" value="#{facesContext.externalContext.requestContextPath}/templates/page/template.jsf">Open sample built with layouts components</h:outputLink>
+<ui:composition template="/templates/component-sample.xhtml">
+ <ui:define name="sample">
+ <p>Set of layout components designed based on <h:outputLink
+ target="blank" value="http://developer.yahoo.com/yui/layout/">Yahoo layouts</h:outputLink>.
+ </p>
+ <p>
+ The component set consists of three components. <b>Page </b>component for page
+ layout definition and <b>Layout/LayoutPanel</b> components for nesting layout
+ grids creation.
+ </p>
+ <p>
+ As this components designed to create full page layouts - click on the link
+ below to open the page template sample based on them and read
+ detailed descriptions.
+ </p>
+ <h:outputLink target="blank"
+ value="#{facesContext.externalContext.requestContextPath}/richfaces/layouts/page/template.jsf">Open sample built with layouts components</h:outputLink>
- </ui:define>
+ </ui:define>
- </ui:composition>
+</ui:composition>
</html>
15 years, 9 months