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

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Thu Aug 30 20:41:00 EDT 2007


Author: SergeySmirnov
Date: 2007-08-30 20:41:00 -0400 (Thu, 30 Aug 2007)
New Revision: 2635

Added:
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/examples/
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/examples/placeToGo.xhtml
   trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/usage.xhtml
Modified:
   trunk/samples/richfaces-demo/src/main/resources/org/richfaces/demo/common/components.properties
Log:
demo update. VirtualEarth has been added

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	2007-08-31 00:09:02 UTC (rev 2634)
+++ trunk/samples/richfaces-demo/src/main/resources/org/richfaces/demo/common/components.properties	2007-08-31 00:41:00 UTC (rev 2635)
@@ -36,8 +36,8 @@
 calendar=           richInputs,           Calendar,             /images/ico_common.gif,                 /images/cn_Calendar.gif,                 RichFacesComponentsLibrary.html#calendar,                                           jbossrichfaces/freezone/docs/tlddoc/rich/calendar.html,           jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UICalendar.html,                   /richfaces/calendar.jsf
 message=            richMisc,             Message,              /images/ico_common.gif,                 /images/cn_Message.gif,                  RichFacesComponentsLibrary.html#message,                                            jbossrichfaces/freezone/docs/tlddoc/rich/message.html,            jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIMessage.html,                    /richfaces/message.jsf
 messages=           richMisc,             Messages,             /images/ico_common.gif,                 /images/cn_Messages.gif,                 RichFacesComponentsLibrary.html#messages,                                           jbossrichfaces/freezone/docs/tlddoc/rich/messages.html,           jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIMessages.html,                   /richfaces/messages.jsf
