[richfaces-svn-commits] JBoss Rich Faces SVN: r2211 - in trunk/samples/richfaces-demo/src/main/webapp/richfaces: keepAlive and 10 other directories.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Fri Aug 10 20:49:45 EDT 2007


Author: SergeySmirnov
Date: 2007-08-10 20:49:45 -0400 (Fri, 10 Aug 2007)
New Revision: 2211

Added:
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/examples/
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/examples/enabledIssue.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/examples/
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/examples/spacers.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/examples/
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/examples/skinedPanel.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/custom.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/switchTypes.xhtml
Removed:
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/jsFunction/examples/hoverEcho.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/source/
Modified:
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/usage.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/examples/manually.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/usage.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/usage.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/usage.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/look-customization.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/usage.xhtml
Log:
demo update (samples to files)

Deleted: trunk/samples/richfaces-demo/src/main/webapp/richfaces/jsFunction/examples/hoverEcho.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/jsFunction/examples/hoverEcho.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/jsFunction/examples/hoverEcho.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -1,29 +0,0 @@
-<ui:composition xmlns="http://www.w3.org/1999/xhtml"
-      xmlns:ui="http://java.sun.com/jsf/facelets"
-      xmlns:h="http://java.sun.com/jsf/html"
-      xmlns:f="http://java.sun.com/jsf/core"
-      xmlns:a4j="http://richfaces.org/a4j"
-      xmlns:rich="http://richfaces.ajax4jsf.org/rich">
-			
-	<rich:separator lineType="solid" height="1" />
-	<table  width="400">
-		<tbody>
-		<tr>
-			<td onmouseover="updateName('Alex')"  onmouseout="updateName('')" > Alex</td>
-			<td onmouseover="updateName('Jonh')"  onmouseout="updateName('')" > Jonh</td>
-			<td onmouseover="updateName('Roger')"  onmouseout="updateName('')" > Roger</td>
-		</tr>
-		<tr>
-			<td colspan="3"><h:outputText id="showname" value="Name: #{userBean.name}" /></td>
-		</tr>
-		</tbody>
-	</table>
-
-	<a4j:form>
-		<a4j:jsFunction name="updateName" reRender="showname">
-			<a4j:actionparam name="param1" assignTo="#{userBean.name}"	/>					
-		</a4j:jsFunction>
-	</a4j:form>
-
-	<rich:separator height="1" style="padding-top:10px" />
-</ui:composition>
\ No newline at end of file

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/examples/enabledIssue.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/examples/enabledIssue.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/examples/enabledIssue.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -0,0 +1,86 @@
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+      xmlns:ui="http://java.sun.com/jsf/facelets"
+      xmlns:h="http://java.sun.com/jsf/html"
+      xmlns:f="http://java.sun.com/jsf/core"
+      xmlns:a4j="http://richfaces.org/a4j"
+      xmlns:rich="http://richfaces.ajax4jsf.org/rich">
+			
+	<rich:separator height="1" />
+	
+		<style type="text/css">
+			.pcolumn {
+				padding:10px;
+				vertical-align:top;
+			}
+		</style>
+	
+		<h:panelGrid columns="2" width="100%" columnClasses="pcolumn">
+
+			<f:verbatim>
+				This example <b>will not work</b> as expected. The expression for 'enabled' attribute
+				equals true only after UPDATE model phase when the rsBean properties are
+				updated with submitted values. So, the component is rendered as enabled
+				on the RENDER RESPONSE phase.<br />
+				However, those values do not make sence during the next Ajax request. The
+				rsBean is created from scratch as soon as it is a new request. JSF makes a
+				decision what is process on the second (APPLY VALUES) phase. At this moment,
+				the expression for 'disabled' still equals false. Therefore, the processing
+				for button is bypassed. The action does not invoked as a result.
+				phase
+			</f:verbatim>				
+
+			<f:verbatim>
+				This example will work properly. The code is almost the same as for
+				example on the left. Used managed been is based on the same class. The only
+				difference is <b>a4j:keepAlive beanName="rsBean2"</b>. This statment
+				declares to keep the value of the rsBean2 between the Ajax requests.<br/>
+				The rsBean2 is still a request scope bean as it is defined in the
+				faces-config.xml file. a4j:keepAlive stores the rsBean at the end of the 
+				JSF lifecycle. At the beginning of the next cycle, it updates with
+				the rsBean2 with the stored data. Therefore, the expression for 'disabled'
+				equals true on the second phase. The button is processed and the action is
+				invoked.
+			</f:verbatim>				
+
+
+			<h:panelGroup>
+				<h:form>
+					<h:inputText size="4" label="First Addent" value="#{rsBean.addent1}">
+						<a4j:support event="onkeyup" reRender="btn" />
+					</h:inputText>
+					<h:outputText value="+"/>
+					<h:inputText  size="4" label="Second Addent"  value="#{rsBean.addent2}">
+							<a4j:support event="onkeyup" reRender="btn" />						
+					</h:inputText>
+					<a4j:commandButton style="margin:0 5px" id="btn" action="#{rsBean.doSum}" 
+						 value="=" reRender="sum"
+						 disabled="#{rsBean.addent1 == null or rsBean.addent2==null}"/>
+					<h:outputText id="sum" value="#{rsBean.sum}" />
+				</h:form>
+			</h:panelGroup>
+		
+			<h:panelGroup>
+				<a4j:keepAlive beanName="rsBean2" />
+				<h:form>
+					<h:inputText size="4" label="First Addent" value="#{rsBean2.addent1}">
+						<a4j:support event="onkeyup" reRender="btn2" />
+					</h:inputText>
+					<h:outputText value="+"/>
+					<h:inputText   size="4" label="Second Addent"  value="#{rsBean2.addent2}">
+							<a4j:support event="onkeyup" reRender="btn2" />						
+					</h:inputText>
+					<a4j:commandButton style="margin:0 5px" id="btn2" action="#{rsBean2.doSum}" 
+						 value="=" reRender="sum2"
+						 disabled="#{rsBean2.addent1 == null or rsBean2.addent2==null}"/>
+					<h:outputText id="sum2" value="#{rsBean2.sum}" />
+				</h:form>
+				<a4j:outputPanel ajaxRendered="true">
+					<h:messages />
+				</a4j:outputPanel>
+			</h:panelGroup>
+		
+
+		
+		</h:panelGrid>
+		<rich:separator height="1" style="padding-top:10px" />
+</ui:composition>
\ No newline at end of file

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/usage.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/keepAlive/usage.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -7,12 +7,7 @@
 	xmlns:rich="http://richfaces.ajax4jsf.org/rich">
 	<ui:composition template="/templates/component-sample.xhtml">
 		<ui:define name="sample">
