[richfaces-svn-commits] JBoss Rich Faces SVN: r2917 - tags/3.1.0/ui/calendar/src/main/templates/org/richfaces.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Wed Sep 12 15:41:48 EDT 2007


Author: nbelaevski
Date: 2007-09-12 15:41:48 -0400 (Wed, 12 Sep 2007)
New Revision: 2917

Modified:
   tags/3.1.0/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx
Log:
Calendar:
- input & general style/class added
- resource URL for icons encoded properly

Modified: tags/3.1.0/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx
===================================================================
--- tags/3.1.0/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx	2007-09-12 19:26:06 UTC (rev 2916)
+++ tags/3.1.0/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx	2007-09-12 19:41:48 UTC (rev 2917)
@@ -14,9 +14,10 @@
 	<h:styles>/org/richfaces/renderkit/html/css/calendar.xcss</h:styles>
 
 	<div id="#{clientId}"
-		style="z-index: #{ component . attributes [ 'zindex' ]"
+		style="z-index: #{component.attributes['zindex']}; #{component.attributes['style']}"
 		class="#{component.attributes['styleClass']}"
-		x:passThruWithExclusions="value,name,type,id"><script
+		x:passThruWithExclusions="value,name,type,id,styleClass,class,style">
+		<script
 		type="text/javascript">
 			new Calendar('#{clientId}', {
 				submitFunction: 
@@ -141,18 +142,18 @@
 		onkeydown="#{component.attributes['oninputkeydown']}"
 		onkeyup="#{component.attributes['oninputkeyup']}"
 		size="#{component.attributes['inputSize']}"
-		style="vertical-align: middle;"
+		style="vertical-align: middle; #{component.attributes['inputStyle']}"
 		class="rich-calendar-input #{component.attributes['inputClass']}"
 		tabindex="#{component.attributes['tabindex']}"> </input>
 		<jsp:scriptlet>
 		 <![CDATA[
-			String buttonIcon = (String) component.getAttributes().get("buttonIcon");
+			String buttonIcon = org.richfaces.component.util.ViewUtil.getResourceURL((String) component.getAttributes().get("buttonIcon"),context);
+			String buttonIconDisabled = org.richfaces.component.util.ViewUtil.getResourceURL((String) component.getAttributes().get("buttonIconDisabled"),context);
 			String buttonLabel = (String) component.getAttributes().get("buttonLabel");
-			String buttonIconDisabled = (String) component.getAttributes().get("buttonIconDisabled");
-			variables.setVariable("buttonIcon",buttonIcon);
 			variables.setVariable("buttonLabel",buttonLabel);
 			variables.setVariable("buttonIconDisabled",buttonIconDisabled);
-			if(buttonLabel==null || buttonLabel.equals("")){	
+			variables.setVariable("buttonIcon",buttonIcon);
+			if(buttonLabel==null || buttonLabel.length()==0){	
 		]]>
 		 </jsp:scriptlet>
 		 <img id="#{clientId}PopupButton" class="rich-calendar-button #{component.attributes['buttonClass']}"




More information about the richfaces-svn-commits mailing list