-virtualEarth=       richMisc,             Virtual Earth,        /images/ico_VirtualEarth.gif,           /images/cn_VirtualEarth.gif,             RichFacesComponentsLibrary.html#virtualEarth,                                       jbossrichfaces/freezone/docs/tlddoc/rich/virtualEarth.html,       jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIVirtualEarth.html,               /richfaces/comingSoon.jsf
-insert=		  richMisc,             Insert,        	    /images/ico_common.gif,           	  /images/cn_insert.gif,             	 RichFacesComponentsLibrary.html#insert,		                                     jbossrichfaces/freezone/docs/tlddoc/rich/insert.html,             jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIInsert.html,               	/richfaces/insert.jsf
+virtualEarth=       richMisc,             Virtual Earth,        /images/ico_VirtualEarth.gif,           /images/cn_VirtualEarth.gif,             RichFacesComponentsLibrary.html#virtualEarth,                                       jbossrichfaces/freezone/docs/tlddoc/rich/virtualEarth.html,       jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIVirtualEarth.html,               /richfaces/virtualEarth.jsf
+insert=				richMisc,             Insert,        	    /images/ico_common.gif,           	  /images/cn_insert.gif,             	 RichFacesComponentsLibrary.html#insert,		                                     jbossrichfaces/freezone/docs/tlddoc/rich/insert.html,             jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIInsert.html,               		  /richfaces/insert.jsf
 scrollableDataTable= richDataIterators,   Scrollable Data Table, /images/ico_common.gif,                /images/cn_ScrollableDataTable.gif,      RichFacesComponentsLibrary.html#scrollableDataTable,                                jbossrichfaces/freezone/docs/tlddoc/rich/scrollableDataTable,     jbossrichfaces/freezone/docs/apidoc/org/richfaces/component/UIscrollableDataTable.html,        /richfaces/scrollableDataTable.jsf
 ajaxattributes=     ajaxSupport,          Ajax Attributes,      /images/ico_common.gif,                 /images/cn_ajaxAttributes.gif,           ArchitectureOverview.html,                                                          jbossajax4jsf/freezone/docs/tlddoc/overview-summary.html,         jbossajax4jsf/freezone/docs/apidoc/overview-summary.html,                                      /richfaces/ajaxAttributes.jsf
 actionparam=        ajaxSupport,          Action Parameter,     /images/ico_common.gif,                 /images/cn_actionParameter.gif,          RichFacesComponentsLibrary.html#actionparam,                                        jbossajax4jsf/freezone/docs/tlddoc/a4j/actionparam.html,          jbossajax4jsf/freezone/docs/apidoc/org/ajax4jsf/ajax/UIActionParameter.html,                   /richfaces/actionparam.jsf

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/examples/placeToGo.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/examples/placeToGo.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/examples/placeToGo.xhtml	2007-08-31 00:41:00 UTC (rev 2635)
@@ -0,0 +1,56 @@
+<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.org/rich">
+
+	<f:view contentType="text/html">
+			
+		<style type="text/css">
+			.col1 { width:510px; }
+			.col2 {	vertical-align: top; }
+		</style>	
+
+	
+		<h:panelGrid columnClasses="col1, col2" columns="2">
+		
+			<rich:virtualEarth id="gm" style="width:500px"
+				 lat="37.9467" lng="-122.0238" dashboardSize="Normal" 
+				 zoom="17" mapStyle="Birdseye" var="map" />
+			
+			<h:panelGroup>
+				Dashboard:<br />
+				<a href="javascript:void(0);" onclick="map.HideDashboard();return false;">Remove</a>
+				<a href="javascript:void(0);" onclick="map.ShowDashboard();return false;">Show</a>
+				<br /><br />
+				Type:<br/>
+				<a href="javascript:void(0);" onclick="map.SetMapStyle(VEMapStyle.Road);return false;">Road</a>
+				<a href="javascript:void(0);" onclick="map.SetMapStyle(VEMapStyle.Aerial);return false;">Aerial</a>
+				<a href="javascript:void(0);" onclick="map.SetMapStyle(VEMapStyle.Hybrid);return false;">Hybrid</a>
+				<a href="javascript:void(0);" onclick="map.SetMapStyle(VEMapStyle.Birdseye);return false;">Birdseye</a>
+				<br /><br />
+				Zoom:<br/>
+				<a href="javascript:void(0);" onclick="map.ZoomIn();return false;">In</a>
+				<a href="javascript:void(0);" onclick="map.ZoomOut();return false;">Out</a>
+				<br /><br />
+				<a href="javascript:void(0);" onclick="showExadel();return false;">Show Exadel, Inc. Office</a>
+			
+			</h:panelGroup>	
+			
+			
+		</h:panelGrid>
+		
+		<script type="text/javascript">
+			function showExadel() {
+	
+			    var point = new VELatLong(37.9721046, -122.0424842834);
+				map.SetCenterAndZoom(point, 16);
+				map.SetMapStyle(VEMapStyle.Birdseye);
+		   
+		   }
+		
+		</script>
+		
+	</f:view>
+</ui:composition>
\ No newline at end of file

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/usage.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/usage.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth/usage.xhtml	2007-08-31 00:41:00 UTC (rev 2635)
@@ -0,0 +1,67 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html 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.org/rich">
+	<ui:composition template="/templates/component-sample.xhtml">
+		<ui:define name="sample">
+
+			<p>rich:virtualEarth presents the dynamically generated map based on the 
+			Microsoft Virtual Earth API. API is a pure Javascript library. So, you do not need
+			to have any external program or plugin installed to make it working. The component
+			allows to place the map on the page and define the initial parameters for it. You
+			can use the Virtual Earth SDK to manipulate with map after that. The folowing links
+			helps you to be familiar to this technology:
+			<ul>
+				<li> <a href="http://dev.live.com/virtualearth/sdk/" target="_blank">
+						Virtual Earth Interactive SDK
+					 </a>
+				</li>
+				<li> <a href="http://msdn2.microsoft.com/en-us/library/bb429619.aspx" target="_blank">
+						MSDN, Virtual Earth Map Control 5.0
+					 </a>
+				</li>
+			</ul>
+			</p>
+			<div class="sample-container" >
+
+				<ui:include src="/richfaces/virtualEarth/examples/placeToGo.xhtml"/>
+				<ui:include src="/templates/include/sourceview.xhtml">
+					<ui:param name="sourcepath" value="/richfaces/virtualEarth/examples/placeToGo.xhtml"/>
+				</ui:include>
+													
+			</div>
+			
+			<p>
+			<b>var</b> attribute define the javascript variable you can use then as a reference to the
+			map from your custom javascript.
+			</p>
+			<p>
+			<b>lat</b> and <b>lng</b> attributes define the initial latitude and longitud of the
+			center of the map.
+			</p>
+			<p>
+			<b>zoom</b> attributes define the initial zoom. The available range from 1  to
+			19 (close look). The maximum might depends of the location.
+			</p>
+			<p>
+			<b>mapStyle</b> attributes define the initial map style. The available value for this 
+			attribute are "Road","Aerial","Hybrid","Birdseye". "Birdseye" is available for the limited
+			number of location only.
+			</p>
+			<p>
+			Use <b>style</b> attribute to define the size of the map. For example, style="width:600px;height:400px".
+			</p>
+			<p>
+				Virtual Earth does not support xhtml format of the page. So, if you use Facelets
+				and JSF 1.2, do not forget &lt;f:view contentType="text/html"&gt; somewhere on the 
+				page. To avoid re-initialization, do not re-render the component during Ajax
+				updates.
+			</p>
+			
+		</ui:define>
+
+	</ui:composition>
+</html>

Added: trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth.xhtml
===================================================================
--- trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth.xhtml	                        (rev 0)
+++ trunk/samples/richfaces-demo/src/main/webapp/richfaces/virtualEarth.xhtml	2007-08-31 00:41:00 UTC (rev 2635)
@@ -0,0 +1,20 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html 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:rich="http://richfaces.org/rich">
+<ui:composition template="/templates/main.xhtml">
+	<ui:define name="title">RichFaces - Open Source Rich JSF Components - Virtual Earth</ui:define>
+	<ui:define name="body">
+		<rich:tabPanel switchType="server" styleClass="top_tab" contentClass="content_tab" headerClass="header_tabs_class"  inactiveTabClass="inactive_tab" activeTabClass="active_tab">
+			<rich:tab label="Usage">
+				<ui:include src="/richfaces/virtualEarth/usage.xhtml"/>
+			</rich:tab>			
+			<ui:include src="/templates/include/tagInfo.xhtml">
+				<ui:param name="path" value="rich/virtualEarth"/>
+			</ui:include>		
+		</rich:tabPanel>
+	</ui:define>
+</ui:composition>
+</html>




More information about the richfaces-svn-commits mailing list