-			<style type="text/css">
-				.pcolumn {
-					padding:10px;
-					vertical-align:top;
-				}
-			</style>
+
 			<p>
 			a4j:keepAlive extends the live cycle for request scope beans. In general, each Ajax
 			request works inside the own request scope. Therefore, the state of the component
@@ -38,82 +33,15 @@
 			will send from this page.
 			</p>
 	
-			<rich:separator height="1" />
 			<div class="sample-container" >
-				<h:panelGrid columns="2" width="100%" columnClasses="pcolumn">
 
-					<f:verbatim>
-						This example <b>will not work</b> as expected. The expression for 'enabled' attribute
-						equals true only after UPDATE model phase when the rsBean properties are
-						updated with submitted values. So, the component is rendered as enabled
-						on the RENDER RESPONSE phase.<br />
-						However, those values do not make sence during the next Ajax request. The
-						rsBean is created from scratch as soon as it is a new request. JSF makes a
-						decision what is process on the second (APPLY VALUES) phase. At this moment,
-						the expression for 'disabled' still equals false. Therefore, the processing
-						for button is bypassed. The action does not invoked as a result.
-						phase
-					</f:verbatim>				
-
-					<f:verbatim>
-						This example will work properly. The code is almost the same as for
-						example on the left. Used managed been is based on the same class. The only
-						difference is <b>a4j:keepAlive beanName="rsBean2"</b>. This statment
-						declares to keep the value of the rsBean2 between the Ajax requests.<br/>
-						The rsBean2 is still a request scope bean as it is defined in the
-						faces-config.xml file. a4j:keepAlive stores the rsBean at the end of the 
-						JSF lifecycle. At the beginning of the next cycle, it updates with
-						the rsBean2 with the stored data. Therefore, the expression for 'disabled'
-						equals true on the second phase. The button is processed and the action is
-						invoked.
-					</f:verbatim>				
-
-
-					<h:panelGroup>
-						<h:form>
-							<h:inputText size="4" label="First Addent" value="#{rsBean.addent1}">
-								<a4j:support event="onkeyup" reRender="btn" />
-							</h:inputText>
-							<h:outputText value="+"/>
-							<h:inputText  size="4" label="Second Addent"  value="#{rsBean.addent2}">
-									<a4j:support event="onkeyup" reRender="btn" />						
-							</h:inputText>
-							<a4j:commandButton style="margin:0 5px" id="btn" action="#{rsBean.doSum}" 
-								 value="=" reRender="sum"
-								 disabled="#{rsBean.addent1 == null or rsBean.addent2==null}"/>
-							<h:outputText id="sum" value="#{rsBean.sum}" />
-						</h:form>
-					</h:panelGroup>
-				
-					<h:panelGroup>
-						<a4j:keepAlive beanName="rsBean2" />
-						<h:form>
-							<h:inputText size="4" label="First Addent" value="#{rsBean2.addent1}">
-								<a4j:support event="onkeyup" reRender="btn2" />
-							</h:inputText>
-							<h:outputText value="+"/>
-							<h:inputText   size="4" label="Second Addent"  value="#{rsBean2.addent2}">
-									<a4j:support event="onkeyup" reRender="btn2" />						
-							</h:inputText>
-							<a4j:commandButton style="margin:0 5px" id="btn2" action="#{rsBean2.doSum}" 
-								 value="=" reRender="sum2"
-								 disabled="#{rsBean2.addent1 == null or rsBean2.addent2==null}"/>
-							<h:outputText id="sum2" value="#{rsBean2.sum}" />
-						</h:form>
-						<a4j:outputPanel ajaxRendered="true">
-							<h:messages />
-						</a4j:outputPanel>
-					</h:panelGroup>
-				
-
-				
-				</h:panelGrid>
-				<rich:separator height="1" style="padding-top:10px" />
+				<ui:include src="/richfaces/keepAlive/examples/enabledIssue.xhtml"/>
+				<ui:include src="/templates/include/sourceview.xhtml">
+					<ui:param name="sourcepath" value="/richfaces/keepAlive/examples/enabledIssue.xhtml"/>
+				</ui:include>						
 			</div>
