[richfaces-svn-commits] JBoss Rich Faces SVN: r2303 - in trunk/ui/calendar/src/main: resources/org/richfaces/renderkit/html/scripts and 1 other directories.
richfaces-svn-commits at lists.jboss.org
richfaces-svn-commits at lists.jboss.org
Fri Aug 17 05:57:11 EDT 2007
Author: pyaschenko
Date: 2007-08-17 05:57:11 -0400 (Fri, 17 Aug 2007)
New Revision: 2303
Modified:
trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/css/calendar.xcss
trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/scripts/calendar.js
trunk/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx
Log:
reset button changed to (x) link
.calendar_header_optional and .calendar_footer_optional classes added
style fixes
Modified: trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/css/calendar.xcss
===================================================================
--- trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/css/calendar.xcss 2007-08-16 20:02:12 UTC (rev 2302)
+++ trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/css/calendar.xcss 2007-08-17 09:57:11 UTC (rev 2303)
@@ -9,12 +9,17 @@
.calendar_btn{
cursor : pointer;
}
-.calendar_header{
+.calendar_header_optional{
border-bottom : 1px solid;
padding : 7px;
height : 22px;
}
+.calendar_header{
+ border-right : 0px solid;
+ border-bottom : 1px solid;
+}
+
.cell_size{
width : 25px;
height : 22px;
@@ -29,7 +34,6 @@
}
.calendar_tool{
- border-bottom : 1px solid;
vertical-align : middle;
text-align : center;
width : 25px;
@@ -83,18 +87,21 @@
}
.calendar_toolfooter{
- border-top : 1px solid;
- border-right : 0px solid;
+
padding : 0px 7px 0px 7px;
height : 22px;
}
-.calendar_footer{
+.calendar_footer_optional{
border-top : 1px solid;
border-right : 0px solid;
padding : 7px;
height : 22px;
}
+.calendar_footer{
+ border-top : 1px solid;
+ border-right : 0px solid;
+}
]]>
</f:verbatim>
@@ -102,6 +109,13 @@
<u:style name="border-color" skin="panelBorderColor"/>
</u:selector>
+ <u:selector name=".calendar_header_optional">
+ <u:style name="border-bottom-color" skin="panelBorderColor"/>
+ <u:style name="background-color" skin="additionalBackgroundColor"/>
+ <u:style name="font-size" skin="generalSizeFont"/>
+ <u:style name="font-family" skin="generalFamilyFont"/>
+ </u:selector>
+
<u:selector name=".calendar_header">
<u:style name="border-bottom-color" skin="panelBorderColor"/>
<u:style name="background-color" skin="additionalBackgroundColor"/>
@@ -118,7 +132,6 @@
</u:selector>
<u:selector name=".calendar_tool">
- <u:style name="border-bottom-color" skin="panelBorderColor"/>
<u:style name="background-color" skin="headerBackgroundColor"/>
<u:style name="font-size" skin="headerSizeFont"/>
<u:style name="font-family" skin="headerFamilyFont"/>
@@ -194,6 +207,12 @@
</u:selector>
<u:selector name=".calendar_toolfooter">
+ <u:style name="background" skin="additionalBackgroundColor"/>
+ <u:style name="font-size" skin="generalSizeFont"/>
+ <u:style name="font-family" skin="generalFamilyFont"/>
+ </u:selector>
+
+ <u:selector name=".calendar_footer_optional">
<u:style name="border-top-color" skin="panelBorderColor"/>
<u:style name="border-right-color" skin="panelBorderColor"/>
<u:style name="background" skin="additionalBackgroundColor"/>
Modified: trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/scripts/calendar.js
===================================================================
--- trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/scripts/calendar.js 2007-08-16 20:02:12 UTC (rev 2302)
+++ trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/scripts/calendar.js 2007-08-17 09:57:11 UTC (rev 2303)
@@ -417,10 +417,10 @@
'<input id="'+this.id+'InputCurrentDate" name="'+this.id+'InputCurrentDate" type="hidden" style="display:none" value="'+this.getCurrentDate().format("MM/y")+'"/>\n' +
'<table border="0" cellpadding="0" cellspacing="0" class="calendar_exterior"><tbody>\n';
var colspan = (this.params.showWeeksBar ? "8" : "7");
- var htmlHeaderOptional = (this.params.headerOptionalMarkup) ? '<tr><td class="calendar_header" colspan="'+colspan+'" id="'+this.id+'HeaderOptional"></td></tr>' : '';
- var htmlFooterOptional = (this.params.footerOptionalMarkup) ? '<tr><td class="calendar_footer" colspan="'+colspan+'" id="'+this.id+'FooterOptional"></td></tr>' : '';
- var htmlControlsHeader = '<tr><td colspan="'+colspan+'" id="'+this.id+'Header"></td></tr>';
- var htmlControlsFooter = '<tr><td colspan="'+colspan+'" id="'+this.id+'Footer"></td></tr>';
+ var htmlHeaderOptional = (this.params.headerOptionalMarkup) ? '<tr><td class="calendar_header_optional" colspan="'+colspan+'" id="'+this.id+'HeaderOptional"></td></tr>' : '';
+ var htmlFooterOptional = (this.params.footerOptionalMarkup) ? '<tr><td class="calendar_footer_optional" colspan="'+colspan+'" id="'+this.id+'FooterOptional"></td></tr>' : '';
+ var htmlControlsHeader = '<tr><td class="calendar_header" colspan="'+colspan+'" id="'+this.id+'Header"></td></tr>';
+ var htmlControlsFooter = '<tr><td class="calendar_footer" colspan="'+colspan+'" id="'+this.id+'Footer"></td></tr>';
var htmlTextFooter = '</tbody></table>\n'
var htmlTextIFrame = '';
@@ -471,15 +471,15 @@
for (k=1;k<7;k++)
{
+ bottomStyleClass = (k==6 ? "bottom_cell " : "");
htmlTextWeek+='<tr id="'+this.params.weekNumberBarId+k+'">';
if (this.params.showWeeksBar)
{
var weekNumberHtml = this.evaluateMarkup(this.params.weekNumberMarkup, {weekNumber: k, componentId:this.getWeekNumberComponentId(k-1)} );
- htmlTextWeek+='<td class="calendar_week">'+weekNumberHtml+'</td>';
+ htmlTextWeek+='<td class="calendar_week '+bottomStyleClass+'">'+weekNumberHtml+'</td>';
}
// day cells creation
- bottomStyleClass = (k==6 ? "bottom_cell " : "");
for (var i=0;i<7;i++)
{
styleClass = bottomStyleClass+"cell_size calendar_cell";
Modified: trunk/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx
===================================================================
--- trunk/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx 2007-08-16 20:02:12 UTC (rev 2302)
+++ trunk/ui/calendar/src/main/templates/org/richfaces/htmlCalendar.jspx 2007-08-17 09:57:11 UTC (rev 2303)
@@ -141,16 +141,17 @@
</button>
<jsp:scriptlet>
<![CDATA[
- if(readonly.booleanValue()){
+ if(readonly.booleanValue() && !component.isDisabled()) {
]]>
- </jsp:scriptlet>
- <button
- id="#{clientId}ResetButton"
- type="button"
- onclick="$(this.form.id+':calendar').component.resetSelectedDate();"
- disabled="#{component.attributes['disabled']}">
- Reset
- </button>
+ </jsp:scriptlet>
+ <a id="#{clientId}ResetButton"
+ href="#"
+ onclick="$('#{clientId}').component.resetSelectedDate();"
+ alt=""
+ style="margin-left:5px;"
+ >
+ (x)
+ </a>
<jsp:scriptlet>
<![CDATA[
}
More information about the richfaces-svn-commits
mailing list