JBoss Rich Faces SVN: r4399 - branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2007-11-30 14:40:46 -0500 (Fri, 30 Nov 2007)
New Revision: 4399
Modified:
branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js
Log:
bug:RF-1467
Modified: branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
===================================================================
--- branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 19:23:29 UTC (rev 4398)
+++ branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 19:40:46 UTC (rev 4399)
@@ -168,7 +168,7 @@
Event.stop(event);
}
Richfaces.SelectItems.doActive(this.activeItem);
- this.saveSate();
+ this.saveState();
break;
}
},
Modified: branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js
===================================================================
--- branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js 2007-11-30 19:23:29 UTC (rev 4398)
+++ branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js 2007-11-30 19:40:46 UTC (rev 4399)
@@ -146,6 +146,7 @@
}
Richfaces.SelectItems.doActive(this.activeItem);
this.saveState();
+ this.controlListManager();
break;
}
}
17 years
JBoss Rich Faces SVN: r4398 - branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2007-11-30 14:23:29 -0500 (Fri, 30 Nov 2007)
New Revision: 4398
Modified:
branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
Log:
selection was corrected
Modified: branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
===================================================================
--- branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 19:16:10 UTC (rev 4397)
+++ branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 19:23:29 UTC (rev 4398)
@@ -362,7 +362,6 @@
} else {
Richfaces.SelectItems.doNormal(this.activeItem);
}
- this.activeItem = null;
},
compareByLabel : function(obj1, obj2) {
17 years
JBoss Rich Faces SVN: r4397 - in trunk/sandbox/samples/fileUploadDemo/src/main: webapp/pages and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2007-11-30 14:16:10 -0500 (Fri, 30 Nov 2007)
New Revision: 4397
Modified:
trunk/sandbox/samples/fileUploadDemo/src/main/java/org/richfaces/Bean.java
trunk/sandbox/samples/fileUploadDemo/src/main/webapp/pages/index.jsp
Log:
RF-1214
Modified: trunk/sandbox/samples/fileUploadDemo/src/main/java/org/richfaces/Bean.java
===================================================================
--- trunk/sandbox/samples/fileUploadDemo/src/main/java/org/richfaces/Bean.java 2007-11-30 19:14:53 UTC (rev 4396)
+++ trunk/sandbox/samples/fileUploadDemo/src/main/java/org/richfaces/Bean.java 2007-11-30 19:16:10 UTC (rev 4397)
@@ -45,16 +45,18 @@
public void printFile() {
int i = -1;
InputStream stream = fileUpload.getLocalInputStream();
- do {
- try {
- i = stream.read();
- } catch (IOException e) {
- // TODO Auto-generated catch block
- e.printStackTrace();
- }
- System.out.print((char)i);
- } while (i!=-1);
- System.out.println();
+ if (stream != null) {
+ do {
+ try {
+ i = stream.read();
+ } catch (IOException e) {
+ // TODO Auto-generated catch block
+ e.printStackTrace();
+ }
+ System.out.print((char) i);
+ } while (i != -1);
+ System.out.println();
+ }
}
}
\ No newline at end of file
Modified: trunk/sandbox/samples/fileUploadDemo/src/main/webapp/pages/index.jsp
===================================================================
--- trunk/sandbox/samples/fileUploadDemo/src/main/webapp/pages/index.jsp 2007-11-30 19:14:53 UTC (rev 4396)
+++ trunk/sandbox/samples/fileUploadDemo/src/main/webapp/pages/index.jsp 2007-11-30 19:16:10 UTC (rev 4397)
@@ -8,7 +8,7 @@
<body>
<f:view>
<h:form enctype="multipart/form-data" >
- <fu:fileUpload binding="#{bean.fileUpload}"></fu:fileUpload>
+ <fu:fileUpload binding="#{bean.fileUpload}" onclick="window.status=this.value"/>
<h:commandButton type="submit" action="#{bean.printFile}"></h:commandButton>
</h:form>
</f:view>
17 years
JBoss Rich Faces SVN: r4396 - in trunk/sandbox/ui/fileUpload/src/main: java/org/richfaces/org/jboss/seam/ui/renderkit and 10 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2007-11-30 14:14:53 -0500 (Fri, 30 Nov 2007)
New Revision: 4396
Added:
trunk/sandbox/ui/fileUpload/src/main/resources/org/
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/css/
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/css/fileUpload.xcss
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/bg_button.png
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/bg_uploaded.png
trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/ico_delete.gif
trunk/sandbox/ui/fileUpload/src/main/templates/org/
trunk/sandbox/ui/fileUpload/src/main/templates/org/richfaces/
trunk/sandbox/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx
Modified:
trunk/sandbox/ui/fileUpload/src/main/config/component/fileUpload.xml
trunk/sandbox/ui/fileUpload/src/main/java/org/richfaces/org/jboss/seam/ui/renderkit/FileUploadRendererBase.java
Log:
RF-1209
Modified: trunk/sandbox/ui/fileUpload/src/main/config/component/fileUpload.xml
===================================================================
--- trunk/sandbox/ui/fileUpload/src/main/config/component/fileUpload.xml 2007-11-30 17:47:13 UTC (rev 4395)
+++ trunk/sandbox/ui/fileUpload/src/main/config/component/fileUpload.xml 2007-11-30 19:14:53 UTC (rev 4396)
@@ -35,17 +35,24 @@
<property name="maxRequestSize">1000000</property>
</component>]]>
</description>
- <renderer generate="false" override="false">
- <name>org.richfaces.renderkit.html.FileUploadRenderer</name>
- <classname>org.richfaces.org.jboss.seam.ui.renderkit.FileUploadRendererBase</classname>
- <!--<template>org/jboss/seam/ui/htmlFileUpload.jspx</template>-->
- </renderer>
+ <test>
+ <classname>org.richfaces.component.html.HtmlFileUploadComponentTestCase</classname>
+ <superclassname>org.ajax4jsf.tests.AbstractAjax4JsfTestCase</superclassname>
+ </test>
+ <renderer generate="true" override="true">
+ <name>org.richfaces.renderkit.html.FileUploadRenderer</name>
+ <template>org/richfaces/fileUpload.jspx</template>
+ </renderer>
<tag>
<name>fileUpload</name>
<classname>org.richfaces.taglib.FileUploadTag</classname>
<superclass>
org.ajax4jsf.webapp.taglib.HtmlComponentTagBase
</superclass>
+ <test>
+ <classname>org.richfaces.taglib.HtmlFileUploadTagTestCase</classname>
+ <superclassname>org.ajax4jsf.tests.AbstractAjax4JsfTestCase</superclassname>
+ </test>
</tag>
&ui_component_attributes;
&ui_input_attributes;
Modified: trunk/sandbox/ui/fileUpload/src/main/java/org/richfaces/org/jboss/seam/ui/renderkit/FileUploadRendererBase.java
===================================================================
--- trunk/sandbox/ui/fileUpload/src/main/java/org/richfaces/org/jboss/seam/ui/renderkit/FileUploadRendererBase.java 2007-11-30 17:47:13 UTC (rev 4395)
+++ trunk/sandbox/ui/fileUpload/src/main/java/org/richfaces/org/jboss/seam/ui/renderkit/FileUploadRendererBase.java 2007-11-30 19:14:53 UTC (rev 4396)
@@ -1,61 +1,20 @@
package org.richfaces.org.jboss.seam.ui.renderkit;
-import java.io.IOException;
import java.lang.reflect.Field;
import java.lang.reflect.Method;
import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;
-import javax.faces.context.ResponseWriter;
import javax.servlet.ServletRequest;
-import org.ajax4jsf.renderkit.RendererBase;
-import org.ajax4jsf.renderkit.RendererUtils.HTML;
+import org.ajax4jsf.renderkit.HeaderResourcesRendererBase;
import org.richfaces.org.jboss.seam.ui.component.UIFileUpload;
import org.richfaces.org.jboss.seam.web.MultipartRequest;
-public class FileUploadRendererBase extends RendererBase
+public abstract class FileUploadRendererBase extends HeaderResourcesRendererBase
{
-
@Override
- protected Class getComponentClass()
- {
- return UIFileUpload.class;
- }
-
- @Override
- protected void doEncodeEnd(ResponseWriter writer, FacesContext context, UIComponent component) throws IOException
- {
- UIFileUpload fileUpload = (UIFileUpload) component;
-
- writer.startElement(HTML.INPUT_ELEM, fileUpload);
- writer.writeAttribute(HTML.TYPE_ATTR, "file", null);
-
- String clientId = fileUpload.getClientId(context);
- writer.writeAttribute(HTML.id_ATTRIBUTE, clientId, null);
- writer.writeAttribute(HTML.NAME_ATTRIBUTE, clientId, null);
-
-
- /*if (fileUpload.getAccept() != null)
- {
- writer.writeAttribute(HTML.ACCEPT_ATTR, fileUpload.getAccept(), "accept");
- }
-
- if (fileUpload.getStyleClass() != null)
- {
- writer.writeAttribute(HTML.CLASS_ATTR, fileUpload.getStyleClass(), JSF.STYLE_CLASS_ATTR);
- }
-
- if (fileUpload.getStyle() != null)
- {
- writer.writeAttribute(HTML.STYLE_ATTR, fileUpload.getStyle(), "style");
- }*/
- getUtils().encodePassThruWithExclusions(context, component, HTML.DISABLED_ATTR);
- writer.endElement(HTML.INPUT_ELEM);
- }
-
- @Override
protected void doDecode(FacesContext context, UIComponent component)
{
UIFileUpload fileUpload = (UIFileUpload) component;
@@ -70,7 +29,7 @@
{
MultipartRequest multipartRequest = (MultipartRequest) request;
- String clientId = component.getClientId(context);
+ String clientId = component.getClientId(context) + ":1";
fileUpload.setLocalInputStream(multipartRequest.getFileInputStream(clientId));
fileUpload.setLocalContentType(multipartRequest.getFileContentType(clientId));
fileUpload.setLocalFileName(multipartRequest.getFileName(clientId));
Added: trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/css/fileUpload.xcss
===================================================================
--- trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/css/fileUpload.xcss (rev 0)
+++ trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/css/fileUpload.xcss 2007-11-30 19:14:53 UTC (rev 4396)
@@ -0,0 +1,79 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<f:template
+ xmlns:f="http://jsf.exadel.com/template"
+ xmlns:u="http://jsf.exadel.com/template/util"
+ xmlns="http://www.w3.org/1999/xhtml">
+ <f:verbatim>
+ *{
+ font-family: verdana;
+ font-size: 11px;
+ }
+ .file_item{
+ white-space: nowrap;
+ }
+ .file_delete_button{
+ border: 1px solid #CCCCCC;
+ padding: 1px;
+ width: 12px;
+ cursor: pointer;
+ float: left;
+ margin: 1px 2px 1px 7px;
+ }
+ .file_field{
+ float: left;
+ width: 200px;
+ height: 18px;
+ margin-bottom: 5px;
+ }
+ .file_bar_height{
+ height: 16px;
+ }
+ .file_bar_width{
+ width: 200px;
+ }
+ .file_bar_uploaded{
+ width: 99px;
+ overflow: hidden;
+ position: absolute;
+ border: 1px solid #cccccc;
+ }
+ .file_bar_shell{
+ position: relative;
+ margin-bottom: 2px;
+ float: left;
+ }
+ .file_bar_track{
+ background: #F1F1F1;
+ text-align: center;
+ border: 1px solid #cccccc;
+ color: #000000;
+ font-weight: bold;
+ position: absolute;
+ }
+ .file_bar_ststusline{
+ background: #FF9409;
+ text-align: center;
+ color: #FFFFFF;
+ font-weight: bold;
+ background-repeat: repeat-x;
+ position : absolute;
+ }
+ .file_stop_button{
+ border: 1px solid #CCCCCC;
+ padding: 0px 5px 0px 5px;
+ cursor: pointer;
+ float: left;
+ margin: 0px 0px 0px 2px;
+ }
+ </f:verbatim>
+ <u:selector name=".file_bar_ststusline">
+ <u:style name="background-image">
+ <f:resource f:key="/org/richfaces/renderkit/html/images/bg_uploaded.png"/>
+ </u:style>
+ </u:selector>
+ <u:selector name=".file_stop_button">
+ <u:style name="background-image">
+ <f:resource f:key="/org/richfaces/renderkit/html/images/bg_button.png"/>
+ </u:style>
+ </u:selector>
+</f:template>
Added: trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/bg_button.png
===================================================================
(Binary files differ)
Property changes on: trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/bg_button.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/bg_uploaded.png
===================================================================
(Binary files differ)
Property changes on: trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/bg_uploaded.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/ico_delete.gif
===================================================================
(Binary files differ)
Property changes on: trunk/sandbox/ui/fileUpload/src/main/resources/org/richfaces/renderkit/html/images/ico_delete.gif
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/sandbox/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx
===================================================================
--- trunk/sandbox/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx (rev 0)
+++ trunk/sandbox/ui/fileUpload/src/main/templates/org/richfaces/fileUpload.jspx 2007-11-30 19:14:53 UTC (rev 4396)
@@ -0,0 +1,46 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<f:root
+ xmlns:f="http://ajax4jsf.org/cdk/template"
+ xmlns:h=" http://ajax4jsf.org/cdk/headers"
+ class="org.richfaces.renderkit.html.FileUploadRenderer"
+ baseclass="org.richfaces.org.jboss.seam.ui.renderkit.FileUploadRendererBase"
+ component="org.richfaces.org.jboss.seam.ui.component.UIFileUpload"
+ >
+ <h:styles>
+ /org/richfaces/renderkit/html/css/fileUpload.xcss
+ </h:styles>
+ <h:scripts>
+ </h:scripts>
+ <f:clientId var="clientId" />
+ <div id="#{clientId}">
+ <div>
+ <div class="file_item">
+ <input id="#{clientId}:1" name="#{clientId}:1" type="file" class="file_field">
+ <f:call name="utils.encodePassThruWithExclusions">
+ <f:parameter value="disabled" />
+ </f:call>
+ </input>
+ <f:resource name="/org/richfaces/renderkit/html/images/ico_delete.gif" var="ico_delete"/>
+ <div class="file_delete_button"><img src="#{ico_delete}" width="12" height="12" alt="" border="0" /></div>
+ </div>
+ </div>
+ <div class="file_stop_button file_bar_height">Upload</div>
+ <!-- div class="file_item">
+ <div class="file_bar_height file_bar_width file_bar_shell">
+ <div class="file_bar_height file_bar_width file_bar_track">
+ 50%
+ </div>
+ <div class="file_bar_height file_bar_uploaded">
+ <div class="file_bar_height file_bar_width file_bar_ststusline">
+ 50%
+ </div>
+ </div>
+ </div>
+ <div class="file_stop_button file_bar_height">Stop</div>
+ </div>
+ Uploaded 200Kb from 500Kb -->
+ </div>
+</f:root>
+
+
+
\ No newline at end of file
17 years
JBoss Rich Faces SVN: r4395 - in trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html: scripts and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: pyaschenko
Date: 2007-11-30 12:47:13 -0500 (Fri, 30 Nov 2007)
New Revision: 4395
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
Log:
RF-1192
Some style classes was added:
.rich-calendar-tool-btn
.rich-calendar-tool-btn-over
.rich-calendar-tool-btn-press
.rich-calendar-tool-close
.rich-calendar-time-shadow
.rich-calendar-time-position
.rich-calendar-time-layout
.rich-calendar-time-layout-fields
.rich-calendar-time-layout-cancel
.rich-calendar-time-layout-ok
.rich-calendar-time-btn
.rich-calendar-time-btn-press
.rich-calendar-time-input
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-11-30 16:34:00 UTC (rev 4394)
+++ trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/css/calendar.xcss 2007-11-30 17:47:13 UTC (rev 4395)
@@ -251,5 +251,59 @@
<u:style name="vertical-align" value="middle"/>
</u:selector>
-
+ <u:selector name=".rich-calendar-time-shadow">
+ <u:style name="background" skin="tableBackgroundColor"/>
+ <u:style name="opacity" value="0.5"/>
+ <u:style name="filter" value="alpha(opacity=50)"/>
+ </u:selector>
+
+ <u:selector name=".rich-calendar-time-layout">
+ <u:style name="background" skin="additionalBackgroundColor"/>
+ <u:style name="border" value="1px solid"/>
+ <u:style name="border-color" skin="panelBorderColor"/>
+ <u:style name="font-size" skin="generalSizeFont"/>
+ <u:style name="font-family" skin="generalFamilyFont"/>
+ </u:selector>
+
+ <u:selector name=".rich-calendar-time-layout-fields">
+ <u:style name="padding" value="7px 7px 5px 7px"/>
+ <u:style name="text-align" value="center"/>
+ <u:style name="white-space" value="nowrap"/>
+ </u:selector>
+
+ <u:selector name=".rich-calendar-time-layout-cancel">
+ <u:style name="padding" value="0px 1px 7px 7px"/>
+ </u:selector>
+
+ <u:selector name=".rich-calendar-time-layout-ok">
+ <u:style name="padding" value="0px 7px 7px 1px"/>
+ </u:selector>
+
+ <u:selector name=".rich-calendar-time-btn">
+ <u:style name="width" value="45px"/>
+ <u:style name="border" value="1px solid"/>
+ <u:style name="border-color" skin="tableBackgroundColor"/>
+ <u:style name="border-right-color" skin="panelBorderColor"/>
+ <u:style name="border-bottom-color" skin="panelBorderColor"/>
+ <u:style name="text-align" value="center"/>
+ <u:style name="padding" value="2px"/>
+ <u:style name="white-space" value="nowrap"/>
+ <u:style name="text-align" value="center"/>
+ <u:style name="cursor" value="pointer"/>
+ </u:selector>
+
+ <u:selector name=".rich-calendar-time-btn-press">
+ <u:style name="border" value="1px solid"/>
+ <u:style name="border-color" skin="panelBorderColor"/>
+ <u:style name="border-right-color" skin="tableBackgroundColor"/>
+ <u:style name="border-bottom-color" skin="tableBackgroundColor"/>
+ <u:style name="background-color" skin="calendarWeekBackgroundColor"/>
+ </u:selector>
+
+ <u:selector name=".rich-calendar-time-input">
+ <u:style name="width" value="22px"/>
+ <u:style name="margin" value="0px 2px"/>
+ </u:selector>
+
+
</f:template>
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-11-30 16:34:00 UTC (rev 4394)
+++ trunk/ui/calendar/src/main/resources/org/richfaces/renderkit/html/scripts/calendar.js 2007-11-30 17:47:13 UTC (rev 4395)
@@ -316,7 +316,7 @@
if ((aa!='am' && aa!='pm') || hh<1 || hh>12) return null;
if (aa=='pm')
{
- if (hh!=12) hh+=11;
+ if (hh!=12) hh+=12;
} else if (hh==12) hh = 0;
}
else if (hh<0 || hh>23) return null;
@@ -529,6 +529,7 @@
this.INPUT_DATE_ID = this.id+'InputDate';
this.IFRAME_ID = this.id+'IFrame';
this.TIME_EDITOR_ID = this.id+'TimeEditor';
+ this.TIME_EDITOR_SHADOW_ID = this.id+'TimeEditorShaddow';
//this.popupIntervalId=null;
@@ -642,43 +643,12 @@
},
-
- createTimeEditor: function(element)
+ updateTimeEditor: function()
{
- if (this.timeType==0) return false;
- var div;
- var hid = this.id+"Header";
- var fid = this.id+"Footer";
- while (element.id!=hid && element.id!=fid && element.parentNode) element=element.parentNode;
- {
- div = document.createElement('div');
- div.id = this.TIME_EDITOR_ID;
- div.style.position='absolute';
- div.style.textAlign='center';
- div.style.backgroundColor='#f0f0f0';
- div.style.border='1px solid #808080';
- div.style.padding='3px';
- div.style.visibility='hidden';
- div.innerHTML = this.timePatternHtml+' <span class="rich-calendar-btn" onclick="$(\''+this.id+'\').component.hideTimeEditor(true)">[ok]</span> '+
- ' <span class="rich-calendar-btn" onclick="$(\''+this.id+'\').component.hideTimeEditor(false)">[x]</span>';
- element.appendChild(div);
-
- var th=$(this.id+'TimeHours');
- var ts;
- var tm=$(this.id+'TimeMinutes');
- if (this.timeType==1)
- {
- sbjQuery(th).SpinButton({digits:this.timeHoursDigits,min:0,max:23});
- }
- else
- {
- sbjQuery(th).SpinButton({digits:this.timeHoursDigits,min:1,max:12});
- ts=$(this.id+'TimeSign');
- sbjQuery(ts).SpinButton({});
- }
- sbjQuery(tm).SpinButton({digits:2,min:0,max:59});
- }
-
+ var th=$(this.id+'TimeHours');
+ var ts=$(this.id+'TimeSign');
+ var tm=$(this.id+'TimeMinutes');
+
var h = this.selectedDate.getHours();
var m = this.selectedDate.getMinutes();
if (this.timeType==2)
@@ -689,13 +659,34 @@
}
th.value = (this.timeHoursDigits==2 && h<10 ? '0'+h : h);
tm.value = (m<10 ? '0'+m : m);
+ },
+
+ createTimeEditor: function(element)
+ {
+ var element = $(this.id);
+ var htmlBegin = '<div id="'+this.TIME_EDITOR_SHADOW_ID+'" class="rich-calendar-time-shadow" style="position:absolute; display:none;"></div><table border="0" cellpadding="0" cellspacing="0" id="'+this.TIME_EDITOR_ID+'" style="position:absolute; display:none;"><tbody><tr><td align="center">';
+ var htmlEndn = '</td></tr></tbody></table>';
+ new Insertion.After(element, htmlBegin+this.evaluateMarkup(CalendarView.timeEditor, this.calendarContext));
+ var te_shadow = $(this.TIME_EDITOR_SHADOW_ID);
+ var te = $(this.TIME_EDITOR_ID);
+ te.style.zIndex = te_shadow.style.zIndex = element.getStyle('z-index');
+
+ var th=$(this.id+'TimeHours');
+ var ts;
+ var tm=$(this.id+'TimeMinutes');
+ if (this.timeType==1)
+ {
+ sbjQuery(th).SpinButton({digits:this.timeHoursDigits,min:0,max:23});
+ }
+ else
+ {
+ sbjQuery(th).SpinButton({digits:this.timeHoursDigits,min:1,max:12});
+ ts=$(this.id+'TimeSign');
+ sbjQuery(ts).SpinButton({});
+ }
+ sbjQuery(tm).SpinButton({digits:2,min:0,max:59});
- div.style.width = element.clientWidth+'px';
- div.style.width = (element.clientWidth - (div.offsetWidth - element.clientWidth))+'px';
- div.style.top = (div.offsetTop - div.offsetHeight - element.offsetHeight)+'px';
- div.style.visibility='';
-
- return true;
+ this.isTimeEditorCreated = true;
},
setTimeProperties: function() {
@@ -754,12 +745,12 @@
this.timePatternHtml = timePattern.replace(/(^|[^\\Hhm])(H{1,2}|h{1,2}|m{2}|a)/g,
function($1,$2,$3) {
switch ($3) {
- case 'a' : return $2+'<input style="width:22px; margin: 0px 2px;" id="'+id+'TimeSign"/>';
+ case 'a' : return $2+'<input class="rich-calendar-time-input" id="'+id+'TimeSign"/>';
case 'H' :
case 'HH' :
case 'h' :
- case 'hh' : return $2+'<input style="width:22px; margin: 0px 2px;" id="'+id+'TimeHours"/>';
- case 'mm' : return $2+'<input style="width:22px; margin: 0px 2px;" id="'+id+'TimeMinutes"/>';
+ case 'hh' : return $2+'<input class="rich-calendar-time-input" id="'+id+'TimeHours"/>';
+ case 'mm' : return $2+'<input class="rich-calendar-time-input" id="'+id+'TimeMinutes"/>';
}
}
);
@@ -778,7 +769,7 @@
doCollapse: function() {
if (!this.params.popup || !this.isVisible) return;
- this.hideTimeEditor();
+ if (this.isTimeEditorCreated) this.hideTimeEditor();
/*this.stopTimer();
this.stopPopupEvents($(this.id));
@@ -1404,10 +1395,6 @@
renderHF: function()
{
- if (this.isTimeEditorCreated)
- {
- this.isTimeEditorCreated = false;
- }
this.renderMarkup(this.params.headerMarkup, this.id+"Header", this.calendarContext);
this.renderMarkup(this.params.footerMarkup, this.id+"Footer", this.calendarContext);
},
@@ -1522,9 +1509,14 @@
var oldSelectedDate = this.selectedDate;
var newSelectedDate;
+ var isDateParsed = false;
if (date)
{
- if (typeof date=='string') date = Richfaces.Calendar.parseDate(date,this.params.datePattern, this.params.monthLabels, this.params.monthLabelsShort);
+ if (typeof date=='string')
+ {
+ date = Richfaces.Calendar.parseDate(date,this.params.datePattern, this.params.monthLabels, this.params.monthLabelsShort);
+ if (date) isDateParsed = true;
+ }
newSelectedDate = date;
}
else
@@ -1547,11 +1539,17 @@
this.selectedDate = newSelectedDate;
if (this.selectedDate!=null)
{
- if (oldSelectedDate!=null)
- {
- this.selectedDate.setHours(oldSelectedDate.getHours());
- this.selectedDate.setMinutes(oldSelectedDate.getMinutes());
- }
+ if (!isDateParsed)
+ if (oldSelectedDate!=null)
+ {
+ this.selectedDate.setHours(oldSelectedDate.getHours());
+ this.selectedDate.setMinutes(oldSelectedDate.getMinutes());
+ }
+ else
+ {
+ this.selectedDate.setHours(12);
+ }
+
if (!this.showApplyButton) field.value=this.getSelectedDateString(this.params.datePattern);
var d = new Date(this.selectedDate);
@@ -1567,8 +1565,12 @@
this.selectedDateCellColor = this.getCellBackgroundColor(e);
Element.addClassName(e, "rich-calendar-select");
- this.renderHF(); }
- } else {
+ this.renderHF();
+ }
+ else if (this.timeType!=0) this.renderHF();
+ }
+ else
+ {
// change currentDate and call this.onUpdate();
d.setDate(1);
this.currentDate = d;
@@ -1659,21 +1661,30 @@
this.doCollapse();
},
- showTimeEditor: function(element)
+ showTimeEditor: function()
{
- if (this.isTimeEditorCreated)
- {
- this.hideTimeEditor();
- return;
- }
- if (this.createTimeEditor(element))
- {
- this.isTimeEditorCreated = true;
- }
+ if (this.timeType==0) return;
+ if (!this.isTimeEditorCreated) this.createTimeEditor();
+
+ var element = $(this.id);
+ var te = $(this.TIME_EDITOR_ID);
+ var te_shadow = $(this.TIME_EDITOR_SHADOW_ID);
+ var dim = Richfaces.Calendar.getOffsetDimensions(element);
+ te.style.width = te_shadow.style.width = dim.width + 'px';
+ te.style.height = te_shadow.style.height = dim.height + 'px';
+ te.style.left = te_shadow.style.left = element.style.left;
+ te.style.top = te_shadow.style.top = element.style.top;
+
+ this.updateTimeEditor();
+
+ te.show();
+ te_shadow.show();
},
hideTimeEditor: function(updateTime)
{
+ $(this.TIME_EDITOR_ID).hide();
+ $(this.TIME_EDITOR_SHADOW_ID).hide();
if (updateTime && this.selectedDate)
{
var m = parseInt($(this.id+'TimeMinutes').value,10);
@@ -1687,20 +1698,13 @@
}
else
{
- if (h!=12) h+=11;
+ if (h!=12) h+=12;
}
}
this.selectedDate.setHours(h);
this.renderHF();
}
- if (this.isTimeEditorCreated)
- {
- var e = $(this.TIME_EDITOR_ID);
- e.parentNode.removeChild(e);
- this.isTimeEditorCreated = false;
- }
-
if (this.params.popup && !this.showApplyButton && updateTime) this.close(true);
}
@@ -1733,7 +1737,7 @@
var text = Richfaces.Calendar.formatDate(calendar.selectedDate, calendar.timePattern, calendar.params.monthLabels, calendar.params.monthLabelsShort);
- var markup = new E('div', {'class': 'rich-calendar-tool-btn rich-calendar-tool-btn-hover rich-calendar-tool-btn-press', 'onclick': "Richfaces.getComponent('calendar',this).showTimeEditor(this);return true;",
+ var markup = new E('div', {'class': 'rich-calendar-tool-btn rich-calendar-tool-btn-hover rich-calendar-tool-btn-press', 'onclick': "Richfaces.getComponent('calendar',this).showTimeEditor();return true;",
'onmouseover': "Element.removeClassName(this, 'rich-calendar-tool-btn-press');",
'onmouseout' : "Element.addClassName(this, 'rich-calendar-tool-btn-press');"}, [new ET(text)]);
@@ -1750,8 +1754,9 @@
CalendarView.selectedDateControl = function (context) { return CalendarView.getSelectedDateControl(context.calendar);};
CalendarView.timeControl = function (context) { return CalendarView.getTimeControl(context.calendar);};
CalendarView.closeControl = CalendarView.getControl("x", CalendarView.toolButtonAttributes, "close", "false");
-CalendarView.applyControl = function (context) { return (context.calendar.showApplyButton ? CalendarView.getControl("OK", CalendarView.toolButtonAttributes, "close", "true") : "");};
+CalendarView.applyControl = function (context) { return (context.calendar.showApplyButton ? CalendarView.getControl("Apply", CalendarView.toolButtonAttributes, "close", "true") : "");};
CalendarView.cleanControl = function (context) { return (context.calendar.selectedDate ? CalendarView.getControl("Clean", CalendarView.toolButtonAttributes, "resetSelectedDate") : "");};
+CalendarView.timeEditorFields = function (context) { return context.calendar.timePatternHtml;};
CalendarView.header = [
new E('table',{'border': '0', 'cellpadding': '0', 'cellspacing': '0', 'width': '100%'},
@@ -1821,6 +1826,39 @@
])
]
)];
+
+CalendarView.timeEditor = [
+ new E('table',{'border': '0', 'cellpadding': '0', 'cellspacing': '0', 'class': 'rich-calendar-time-layout'},
+ [
+ new E('tbody',{},
+ [
+ new E('tr',{},
+ [
+ new E('td',{'class': 'rich-calendar-time-layout-fields', 'colspan': '2'},
+ [
+ new ET(function (context) { return Richfaces.evalMacro("timeEditorFields", context)})
+ ])
+ ]),
+ new E('tr',{},
+ [
+ new E('td',{'class': 'rich-calendar-time-layout-cancel'},
+ [
+ new E('div',{'class': 'rich-calendar-time-btn', 'style': 'float:right;', 'onmousedown': "Element.addClassName(this, 'rich-calendar-time-btn-press');", 'onmouseout': "Element.removeClassName(this, 'rich-calendar-time-btn-press');", 'onmouseup': "Element.removeClassName(this, 'rich-calendar-time-btn-press');", 'onclick': function(context){return "$('"+context.calendar.id+"').component.hideTimeEditor(false)";}},
+ [
+ new T('Cancel')
+ ])
+ ]),
+ new E('td',{'class': 'rich-calendar-time-layout-ok'},
+ [
+ new E('div',{'class': 'rich-calendar-time-btn', 'style': 'float:left;', 'onmousedown': "Element.addClassName(this, 'rich-calendar-time-btn-press');", 'onmouseout': "Element.removeClassName(this, 'rich-calendar-time-btn-press');", 'onmouseup': "Element.removeClassName(this, 'rich-calendar-time-btn-press');", 'onclick': function(context){return "$('"+context.calendar.id+"').component.hideTimeEditor(true)";}},
+ [
+ new T('Ok')
+ ])
+ ])
+ ])
+ ])
+ ])
+ ];
CalendarView.dayList = [new ET(function (context) { return context.day})];
CalendarView.weekNumber = [new ET(function (context) { return context.weekNumber})];
@@ -1846,5 +1884,6 @@
timeControl: CalendarView.timeControl,
todayControl: CalendarView.todayControl,
closeControl: CalendarView.closeControl,
- applyControl: CalendarView.applyControl
+ applyControl: CalendarView.applyControl,
+ timeEditorFields: CalendarView.timeEditorFields
});
\ No newline at end of file
17 years
JBoss Rich Faces SVN: r4394 - trunk/docs/userguide/en/src/main/docbook/included.
by richfaces-svn-commits@lists.jboss.org
Author: vkorluzhenko
Date: 2007-11-30 11:34:00 -0500 (Fri, 30 Nov 2007)
New Revision: 4394
Modified:
trunk/docs/userguide/en/src/main/docbook/included/poll.xml
trunk/docs/userguide/en/src/main/docbook/included/push.xml
Log:
http://jira.jboss.com/jira/browse/RF-657 - improved description.
Modified: trunk/docs/userguide/en/src/main/docbook/included/poll.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/poll.xml 2007-11-30 15:10:24 UTC (rev 4393)
+++ trunk/docs/userguide/en/src/main/docbook/included/poll.xml 2007-11-30 16:34:00 UTC (rev 4394)
@@ -66,7 +66,7 @@
</emphasis> componet is used for periodical polling of server data. In order to use the component
it's necessary to set an update interval. The <emphasis>
<property>"interval"</property>
- </emphasis> attribute defines an interval in milliseconds beetween the previous
+ </emphasis> attribute defines an interval in milliseconds between the previous
response and the next request. The total period beetween two requests generated by the
<emphasis role="bold">
<property><a4j:poll></property>
@@ -78,7 +78,7 @@
the <link linkend="creating">"Creating on a page" section</link>. </para>
<para>The <emphasis>
<property>"timeout"</property>
- </emphasis> attribute defines response wating time in milliseconds. If the response
+ </emphasis> attribute defines response waiting time in milliseconds. If a response
isn't received during this period a connection is aborted and the next request is
sent. Default value for <emphasis>
<property>"timeout"</property>
Modified: trunk/docs/userguide/en/src/main/docbook/included/push.xml
===================================================================
--- trunk/docs/userguide/en/src/main/docbook/included/push.xml 2007-11-30 15:10:24 UTC (rev 4393)
+++ trunk/docs/userguide/en/src/main/docbook/included/push.xml 2007-11-30 16:34:00 UTC (rev 4394)
@@ -49,30 +49,83 @@
<title>Key attributes and ways of usage</title>
<para>The <emphasis role="bold">
<property><a4j:push></property>
- </emphasis> component is similar to the <emphasis role="bold">
- <property><a4j:poll></property>
- </emphasis>
- <link linkend="poll_d"> one</link>. The main difference is that the<emphasis role="bold">
+ </emphasis> implements reverse Ajax technique. The component makes requests to minimal code
+ (not to JSF tree) in order to check presence of messages in a queue. If a message exists, a
+ complete request is performed. <emphasis role="bold">
+ <property><a4j:push></property>
+ </emphasis> registers <property>EventListener</property> in the bean,
+ which receives messages about an event presence.</para>
+
+ <para>The bean, for example, could be subscribed to Java Messaging Service (<ulink
+ url="http://java.sun.com/products/jms/">JMS</ulink>) topic or it could be implemented as
+ Message Driven Bean (MDB) in order to send a message to the <emphasis role="bold">
<property><a4j:push></property>
- </emphasis> makes request to minimal code (not to JSF tree) in order to check presence of
- messages in a queue. If a message exists, a complete request is performed. The component
- doesn't poll registered bean. It registers <property>EventListener</property>, which
- receives messages about event presence. See an example below:</para>
+ </emphasis> component about an event presence. In the presence of the event some action
+ occurs.</para>
+ <para>Thus, a work paradigm with the <emphasis role="bold">
+ <property><a4j:push></property>
+ </emphasis> component corresponds to an anisochronous model, but not to pools as for <emphasis
+ role="bold">
+ <property><a4j:poll></property>
+ </emphasis> component. See the simplest example below:</para>
+
<para>
<emphasis role="bold">Example:</emphasis>
</para>
- <programlisting role="XML"><![CDATA[<a4j:push reRender="msg" eventProducer="#{pushBean.addListener}" interval="2000"/>
+ <programlisting role="JAVA"><![CDATA[...
+class MyPushEventListener implements PushEventListener {
+ public void onEvent(EventObject evt) {
+ System.out.println(evt.getSource());
+ //Some action
+ }
+...
]]></programlisting>
- <para>In the example <emphasis>
+
+ <para>Code for <property>EventListener</property> registration in the bean is placed below:</para>
+ <para>
+ <emphasis role="bold">Example:</emphasis>
+ </para>
+ <programlisting role="JAVA"><![CDATA[...
+public void addListener(EventListener listener) {
+synchronized (listener) {
+ if (this.listener != listener) {
+ this.listener = (PushEventListener) listener;
+}
+...
+]]></programlisting>
+
+ <para>A page code for this example is placed below.</para>
+
+ <para>
+ <emphasis role="bold">Example:</emphasis>
+ </para>
+ <programlisting role="XML"><![CDATA[...
+ <a4j:status startText="in progress" stopText="done"/>
+ <a4j:form>
+ <a4j:region>
+ <a4j:push reRender="msg" eventProducer="#{pushBean.addListener}" interval="2000"/>
+ </a4j:region>
+ <a4j:outputPanel id="msg" >
+ <h:outputText value="#{pushBean.date}">
+ <f:convertDateTime type="time"/>
+ </h:outputText>
+ </a4j:outputPanel>
+ <a4j:commandButton value="Push!!" action="#{pushBean.push}" ajaxSingle="true"/>
+ </a4j:form>
+...
+]]></programlisting>
+
+ <para>The example shows how date is updated on a page in compliance with data taken from a
+ server. In the example <emphasis>
<property>"interval"</property>
</emphasis> attribute has value "2000". This attribute defines an interval
- in milliseconds beetween the previous response and the next request. Default value is set to
+ in milliseconds between the previous response and the next request. Default value is set to
"1000" milliseconds (1 second). It's possible to set value equal to
"0". In this case connection is permanent. </para>
<para>The <emphasis>
<property>"timeout"</property>
- </emphasis> attribute defines response wating time in milliseconds. If the response
+ </emphasis> attribute defines response waiting time in milliseconds. If a response
isn't received during this period a connection is aborted and the next request is
sent. Default value for <emphasis>
<property>"timeout"</property>
@@ -81,22 +134,11 @@
</emphasis> and <emphasis>
<property>"timeout"</property>
</emphasis> attributes gives an opportunity to set short polls of queue state or long
- connections or permanent connection generally.</para>
- <para>Code for <property>EventListener</property> registration in a bean is placed below:</para>
- <para>
- <emphasis role="bold">Example:</emphasis>
- </para>
- <programlisting role="JAVA"><![CDATA[...
-public void addListener(EventListener listener) {
-synchronized (listener) {
- if (this.listener != listener) {
- this.listener = (PushEventListener) listener;
-}
-...
-]]></programlisting>
+ connections, or permanent connection.</para>
-<para></para>
-
+ <note><title>Note:</title> The form around the <emphasis role="bold">
+ <property><a4j:push></property>
+ </emphasis> component is required.</note>
</section>
<!--section>
17 years
JBoss Rich Faces SVN: r4393 - branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2007-11-30 10:10:24 -0500 (Fri, 30 Nov 2007)
New Revision: 4393
Modified:
branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
Log:
reset of the active item
Modified: branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
===================================================================
--- branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 14:53:56 UTC (rev 4392)
+++ branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 15:10:24 UTC (rev 4393)
@@ -356,6 +356,13 @@
e = e || window.event;
this.focusKeeper.focused = false;
this.shuttleTable.className = Richfaces.ListBase.ORDERING_LIST_CLASSES.normal;
+
+ if (Richfaces.SelectItems.isSelected(this.activeItem)) {
+ Richfaces.SelectItems.doSelect(this.activeItem);
+ } else {
+ Richfaces.SelectItems.doNormal(this.activeItem);
+ }
+ this.activeItem = null;
},
compareByLabel : function(obj1, obj2) {
17 years
JBoss Rich Faces SVN: r4392 - branches/3.1.x/framework/impl/src/main/resources/org/ajax4jsf/javascript/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: maksimkaszynski
Date: 2007-11-30 09:53:56 -0500 (Fri, 30 Nov 2007)
New Revision: 4392
Modified:
branches/3.1.x/framework/impl/src/main/resources/org/ajax4jsf/javascript/scripts/form.js
Log:
http://jira.jboss.com/jira/browse/RF-1355
backported to 3.1.x branch
Modified: branches/3.1.x/framework/impl/src/main/resources/org/ajax4jsf/javascript/scripts/form.js
===================================================================
--- branches/3.1.x/framework/impl/src/main/resources/org/ajax4jsf/javascript/scripts/form.js 2007-11-30 14:53:50 UTC (rev 4391)
+++ branches/3.1.x/framework/impl/src/main/resources/org/ajax4jsf/javascript/scripts/form.js 2007-11-30 14:53:56 UTC (rev 4392)
@@ -6,21 +6,14 @@
function _JSFFormSubmit(linkId,formName,target,parameters){
var form = document.getElementById(formName);
if(form){
- var hiddenField = form.elements[formName+":_idcl"];
- if(hiddenField){
- hiddenField.value=linkId;
- } else {
- var input = document.createElement("input");
- input.type="hidden";
- input.name=formName+":_idcl";
- input.value=linkId;
- form.appendChild(input);
- }
+ var paramNames = [];
+
if(target){
form.target=target;
}
if(parameters){
for(var param in parameters){
+ paramNames.push(param);
if(form.elements[param]){
form.elements[param].value = parameters[param];
} else {
@@ -33,6 +26,8 @@
}
}
form.submit();
+ _clearJSFFormParameters(formName,target,paramNames);
+
} else {
alert("Form "+formName+" not found in document");
}
17 years
JBoss Rich Faces SVN: r4391 - branches/3.1.x/ui/core/src/main/java/org/ajax4jsf/renderkit/html.
by richfaces-svn-commits@lists.jboss.org
Author: maksimkaszynski
Date: 2007-11-30 09:53:50 -0500 (Fri, 30 Nov 2007)
New Revision: 4391
Modified:
branches/3.1.x/ui/core/src/main/java/org/ajax4jsf/renderkit/html/HtmlCommandLinkRenderer.java
Log:
http://jira.jboss.com/jira/browse/RF-1355
backported to 3.1.x branch
Modified: branches/3.1.x/ui/core/src/main/java/org/ajax4jsf/renderkit/html/HtmlCommandLinkRenderer.java
===================================================================
--- branches/3.1.x/ui/core/src/main/java/org/ajax4jsf/renderkit/html/HtmlCommandLinkRenderer.java 2007-11-30 14:47:13 UTC (rev 4390)
+++ branches/3.1.x/ui/core/src/main/java/org/ajax4jsf/renderkit/html/HtmlCommandLinkRenderer.java 2007-11-30 14:53:50 UTC (rev 4391)
@@ -61,7 +61,7 @@
protected void doDecode(FacesContext context, UIComponent component) {
UIForm form = getUtils().getNestingForm(context,component);
if(null != form){
- String hiddenFieldId = form.getClientId(context)+AjaxFormRenderer.HIDDEN_FIELD_SUFFIX;
+ String hiddenFieldId = getHiddenFieldId(context, form, component);
Object hiddenFieldValue;
if(null != (hiddenFieldValue=context.getExternalContext().getRequestParameterMap().get(hiddenFieldId))){
if(component.getClientId(context).equals(hiddenFieldValue)){
@@ -87,6 +87,10 @@
}
}
+ private String getHiddenFieldId(FacesContext context, UIForm form, UIComponent component) {
+ return form.getClientId(context)+AjaxFormRenderer.HIDDEN_FIELD_SUFFIX;
+ }
+
protected void doEncodeActiveBegin(ResponseWriter writer, FacesContext context, UIComponent component) throws IOException{
writer.startElement(HTML.a_ELEMENT,component);
getUtils().encodeId(context,component);
@@ -119,6 +123,9 @@
parameters.put(param.getName(),param.getValue());
}
}
+
+ parameters.put(getHiddenFieldId(context, form, component), component.getClientId(context));
+
submit.addParameter(parameters);
onclick.append("return ");
submit.appendScript(onclick);
17 years
JBoss Rich Faces SVN: r4390 - branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: vmolotkov
Date: 2007-11-30 09:47:13 -0500 (Fri, 30 Nov 2007)
New Revision: 4390
Modified:
branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
Log:
bug:RF-1463
Modified: branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js
===================================================================
--- branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 14:31:50 UTC (rev 4389)
+++ branches/3.1.x/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/ListBase.js 2007-11-30 14:47:13 UTC (rev 4390)
@@ -43,7 +43,7 @@
this.valueKeeper = $(valueKeeperId);
this.focusKeeper = $(focusKeeperId);
this.focusKeeper.focused = false;
- this.setFocus();
+ //this.setFocus();
this.focusKeeper.observe("keydown", (function(e) {this.onkeydownHandler(window.event || e)}).bindAsEventListener(this));
this.focusKeeper.observe("blur", function (e) {this.focusListener(e);}.bindAsEventListener(this));
17 years