+			
 		</ui:define>
-		<ui:define name="sources">
-				Here is a fragment of page sources for the given example:
-				<iframe src="${facesContext.externalContext.requestContextPath}/richfaces/keepAlive/source/usage.html" class="source_frame"/>
-		</ui:define>
+
 	</ui:composition>
 </html>

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/modalPanel/usage.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -28,7 +28,7 @@
 		where it is called. If modal panel has a form element, it should have it own form.
 		In this case, it must be declired outside of the other form on the same page.
 		I.e. nested form are not allowed.<br/>
-		Those requirements are apply because due to the bug of earlier Interner Expolrer versions,
+		Those requirements apply because due to the bug of earlier Interner Expolrer versions,
 		the dialog are moved to the top of the browser DOM tree just after it is rendered.</p>
 
 	</ui:define>

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/examples/manually.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/examples/manually.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/examples/manually.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -7,36 +7,42 @@
 			
 	<a4j:loadScript src="resource:///org/richfaces/renderkit/html/scripts/scriptaculous/scriptaculous.js"/>
 	<a4j:loadScript src="resource:///org/richfaces/renderkit/html/scripts/scriptaculous/effects.js"/>
+	
+	<script>
+		Effect.Transitions.Elastic = function(pos) {
+	    	return -1*Math.pow(4,-2*pos) * Math.sin((pos*3-1)*(3*Math.PI)/2) + 1;
+		};
+	</script>
 
