Author: ilya_shaikovsky
Date: 2008-03-27 04:56:48 -0400 (Thu, 27 Mar 2008)
New Revision: 7288
Modified:
trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/ajaxsupport/UserBean.java
trunk/samples/richfaces-demo/src/main/webapp/WEB-INF/faces-config.xml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/fileUpload/usage.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/externalFilteringUsage.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/filteringUsage.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/blockInplace.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/controlsCustomization.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/usage.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/controlsCustomization.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/selectItems.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/usage.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/examples/simplePanel.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml
trunk/samples/richfaces-demo/src/main/webapp/richfaces/sortingFeature/sortingUsage.xhtml
Log:
changes after Sergey's review.
Modified:
trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/ajaxsupport/UserBean.java
===================================================================
---
trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/ajaxsupport/UserBean.java 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/java/org/richfaces/demo/ajaxsupport/UserBean.java 2008-03-27
08:56:48 UTC (rev 7288)
@@ -3,7 +3,7 @@
import java.util.Date;
public class UserBean {
- private String name;
+ private String name="";
private java.lang.Integer screenWidth;
private java.lang.Integer screenHeight;
private String job;
Modified: trunk/samples/richfaces-demo/src/main/webapp/WEB-INF/faces-config.xml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/WEB-INF/faces-config.xml 2008-03-27
02:18:29 UTC (rev 7287)
+++ trunk/samples/richfaces-demo/src/main/webapp/WEB-INF/faces-config.xml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -41,11 +41,6 @@
<managed-bean-class>org.richfaces.demo.ajaxsupport.UserBean</managed-bean-class>
<managed-bean-scope>session</managed-bean-scope>
<managed-property>
- <property-name>name</property-name>
- <property-class>java.lang.String</property-class>
- <value/>
- </managed-property>
- <managed-property>
<property-name>screenWidth</property-name>
<property-class>java.lang.Integer</property-class>
<null-value/>
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/fileUpload/usage.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/fileUpload/usage.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/fileUpload/usage.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -7,17 +7,18 @@
xmlns:rich="http://richfaces.org/rich">
<ui:composition template="/templates/component-sample.xhtml">
<ui:define name="sample">
-
<p><b>
rich:fileUpload</b> is a component which provides files upload functionality
and
extends functionality of standard <i>input </i>with
<i>type=file</i>.
</p>
<p>
- Next example shows you <b>File Upload</b> which allows you to upload five
pictures to server.
+ Next example shows you <b>File Upload</b> which allows you to upload
files to server.
Files count allowed to upload managed with <b>maxFilesQuantity
</b>attribute.
Every uploaded file should be managed through <b>fileUploadListener
</b>which called after
every single file upload finished.
</p>
+ <p><b>This example allows to download up to 5 files. The file extension is
limited to GIF, JPG,
+ BMP, PNG and the maximum size of each file must not exceed 100kB </b></p>
<div class="sample-container" >
<ui:include src="/richfaces/fileUpload/examples/fileUpload.xhtml"/>
<ui:include src="/templates/include/sourceview.xhtml">
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/externalFilteringUsage.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/externalFilteringUsage.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/externalFilteringUsage.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -32,6 +32,7 @@
<ui:include
src="/richfaces/filteringFeature/examples/externalFiltering.xhtml"/>
<ui:include src="/templates/include/sourceview.xhtml">
+ <ui:param name="openlabel" value="View Page Source" />
<ui:param name="sourcepath"
value="/richfaces/filteringFeature/examples/externalFiltering.xhtml"/>
</ui:include>
<ui:include src="/templates/include/sourceview.xhtml">
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/filteringUsage.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/filteringUsage.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/filteringFeature/filteringUsage.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -35,6 +35,10 @@
<fieldset>
<legend><b>Details of usage</b></legend>
<p>
+ In order to change filter event you should change <b>filterEvent</b>
attribute
+ on column (<i>e.g. filterEvent = "onblur"</i>)
+ </p>
+ <p>
In order to get or change current filtering value <b>filterValue
</b>attribute
provided. It should be defined with initial filtering value on the page
or as value binding to get/change it on server.
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/blockInplace.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/blockInplace.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/blockInplace.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -49,7 +49,7 @@
requiredMessage="Price at row #{row+1} wasn't filled. Value can't be
changed."
changedHoverClass="hover" viewHoverClass="hover"
viewClass="inplace" changedClass="inplace"
- selectOnEdit="true">
+ selectOnEdit="true" editEvent="ondblclick">
<a4j:support event="onviewactivated" reRender="table,
messages"
bypassUpdates="true" ajaxSingle="true" />
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/controlsCustomization.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/controlsCustomization.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/examples/controlsCustomization.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -16,5 +16,5 @@
</f:facet>
</rich:inplaceInput>
-
+ <rich:spacer height="25px" width="100%"/>
</ui:composition>
\ No newline at end of file
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/usage.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/usage.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceInput/usage.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -26,25 +26,22 @@
to edit the value and
click somewhere outside the component to store this value(Or just press ENTER
button).
</p>
+ <div class="sample-container" jsfc="h:panelGroup"
layout="block">
+ <ui:include
src="/richfaces/inplaceInput/examples/simpleDefault.xhtml"/>
+ <ui:include src="/templates/include/sourceview.xhtml">
+ <ui:param name="sourcepath"
value="/richfaces/inplaceInput/examples/simpleDefault.xhtml"/>
+ </ui:include>
+ </div>
<p>
The second example has controls for components enabled with <b>showControls
</b>attribute.
- These controls should
- be used in order to apply a value or cancel editing.
+ These controls should be used in order to apply a value or cancel editing.
</p>
- <h:panelGrid columns="2" columnClasses="top equals,top equals"
width="90%">
<div class="sample-container" jsfc="h:panelGroup"
layout="block">
- <ui:include
src="/richfaces/inplaceInput/examples/simpleDefault.xhtml"/>
- <ui:include src="/templates/include/sourceview.xhtml">
- <ui:param name="sourcepath"
value="/richfaces/inplaceInput/examples/simpleDefault.xhtml"/>
- </ui:include>
- </div>
- <div class="sample-container" jsfc="h:panelGroup"
layout="block">
<ui:include
src="/richfaces/inplaceInput/examples/simpleWithControls.xhtml"/>
<ui:include src="/templates/include/sourceview.xhtml">
<ui:param name="sourcepath"
value="/richfaces/inplaceInput/examples/simpleWithControls.xhtml"/>
</ui:include>
</div>
- </h:panelGrid>
<p>
Controls used by inplace could be redefined using <b>controls</b> named
facet:
</p>
@@ -63,8 +60,9 @@
fired on saving a value used in this example to perform Ajax validation for the value
entered.
</p>
<p>
-
- </p>
+ <b>Note:</b> Inplaces in this example also customized with
<b>editEvent </b>
+ attribute. Perform <b>double click</b> at any price in order to change
it.
+ </p>
<div class="sample-container" >
<ui:include
src="/richfaces/inplaceInput/examples/blockInplace.xhtml"/>
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/controlsCustomization.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/controlsCustomization.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/controlsCustomization.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -10,7 +10,7 @@
}
</style>
<h:form>
- <h:panelGrid columns="1">
+ <h:panelGrid columns="2" width="500px;">
<rich:inplaceSelect value="#{inplaceComponentsBean.inputValue}"
defaultLabel="Click here to edit" showControls="true"
controlsHorizontalPosition="left"
controlsVerticalPosition="bottom"
@@ -24,7 +24,9 @@
<f:selectItems value="#{capitalsBean.capitalsOptions}" />
<a4j:support event="onviewactivated" reRender="output" />
</rich:inplaceSelect>
- <h:outputText id="output" value="Current Value:
#{inplaceComponentsBean.inputValue}"/>
+ <h:outputText id="output"
+ value="Current State Capital: #{inplaceComponentsBean.inputValue}"
+ style="font-weight:bold;" />
</h:panelGrid>
</h:form>
<rich:spacer width="100%" height="40px" />
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/selectItems.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/selectItems.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/examples/selectItems.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -6,9 +6,12 @@
xmlns:rich="http://richfaces.org/rich">
<style>
+ .rich-inplace-select{
+ font-size:10pt;
+ }
.inplace{
border: none;
- cursor:pointer;
+ cursor:pointer;
}
.hover {
color: #{a4jSkin.generalTextColor};
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/usage.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/usage.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/inplaceSelect/usage.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -30,7 +30,6 @@
</p>
<ul>
<li>Controls "save" and "cancel" are turned on with
<b>showControls</b> attribute</li>
- <li><b>editEvent</b> set as <i>ondblclick</i>.
<u>So you should click twice to edit a value</u> </li>
<li><b>Layout</b> attribute is defined as <b>block</b>
and inplace is rendered as <i>div</i> an element instead of<i> span
</i></li>
<li>
@@ -39,6 +38,7 @@
</li>
<li> Classes customization is used</li>
</ul>
+ <p><b>Double click to edit value</b> <i>(editEvent set as
ondblclick)</i>.</p>
<div class="sample-container" >
<ui:include
src="/richfaces/inplaceSelect/examples/selectItems.xhtml"/>
<ui:include src="/templates/include/sourceview.xhtml">
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/examples/simplePanel.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/examples/simplePanel.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/examples/simplePanel.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -27,7 +27,7 @@
a wizard like behavior.</p>
<p>The model panel is open and closed from the javascript function
on <i>Richfaces</i> object. The following code
- <a href="javascript:Richfaces.hideModalPanel('mp')">hide this
panel</a>:
- Richfaces.hideModalPanel('mp')</p>
+ <a href="#"
onclick="#{rich:component('mp')}.hide()">hide this panel</a>:
+ <f:verbatim>#</f:verbatim>{rich:component('mp')}.hide()</p>
</rich:modalPanel>
</ui:composition>
\ No newline at end of file
Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -11,35 +11,37 @@
<p>RichFaces Modal Panel is a container that blocks an operation on the base page
when the modal
panel is shown.</p>
- <p>You can show the modal panel using the following javascript function:
Richfaces.hideModalPanel(id, params).</p>
+ <p>
+ Modal Panel could be freely managed with <b>rich:componentControl</b>
component.
+ Next example shows the code which should be used:
+ </p>
<fieldset class="demo_fieldset">
<legend class="demo_legend">Example 1</legend>
<div class="sample-container">
- This line code invokes the modal panel:<br/>
- <a href="javascript:Richfaces.showModalPanel('mp',{width:450,
top:200})">
- Richfaces.showModalPanel('mp',{width:450,
top:200})</a><br/><br/>
- <ui:include src="/richfaces/modalPanel/examples/simplePanel.xhtml"/>
+ <ui:include
src="/richfaces/componentControl/examples/mpusage.xhtml"/>
+ <br/><br/>
<ui:include src="/templates/include/sourceview.xhtml">
- <ui:param name="sourcepath"
value="/richfaces/modalPanel/examples/simplePanel.xhtml"/>
+ <ui:param name="sourcepath"
value="/richfaces/componentControl/examples/mpusage.xhtml"/>
<ui:param name="openlabel" value="View Page Source" />
- </ui:include>
+ </ui:include>
</div>
</fieldset>
- <p>
- Modal Panel could be also managed with <b>rich:componentControl</b>
component.
- Next example shows the code which should be used:
- </p>
+ <p>You can show the modal panel using the JS API <b>show</b> function
(<f:verbatim>#</f:verbatim>{rich:component('mp')}.show).</p>
<fieldset class="demo_fieldset">
<legend class="demo_legend">Example 2</legend>
<div class="sample-container">
- <ui:include
src="/richfaces/componentControl/examples/mpusage.xhtml"/>
- <br/><br/>
+ This line code invokes the modal panel:<br/>
+ <a onclick="#{rich:component('mp')}.show()"
href="#">
+ <f:verbatim>#</f:verbatim>{rich:component('mp')}.show()
+ </a><br/><br/>
+ <ui:include src="/richfaces/modalPanel/examples/simplePanel.xhtml"/>
<ui:include src="/templates/include/sourceview.xhtml">
- <ui:param name="sourcepath"
value="/richfaces/componentControl/examples/mpusage.xhtml"/>
+ <ui:param name="sourcepath"
value="/richfaces/modalPanel/examples/simplePanel.xhtml"/>
<ui:param name="openlabel" value="View Page Source" />
- </ui:include>
+ </ui:include>
</div>
</fieldset>
+ <p><b>NOTE:</b> Old style panel calls will be also
supported.</p>
<p>The modal panel has an absolute layout.There is no reason to put in on the
page
where it is called.If you want to perform submits from this modal panel, you should
have a separate form inside it.
In this case, the panel must be declared outside of the other form on the same page.
Modified:
trunk/samples/richfaces-demo/src/main/webapp/richfaces/sortingFeature/sortingUsage.xhtml
===================================================================
---
trunk/samples/richfaces-demo/src/main/webapp/richfaces/sortingFeature/sortingUsage.xhtml 2008-03-27
02:18:29 UTC (rev 7287)
+++
trunk/samples/richfaces-demo/src/main/webapp/richfaces/sortingFeature/sortingUsage.xhtml 2008-03-27
08:56:48 UTC (rev 7288)
@@ -6,6 +6,12 @@
xmlns:rich="http://richfaces.org/rich">
<ui:composition template="/templates/component-sample.xhtml">
<ui:define name="sample">
+ <style>
+ .top{
+ vertical-align:top;
+ }
+
+ </style>
<p><b>
Rich Data Table</b> has columns <b>sorting feature</b> built-in.
Simplest way to add sorting
@@ -19,39 +25,44 @@
In this example you could see that two first columns sorted after corresponding
header click.
</p>
- <h:panelGrid columns="2">
<div class="sample-container" jsfc="h:panelGroup"
layout="block">
- <ui:include
src="/richfaces/sortingFeature/examples/simpleSingleSorting.xhtml"/>
+ <h:panelGrid columns="2" columnClasses=",top">
+ <h:panelGroup>
+ <ui:include
src="/richfaces/sortingFeature/examples/simpleSingleSorting.xhtml"/>
+ </h:panelGroup>
+ <div jsfc="h:panelGroup" layout="block">
+ <fieldset>
+ <legend><b>Details Of usage</b></legend>
+ <p>
+ Next attributes could be defined to manage simple built-in sorting:
+ </p>
+ <ul>
+ <li>
+ <b>sortMode</b> - attribute of <b>rich:dataTable</b>
which could be defined as
+ "single"(Default) and "multiple". If multiple sorting
defined -
+ previous sorting will not be reseted. Column will be sorted
+ </li>
+ <li><b>sortOrder</b> - attribute of
<b>rich:column</b>
+ allows to set initial sorting on the column.
+ (Additional ways of usage to customize sorting described at "External
+ Sorting" tab). Possible values are "ASCENDING",
"DESCENDING" and
+ "UNSORTED"(default)
+ </li>
+ <li>
+ <b>selfSorted</b> attribute of <b>brich:column</b>
which defines
+ if the table will make header clickable and if click on the
+ header will call sorting request.
+ Default value is "true". In order to use custom sorting mechanism
+ use value "false" for this attribute.
+ </li>
+ </ul>
+ </fieldset>
+ </div>
+ </h:panelGrid>
<ui:include src="/templates/include/sourceview.xhtml">
<ui:param name="sourcepath"
value="/richfaces/sortingFeature/examples/simpleSingleSorting.xhtml"/>
</ui:include>
</div>
- <div jsfc="h:panelGroup" layout="block">
- <p>
- Next attributes could be defined to manage simple built-in sorting:
- </p>
- <ul>
- <li>
- <b>sortMode</b> - attribute of <b>rich:dataTable</b>
which could be defined as
- "single"(Default) and "multiple". If multiple sorting defined
-
- previous sorting will not be reseted. Column will be sorted
- </li>
- <li><b>sortOrder</b> - attribute of
<b>rich:column</b>
- allows to set initial sorting on the column.
- (Additional ways of usage to customize sorting described at "External
- Sorting" tab). Possible values are "ASCENDING",
"DESCENDING" and
- "UNSORTED"(default)
- </li>
- <li>
- <b>selfSorted</b> attribute of <b>brich:column</b> which
defines
- if the table will make header clickable and if click on the
- header will call sorting request.
- Default value is "true". In order to use custom sorting mechanism
- use value "false" for this attribute.
- </li>
- </ul>
- </div>
- </h:panelGrid>
</ui:define>