-	<h:commandButton  onclick="new Effect.BlindUp($('mypanel_body'), {duration:.3});return false" value="Hide"></h:commandButton>
-	<h:commandButton  onclick="new Effect.Appear($('mypanel_body'));return false" value="Show"></h:commandButton>
+	<h:commandButton  onclick="new Effect.BlindUp($('mypanel'), {duration:.3});return false" value="Hide" />
+	<h:commandButton  onclick="new Effect.BlindDown($('mypanel'),{duration:1.5,transition:Effect.Transitions.Elastic});return false" value="Show" />
 
-	<rich:separator height="1" style="padding:10px 0" />
+	<div>
+		<rich:spacer height="20" />
 
-	<rich:panel  id="mypanel">
+		<rich:panel  id="mypanel">
 			<f:facet name="header">
 				<h:outputText value="Using Scriptaculous Effects"/>
 			</f:facet>
 
-
-
-
-			<h:panelGrid styleClass="rsPanel" width="250" columns="2">
-				<h:outputText styleClass="rsLabel" value="Name:" />
-				<h:inputText  styleClass="rsInput"  value="#{userBean.name}" />
-				
-				<h:outputText styleClass="rsLabel" value="Job:" />
-				<h:inputText  styleClass="rsInput"  value="#{userBean.job}" />
-				
-				<h:panelGroup />
-				<h:commandButton styleClass="rsButton"  value="Submit">
-					<a4j:support  disableDefault="true" event="onclick" reRender="out" />
-				</h:commandButton>
-				
-				<f:facet name="footer">
-				</f:facet>
-						
-			</h:panelGrid>
+			<h:form>
+				<h:panelGrid styleClass="rsPanel" width="250" columns="2">
+					<h:outputText styleClass="rsLabel" value="Name:" />
+					<h:inputText  styleClass="rsInput"  value="#{userBean.name}" />
+					
+					<h:outputText styleClass="rsLabel" value="Job:" />
+					<h:inputText  styleClass="rsInput"  value="#{userBean.job}" />
+					
+					<h:panelGroup />
+					<h:commandButton styleClass="rsButton"  value="Submit">
+						<a4j:support  disableDefault="true" event="onclick" reRender="out" />
+					</h:commandButton>
+					
+					<f:facet name="footer">
+					</f:facet>
+							
+				</h:panelGrid>
+			</h:form>			
 			<h:panelGrid id="out" columns="1">
 				
 			<h:outputText value=""/>
@@ -44,10 +50,10 @@
 			<h:outputText value="Name: #{userBean.name}" />
 			<h:outputText value="Job: #{userBean.job}" />
 			</h:panelGrid>
-			
+				
 		</rich:panel>
 
 		<rich:spacer height="20" />
+	</div>
 
-
 </ui:composition>
\ No newline at end of file

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/usage.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/script/usage.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -21,8 +21,8 @@
 				RichFaces resource framework.  For example, if you script file is located inside the
 				jar file and has a full path there: /org/mycompany/assets/script/focus.js , you can
 				point to it with:
-				<pre>
-	&lt;a4j:loadScript src="resource:///org/mycompany/assets/script/focus.js" /&gt;
+				<pre style="margin:0px">
+	<span class="xml_tag_symbols">&lt;</span><span class="xml_tag_name">a4j:loadScript</span><span class="xml_plain"> </span><span class="xml_attribute_name">src</span><span class="xml_tag_symbols">=</span><span class="xml_attribute_value">"resource:///org/mycompany/assets/script/focus.js"</span><span class="xml_plain"> </span><span class="xml_tag_symbols">/&gt;</span><span class="xml_plain"/>
 				</pre>
 			</p>
 			<p>

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/examples/spacers.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/examples/spacers.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/examples/spacers.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -0,0 +1,17 @@
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+      xmlns:ui="http://java.sun.com/jsf/facelets"
+      xmlns:h="http://java.sun.com/jsf/html"
+      xmlns:f="http://java.sun.com/jsf/core"
+      xmlns:a4j="http://richfaces.org/a4j"
+      xmlns:rich="http://richfaces.ajax4jsf.org/rich">
+			
+	<p>
+		There is a spacer 100x10<rich:spacer width="100" height="10" title="Here is a spacer..."/>before this.
+	</p>
+	<p>
+		There is 1x5 spacer between two lines below:
+		<div style="height:0px; border:1px solid #{a4jSkin.panelBorderColor}"/>
+		<rich:spacer width="1" height="5" title="Here is a spacer..."/>
+		<div style="height:0px; border:1px solid #{a4jSkin.panelBorderColor}"/>
+	</p>
+</ui:composition>
\ No newline at end of file

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/usage.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/spacer/usage.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -6,23 +6,15 @@
 	xmlns:rich="http://richfaces.ajax4jsf.org/rich">
 	<ui:composition template="/templates/component-sample.xhtml">
 		<ui:define name="sample">
-		<p>
-			Spacer is a simple component that render invisible image with given width, height. Usually it used to separate elements of page design.
-		</p>
-		<p>
-			There is a spacer 100x10<rich:spacer width="100" height="10" title="Here is a spacer..."/>before this.
-		</p>
-		<br/>
-			There is 1x5 spacer between two lines below:
-			<div style="height:0px; border:1px solid #{a4jSkin.panelBorderColor}"/>
-			<rich:spacer width="1" height="5" title="Here is a spacer..."/>
-			<div style="height:0px; border:1px solid #{a4jSkin.panelBorderColor}"/>
-		<br/>
-		
+			<p>
+				Spacer is a simple component that render invisible image with given width, height. Usually it used to separate elements of page design.
+			</p>
+
+			<ui:include src="/richfaces/spacer/examples/spacers.xhtml"/>
+			<ui:include src="/templates/include/sourceview.xhtml">
+				<ui:param name="sourcepath" value="/richfaces/spacer/examples/spacers.xhtml"/>
+			</ui:include>		
 		</ui:define>
-		<ui:define name="sources">
-			Here is fragment of page sources for given example. Note how we used skin parameters to define border color for span.
-			<iframe src="${facesContext.externalContext.requestContextPath}/richfaces/spacer/source/usage.html" class="source_frame"/>
-		</ui:define>
+
 	</ui:composition>
 </html>

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/examples/skinedPanel.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/examples/skinedPanel.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/examples/skinedPanel.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -0,0 +1,55 @@
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+      xmlns:ui="http://java.sun.com/jsf/facelets"
+      xmlns:h="http://java.sun.com/jsf/html"
+      xmlns:f="http://java.sun.com/jsf/core"
+      xmlns:a4j="http://richfaces.org/a4j"
+      xmlns:rich="http://richfaces.ajax4jsf.org/rich">
+	<a4j:loadStyle src="resource:///org/richfaces/demo/ajaxSamples/rspanel.xcss" />
+	<h:form>
+	
+		<rich:panel>
+			<f:facet name="header">
+				<h:outputText value="Applying Skin on non-RichFaces Components"/>
+			</f:facet>
+			<h:commandLink value="DeepMarine">
+				<a4j:actionparam name="skin" value="deepMarine" assignTo="#{skinBean.skin}"/>
+			</h:commandLink>
+			<rich:spacer width="20" />
+			<h:commandLink value="BlueSky" >
+				<a4j:actionparam name="skin" value="blueSky" assignTo="#{skinBean.skin}"/>
+			</h:commandLink>
+			<rich:spacer width="20" />
+			<h:commandLink value="JapanCherry" >
+				<a4j:actionparam name="skin" value="japanCherry" assignTo="#{skinBean.skin}"/>
+			</h:commandLink>
+
+			<rich:separator height="2"  style="padding:10px 0" />
+
+			<h:panelGrid styleClass="rsPanel" width="250" columns="2">
+				<h:outputText styleClass="rsLabel" value="Name:" />
+				<h:inputText  styleClass="rsInput"  value="#{userBean.name}" />
+				
+				<h:outputText styleClass="rsLabel" value="Job:" />
+				<h:inputText  styleClass="rsInput"  value="#{userBean.job}" />
+				
+				<h:panelGroup />
+				<h:commandButton styleClass="rsButton"  value="Submit">
+					<a4j:support  disableDefault="true" event="onclick" reRender="out" />
+				</h:commandButton>
+				
+				<f:facet name="footer">
+				</f:facet>
+						
+			</h:panelGrid>
+			<h:panelGrid id="out" columns="1">
+				
+			<h:outputText value=""/>
+			<h:outputText value="You have just entered:"/>
+			<h:outputText value="Name: #{userBean.name}" />
+			<h:outputText value="Job: #{userBean.job}" />
+			</h:panelGrid>
+			
+		</rich:panel>
+	</h:form>
+
+</ui:composition>
\ No newline at end of file

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/usage.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/style/usage.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -21,10 +21,10 @@
 				RichFaces resource framework. For example, if you css file is located inside the
 				jar file and has a full path there: /org/mycompany/assets/css/common.css , you can
 				point to it with:
-				<pre>
-	&lt;a4j:loadScript src="resource:///org/mycompany/assets/css/common.css" /&gt;
-				</pre>
 			</p>
+<pre style="margin:0px">			
+	<span class="xml_tag_symbols">&lt;</span><span class="xml_tag_name">a4j:loadScript</span><span class="xml_plain"> </span><span class="xml_attribute_name">src</span><span class="xml_tag_symbols">=</span><span class="xml_attribute_value">"resource:///org/mycompany/assets/css/common.css"</span><span class="xml_plain"> </span><span class="xml_tag_symbols">/&gt;</span><span class="xml_plain"/>
+</pre>
 			<p>
 				Richfaces allows to have a dynamically generated css file based on RichFaces 
 				skinability feature. xcss is a XML formated css with some additional extentions.
@@ -33,64 +33,15 @@
 				of only non-Richfaces component, but it is sensitive to the current skin.
 			</p>
 			
-			<a4j:loadStyle src="resource:///org/richfaces/demo/ajaxSamples/rspanel.xcss" />
-
-
 			
-			
 			<div class="sample-container" >
-				<h:form>
-				
-					<rich:panel>
-						<f:facet name="header">
-							<h:outputText value="Applying Skin on non-RichFaces Components"/>
-						</f:facet>
-						<h:commandLink value="DeepMarine">
-							<a4j:actionparam name="skin" value="deepMarine" assignTo="#{skinBean.skin}"/>
-						</h:commandLink>
-						<rich:spacer width="20" />
-						<h:commandLink value="BlueSky" >
-							<a4j:actionparam name="skin" value="blueSky" assignTo="#{skinBean.skin}"/>
-						</h:commandLink>
-						<rich:spacer width="20" />
-						<h:commandLink value="JapanCherry" >
-							<a4j:actionparam name="skin" value="japanCherry" assignTo="#{skinBean.skin}"/>
-						</h:commandLink>
 
-						<rich:separator height="2"  style="padding:10px 0" />
-
-						<h:panelGrid styleClass="rsPanel" width="250" columns="2">
-							<h:outputText styleClass="rsLabel" value="Name:" />
-							<h:inputText  styleClass="rsInput"  value="#{userBean.name}" />
-							
-							<h:outputText styleClass="rsLabel" value="Job:" />
-							<h:inputText  styleClass="rsInput"  value="#{userBean.job}" />
-							
-							<h:panelGroup />
-							<h:commandButton styleClass="rsButton"  value="Submit">
-								<a4j:support  disableDefault="true" event="onclick" reRender="out" />
-							</h:commandButton>
-							
-							<f:facet name="footer">
-							</f:facet>
-									
-						</h:panelGrid>
-						<h:panelGrid id="out" columns="1">
-							
-						<h:outputText value=""/>
-						<h:outputText value="You have just entered:"/>
-						<h:outputText value="Name: #{userBean.name}" />
-						<h:outputText value="Job: #{userBean.job}" />
-						</h:panelGrid>
-						
-					</rich:panel>
-				</h:form>
-
+				<ui:include src="/richfaces/style/examples/skinedPanel.xhtml"/>
+				<ui:include src="/templates/include/sourceview.xhtml">
+					<ui:param name="sourcepath" value="/richfaces/style/examples/skinedPanel.xhtml"/>
+				</ui:include>	
 			</div>
 		</ui:define>
-		<ui:define name="sources">
-				Here is a fragment of page sources for the given example:
-				<iframe src="${facesContext.externalContext.requestContextPath}/richfaces/style/source/usage.html" class="source_frame"/>
-		</ui:define>
+
 	</ui:composition>
 </html>

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/custom.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/custom.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/custom.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -0,0 +1,31 @@
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+      xmlns:ui="http://java.sun.com/jsf/facelets"
+      xmlns:h="http://java.sun.com/jsf/html"
+      xmlns:f="http://java.sun.com/jsf/core"
+      xmlns:a4j="http://richfaces.org/a4j"
+      xmlns:rich="http://richfaces.ajax4jsf.org/rich">
+	<style>
+	.rich-tab-inactive {
+		cursor: pointer;
+	}
+	.rich-tabpanel-content {
+		border-width: 1px 0px 0px 0px;
+		background-color: transparent;
+	}
+	</style>
+	<p>
+	Here is an example of default tab panel with 3 tabs.
+	<rich:tabPanel headerAlignment="right" switchType="client">
+		<rich:tab label="First">
+			Here is tab #1
+		</rich:tab>
+		<rich:tab label="Second">
+			Here is tab #2
+		</rich:tab>
+		<rich:tab label="Third">
+			Here is tab #3
+		</rich:tab>
+	</rich:tabPanel>
+	</p>
+
+</ui:composition>
\ No newline at end of file

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/switchTypes.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/switchTypes.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/examples/switchTypes.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -0,0 +1,50 @@
+<ui:composition xmlns="http://www.w3.org/1999/xhtml"
+      xmlns:ui="http://java.sun.com/jsf/facelets"
+      xmlns:h="http://java.sun.com/jsf/html"
+      xmlns:f="http://java.sun.com/jsf/core"
+      xmlns:a4j="http://richfaces.org/a4j"
+      xmlns:rich="http://richfaces.ajax4jsf.org/rich">
+	<p>
+	Here is an example of default tab panel with 3 tabs.
+	<rich:tabPanel>
+		<rich:tab label="First">
+			Here is tab #1
+		</rich:tab>
+		<rich:tab label="Second">
+			Here is tab #2
+		</rich:tab>
+		<rich:tab label="Third">
+			Here is tab #3
+		</rich:tab>
+	</rich:tabPanel>
+	</p>
+	<p>
+	Here is an example of tab panel switched in "ajax" style. Second tab is disabled.
+	<rich:tabPanel switchType="ajax">
+		<rich:tab label="First">
+			Here is tab #1
+		</rich:tab>
+		<rich:tab label="Second" disabled="true">
+			Here is tab #2
+		</rich:tab>
+		<rich:tab label="Third">
+			Here is tab #3
+		</rich:tab>
+	</rich:tabPanel>
+	</p>
+	<p>
+	Here is an example of tab panel switched completely on client.
+	<rich:tabPanel switchType="client">
+		<rich:tab label="First">
+			Here is tab #1
+		</rich:tab>
+		<rich:tab label="Second">
+			Here is tab #2
+		</rich:tab>
+		<rich:tab label="Third">
+			Here is tab #3
+		</rich:tab>
+	</rich:tabPanel>
+	</p>
+
+</ui:composition>
\ No newline at end of file

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/look-customization.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/look-customization.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/look-customization.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -6,37 +6,20 @@
 	xmlns:rich="http://richfaces.ajax4jsf.org/rich">
 	<ui:composition template="/templates/component-sample.xhtml">
 		<ui:define name="sample">
-		<p>
-		This is a demo of use stylesheets and skinability features to adjust tab spanel look. Here we use pre-defined classes for tab panel
-		"rich-tab-inactive", "rich-tab-active" and "rich-tabpanel-content" to adjust tab panel look. Note how look of tabs above also affected.
-		</p>
-<style>
-.rich-tab-inactive {
-	cursor: pointer;
-}
-.rich-tabpanel-content {
-	border-width: 1px 0px 0px 0px;
-	background-color: transparent;
-}
-</style>
-<p>
-Here is an example of default tab panel with 3 tabs.
-<rich:tabPanel headerAlignment="right" switchType="client">
-	<rich:tab label="First">
-		Here is tab #1
-	</rich:tab>
-	<rich:tab label="Second">
-		Here is tab #2
-	</rich:tab>
-	<rich:tab label="Third">
-		Here is tab #3
-	</rich:tab>
-</rich:tabPanel>
-</p>
+			<p>
+			This is a demo of use stylesheets and skinability features to adjust tab spanel look. Here we use pre-defined classes for tab panel
+			"rich-tab-inactive", "rich-tab-active" and "rich-tabpanel-content" to adjust tab panel look. Note how look of tabs above also affected.
+			</p>
+
+			<div id="itme" class="sample-container">
+				
+				<ui:include src="/richfaces/tabPanel/examples/custom.xhtml"/>
+				<ui:include src="/templates/include/sourceview.xhtml">
+					<ui:param name="sourcepath" value="/richfaces/tabPanel/examples/custom.xhtml"/>
+				</ui:include>	
+			
+			</div>
 		</ui:define>
-		<ui:define name="sources">
-				Here is fragment of page sources for given example:
-				<iframe src="${facesContext.externalContext.requestContextPath}/richfaces/tabPanel/source/look-customization.html" class="source_frame"/>
-		</ui:define>
+
 	</ui:composition>
 </html>

Modified: trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/usage.xhtml	2007-08-11 00:30:28 UTC (rev 2210)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/tabPanel/usage.xhtml	2007-08-11 00:49:45 UTC (rev 2211)
@@ -10,52 +10,16 @@
 		Tab panel use to create "tabbed" pages. RichFaces tab panel can be switched in 3 way - using "normal" server-side update, using "ajax" style update, when only tab panel area will be updated on the page, and using "client" type - without any interaction with server.
 		Note, that in case of "client" switch type all tabs will be rendered at the same time.
 		</p>
-		<p>
-		Here is an example of default tab panel with 3 tabs.
-		<rich:tabPanel>
-			<rich:tab label="First">
-				Here is tab #1
-			</rich:tab>
-			<rich:tab label="Second">
-				Here is tab #2
-			</rich:tab>
-			<rich:tab label="Third">
-				Here is tab #3
-			</rich:tab>
-		</rich:tabPanel>
-		</p>
-		<p>
-		Here is an example of tab panel switched in "ajax" style. Second tab is disabled.
-		<rich:tabPanel switchType="ajax">
-			<rich:tab label="First">
-				Here is tab #1
-			</rich:tab>
-			<rich:tab label="Second" disabled="true">
-				Here is tab #2
-			</rich:tab>
-			<rich:tab label="Third">
-				Here is tab #3
-			</rich:tab>
-		</rich:tabPanel>
-		</p>
-		<p>
-		Here is an example of tab panel switched completely on client.
-		<rich:tabPanel switchType="client">
-			<rich:tab label="First">
-				Here is tab #1
-			</rich:tab>
-			<rich:tab label="Second">
-				Here is tab #2
-			</rich:tab>
-			<rich:tab label="Third">
-				Here is tab #3
-			</rich:tab>
-		</rich:tabPanel>
-		</p>
+		<div id="itme" class="sample-container">
+			
+			<ui:include src="/richfaces/tabPanel/examples/switchTypes.xhtml"/>
+			<ui:include src="/templates/include/sourceview.xhtml">
+				<ui:param name="sourcepath" value="/richfaces/tabPanel/examples/switchTypes.xhtml"/>
+			</ui:include>	
+		
+		</div>
+		
 		</ui:define>
-		<ui:define name="sources">
-				Here is fragment of page sources for given example:
-				<iframe src="${facesContext.externalContext.requestContextPath}/richfaces/tabPanel/source/usage.html" class="source_frame"/>
-		</ui:define>
+
 	</ui:composition>
 </html>




More information about the richfaces-svn-commits mailing list