JBoss Rich Faces SVN: r18399 - tags and 1 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: alexsmirnov
Date: 2010-08-03 15:51:02 -0400 (Tue, 03 Aug 2010)
New Revision: 18399
Added:
tags/4.0.0.Alpha2/
tags/4.0.0.Alpha2/commons/
Removed:
root/tags/richfaces-commons-4.0.0.Alpha2/
Log:
Move tag 4.0.0.Alpha2 to the global /tags folder
Copied: tags/4.0.0.Alpha2/commons (from rev 18398, root/tags/richfaces-commons-4.0.0.Alpha2)
15 years, 1 month
JBoss Rich Faces SVN: r18398 - in root/sandbox: examples/components/inputnumberslider-demo/src/main/webapp and 2 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-08-03 13:14:05 -0400 (Tue, 03 Aug 2010)
New Revision: 18398
Modified:
root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java
root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml
root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml
root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc
Log:
RF-8983
Modified: root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java
===================================================================
--- root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java 2010-08-03 17:01:07 UTC (rev 18397)
+++ root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java 2010-08-03 17:14:05 UTC (rev 18398)
@@ -30,7 +30,7 @@
@SessionScoped
public class Bean {
- private static final String[] SKINS = { "blueSky", "deepMarine", "emeraldTown", "NULL", "ruby", "classic",
+ private static final String[] SKINS = {"blueSky", "deepMarine", "emeraldTown", "NULL", "ruby", "classic",
"DEFAULT", "japanCherry", "plain", "wine" };
private String skin = "classic";
@@ -40,6 +40,7 @@
private boolean disabled = false;
private boolean enableManualInput = true;
private PositionType inputPosition = PositionType.right;
+ private int inputSize = 3;
private double maxValue = 100;
private double minValue = 0;
private boolean showArrows = false;
@@ -167,4 +168,12 @@
public boolean isDisabled() {
return disabled;
}
+
+ public void setInputSize(int inputSize) {
+ this.inputSize = inputSize;
+ }
+
+ public int getInputSize() {
+ return inputSize;
+ }
}
Modified: root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml
===================================================================
--- root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml 2010-08-03 17:01:07 UTC (rev 18397)
+++ root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml 2010-08-03 17:14:05 UTC (rev 18398)
@@ -41,9 +41,10 @@
<br />
<ins:inputnumberslider id="ins" value="#{bean.value}" accesskey="#{bean.accesskey}" delay="#{bean.delay}"
disabled="#{bean.disabled}" enableManualInput="#{bean.enableManualInput}"
- showArrows="#{bean.showArrows}" showBoundaryValues="#{bean.showBoundaryValues}"
- showInput="#{bean.showInput}" showToolTip="#{bean.showToolTip}" maxValue="#{bean.maxValue}"
- minValue="#{bean.minValue}" step="#{bean.step}" inputPosition="#{bean.inputPosition}"/>
+ inputPosition="#{bean.inputPosition}" inputSize="#{bean.inputSize}" showArrows="#{bean.showArrows}"
+ showBoundaryValues="#{bean.showBoundaryValues}" showInput="#{bean.showInput}"
+ showToolTip="#{bean.showToolTip}" maxValue="#{bean.maxValue}" minValue="#{bean.minValue}"
+ step="#{bean.step}" />
<br />
<h:outputText value="Accesskey: "/>
<h:inputText value="#{bean.accesskey}">
@@ -71,6 +72,11 @@
<f:ajax render="ins"/>
</h:selectOneMenu>
<br />
+ <h:outputText value="InputSize: "/>
+ <h:inputText value="#{bean.inputSize}">
+ <f:ajax render="ins"/>
+ </h:inputText>
+ <br />
<h:outputText value="MaxValue: "/>
<h:inputText value="#{bean.maxValue}">
<f:ajax render="ins"/>
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml 2010-08-03 17:01:07 UTC (rev 18397)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml 2010-08-03 17:14:05 UTC (rev 18398)
@@ -119,6 +119,14 @@
</property-extension>
</property>
<property>
+ <property-name>inputSize</property-name>
+ <property-class>int</property-class>
+ <default-value>3</default-value>
+ <property-extension>
+ <cdk:generate>true</cdk:generate>
+ </property-extension>
+ </property>
+ <property>
<property-name>maxValue</property-name>
<property-class>double</property-class>
<default-value>100</default-value>
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc 2010-08-03 17:01:07 UTC (rev 18397)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc 2010-08-03 17:14:05 UTC (rev 18398)
@@ -22,7 +22,8 @@
Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
02110-1301 USA, or see the FSF site: http://www.fsf.org.
-->
-<input name="#{clientId}" type="text" class="rf-ins-i #{component.attributes['inputClass']}" size="3" value="#{getInputValue(facesContext, component)}"
+<input name="#{clientId}" type="text" class="rf-ins-i #{component.attributes['inputClass']}"
+ size="#{component.attributes['inputSize']}" value="#{getInputValue(facesContext, component)}"
accesskey="#{component.attributes['accesskey']}" disabled="#{component.attributes['disabled']}"
readonly="#{!component.attributes['enableManualInput']}"
style="#{component.attributes['showInput'] ? null : 'display: none;'}" />
15 years, 1 month
JBoss Rich Faces SVN: r18397 - in root/sandbox/ui/inputs/inputnumberslider/src/main: templates and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-08-03 13:01:07 -0400 (Tue, 03 Aug 2010)
New Revision: 18397
Added:
root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc
Modified:
root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml
root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml
Log:
RF-8983
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml 2010-08-03 16:18:22 UTC (rev 18396)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml 2010-08-03 17:01:07 UTC (rev 18397)
@@ -104,6 +104,13 @@
</property-extension>
</property>
<property>
+ <property-name>inputClass</property-name>
+ <property-class>java.lang.String</property-class>
+ <property-extension>
+ <cdk:generate>true</cdk:generate>
+ </property-extension>
+ </property>
+ <property>
<property-name>inputPosition</property-name>
<property-class>org.richfaces.renderkit.html.PositionType</property-class>
<default-value>PositionType.right</default-value>
Added: root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc (rev 0)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/templates/input.template.inc 2010-08-03 17:01:07 UTC (rev 18397)
@@ -0,0 +1,28 @@
+<!--
+JBoss, Home of Professional Open Source
+Copyright ${year}, Red Hat, Inc. and individual contributors
+by the @authors tag. See the copyright.txt in the distribution for a
+full listing of individual contributors.
+
+
+This is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of
+the License, or (at your option) any later version.
+
+
+This software is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+
+You should have received a copy of the GNU Lesser General Public
+License along with this software; if not, write to the Free
+Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+02110-1301 USA, or see the FSF site: http://www.fsf.org.
+-->
+<input name="#{clientId}" type="text" class="rf-ins-i #{component.attributes['inputClass']}" size="3" value="#{getInputValue(facesContext, component)}"
+ accesskey="#{component.attributes['accesskey']}" disabled="#{component.attributes['disabled']}"
+ readonly="#{!component.attributes['enableManualInput']}"
+ style="#{component.attributes['showInput'] ? null : 'display: none;'}" />
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml 2010-08-03 16:18:22 UTC (rev 18396)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml 2010-08-03 17:01:07 UTC (rev 18397)
@@ -24,7 +24,8 @@
02110-1301 USA, or see the FSF site: http://www.fsf.org.
-->
<cdk:root xmlns="http://richfaces.org/cdk/xhtml-el" xmlns:cdk="http://richfaces.org/cdk/core"
- xmlns:cc="http://richfaces.org/cdk/jsf/composite" xmlns:c="http://richfaces.org/cdk/jstl/core">
+ xmlns:cc="http://richfaces.org/cdk/jsf/composite" xmlns:c="http://richfaces.org/cdk/jstl/core"
+ xmlns:xi="http://www.w3.org/2001/XInclude">
<cc:interface>
<cdk:class>org.richfaces.renderkit.html.InputNumberSliderRenderer</cdk:class>
<cdk:superclass>org.richfaces.renderkit.InputRendererBase</cdk:superclass>
@@ -42,10 +43,7 @@
<span id="#{clientId}" class="rf-ins">
<c:if test="#{PositionType.valueOf('left') == component.attributes['inputPosition']
|| PositionType.valueOf('top') == component.attributes['inputPosition']}">
- <input name="#{clientId}" type="text" class="rf-ins-i" size="3"
- value="#{getInputValue(facesContext, component)}" accesskey="#{component.attributes['accesskey']}"
- disabled="#{component.attributes['disabled']}" readonly="#{!component.attributes['enableManualInput']}"
- style="#{component.attributes['showInput'] ? null : 'display: none;'}" />
+ <xi:include xpointer="xpointer(//input)" href="input.template.inc" />
<c:if test="#{PositionType.valueOf('top') == component.attributes['inputPosition'] and component.attributes['showInput']}">
<br />
</c:if>
@@ -70,10 +68,7 @@
<c:if test="#{PositionType.valueOf('bottom') == component.attributes['inputPosition'] and component.attributes['showInput']}">
<br />
</c:if>
- <input name="#{clientId}" type="text" class="rf-ins-i" size="3"
- value="#{getInputValue(facesContext, component)}" accesskey="#{component.attributes['accesskey']}"
- disabled="#{component.attributes['disabled']}" readonly="#{!component.attributes['enableManualInput']}"
- style="#{component.attributes['showInput'] ? null : 'display: none;'}" />
+ <xi:include xpointer="xpointer(//input)" href="input.template.inc" />
</c:if>
<c:if test="#{component.attributes['showToolTip']}">
<span class="rf-ins-tt #{component.attributes['toolTipClass']}">#{getInputValue(facesContext, component)}</span>
15 years, 1 month
JBoss Rich Faces SVN: r18396 - in root/sandbox: examples/components/inputnumberslider-demo/src/main/webapp and 4 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-08-03 12:18:22 -0400 (Tue, 03 Aug 2010)
New Revision: 18396
Added:
root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowBottom.java
root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowLeft.java
root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowRight.java
Modified:
root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java
root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml
root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml
root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.ecss
root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.js
root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml
Log:
RF-8983
Modified: root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java
===================================================================
--- root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java 2010-08-03 13:56:28 UTC (rev 18395)
+++ root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java 2010-08-03 16:18:22 UTC (rev 18396)
@@ -37,6 +37,7 @@
private double value;
private String accesskey;
private int delay = 200;
+ private boolean disabled = false;
private boolean enableManualInput = true;
private PositionType inputPosition = PositionType.right;
private double maxValue = 100;
@@ -158,4 +159,12 @@
public String[] getSkins() {
return SKINS;
}
+
+ public void setDisabled(boolean disabled) {
+ this.disabled = disabled;
+ }
+
+ public boolean isDisabled() {
+ return disabled;
+ }
}
Modified: root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml
===================================================================
--- root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml 2010-08-03 13:56:28 UTC (rev 18395)
+++ root/sandbox/examples/components/inputnumberslider-demo/src/main/webapp/index.xhtml 2010-08-03 16:18:22 UTC (rev 18396)
@@ -39,11 +39,11 @@
<f:selectItems value="#{bean.skins}"/>
</h:selectOneMenu>
<br />
- <ins:inputnumberslider id="ins" value="#{bean.value}" accesskey="#{bean.accesskey}"
- delay="#{bean.delay}" enableManualInput="#{bean.enableManualInput}" showArrows="#{bean.showArrows}"
- showBoundaryValues="#{bean.showBoundaryValues}" showInput="#{bean.showInput}"
- showToolTip="#{bean.showToolTip}" maxValue="#{bean.maxValue}" minValue="#{bean.minValue}"
- step="#{bean.step}" inputPosition="#{bean.inputPosition}"/>
+ <ins:inputnumberslider id="ins" value="#{bean.value}" accesskey="#{bean.accesskey}" delay="#{bean.delay}"
+ disabled="#{bean.disabled}" enableManualInput="#{bean.enableManualInput}"
+ showArrows="#{bean.showArrows}" showBoundaryValues="#{bean.showBoundaryValues}"
+ showInput="#{bean.showInput}" showToolTip="#{bean.showToolTip}" maxValue="#{bean.maxValue}"
+ minValue="#{bean.minValue}" step="#{bean.step}" inputPosition="#{bean.inputPosition}"/>
<br />
<h:outputText value="Accesskey: "/>
<h:inputText value="#{bean.accesskey}">
@@ -55,6 +55,11 @@
<f:ajax render="ins"/>
</h:selectBooleanCheckbox>
<br />
+ <h:outputText value="Disabled "/>
+ <h:selectBooleanCheckbox value="#{bean.disabled}">
+ <f:ajax render="ins"/>
+ </h:selectBooleanCheckbox>
+ <br />
<h:outputText value="Delay: "/>
<h:inputText value="#{bean.delay}">
<f:ajax render="ins"/>
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml 2010-08-03 13:56:28 UTC (rev 18395)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/config/faces-config.xml 2010-08-03 16:18:22 UTC (rev 18396)
@@ -60,6 +60,14 @@
</property-extension>
</property>
<property>
+ <property-name>disabled</property-name>
+ <property-class>boolean</property-class>
+ <default-value>false</default-value>
+ <property-extension>
+ <cdk:generate>true</cdk:generate>
+ </property-extension>
+ </property>
+ <property>
<property-name>enableManualInput</property-name>
<property-class>boolean</property-class>
<default-value>true</default-value>
Added: root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowBottom.java
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowBottom.java (rev 0)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowBottom.java 2010-08-03 16:18:22 UTC (rev 18396)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright ${year}, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.richfaces.renderkit.html.images;
+
+
+/**
+ * @author Konstantin Mishin
+ *
+ */
+public class SliderDisabledArrowBottom extends SliderArrowBottom {
+
+ public SliderDisabledArrowBottom() {
+ setColorName("tabDisabledTextColor");
+ }
+}
Added: root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowLeft.java
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowLeft.java (rev 0)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowLeft.java 2010-08-03 16:18:22 UTC (rev 18396)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright ${year}, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.richfaces.renderkit.html.images;
+
+
+/**
+ * @author Konstantin Mishin
+ *
+ */
+public class SliderDisabledArrowLeft extends SliderArrowLeft {
+
+ public SliderDisabledArrowLeft() {
+ setColorName("tabDisabledTextColor");
+ }
+}
Added: root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowRight.java
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowRight.java (rev 0)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/java/org/richfaces/renderkit/html/images/SliderDisabledArrowRight.java 2010-08-03 16:18:22 UTC (rev 18396)
@@ -0,0 +1,35 @@
+/*
+ * JBoss, Home of Professional Open Source
+ * Copyright ${year}, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ */
+
+package org.richfaces.renderkit.html.images;
+
+
+/**
+ * @author Konstantin Mishin
+ *
+ */
+public class SliderDisabledArrowRight extends SliderArrowRight {
+
+ public SliderDisabledArrowRight() {
+ setColorName("tabDisabledTextColor");
+ }
+}
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.ecss
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.ecss 2010-08-03 13:56:28 UTC (rev 18395)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.ecss 2010-08-03 16:18:22 UTC (rev 18396)
@@ -77,7 +77,7 @@
clear: both;
}
-.rf-ins-h, .rf-ins-db, .rf-ins-ib {
+.rf-ins-h, .rf-ins-db, .rf-ins-ib, .rf-ins-h-d, .rf-ins-db-d, .rf-ins-ib-d {
display: inline-block;
width: 7px;
height: 7px;
@@ -91,6 +91,10 @@
background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderSelectedArrowBottom']}");
}
+.rf-ins-h-d {
+ background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderDisabledArrowBottom']}");
+}
+
.rf-ins-db {
background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderArrowLeft']}");
}
@@ -99,10 +103,18 @@
background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderSelectedArrowLeft']}");
}
+.rf-ins-db-d {
+ background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderDisabledArrowLeft']}");
+}
+
.rf-ins-ib {
background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderArrowRight']}");
}
.rf-ins-ib-s {
background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderSelectedArrowRight']}");
+}
+
+.rf-ins-ib-d {
+ background-image: url("#{resource['org.richfaces.renderkit.html.images.SliderDisabledArrowRight']}");
}
\ No newline at end of file
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.js
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.js 2010-08-03 13:56:28 UTC (rev 18395)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/resources/META-INF/resources/inputNumberSlider.js 2010-08-03 16:18:22 UTC (rev 18396)
@@ -37,32 +37,50 @@
init: function (id, options, selectedClasses) {
jQuery.extend(this, options);
- for (var i in selectedClasses) {
- this[i] += " " + selectedClasses[i];
- }
this.range = this.maxValue - this.minValue;
this.id = id;
this.element = jQuery(this.attachToDom());
this.input = this.element.children(".rf-ins-i");
this.track = this.element.children(".rf-ins-ta").children(".rf-ins-t");
- this.handle = this.track.children(".rf-ins-h");
+ this.handle = this.track.children(".rf-ins-h, .rf-ins-h-d");
this.tooltip = this.element.children(".rf-ins-tt");
- this.decrease = this.element.children(".rf-ins-db");
- this.increase = this.element.children(".rf-ins-ib");
-
+
this.__inputHandler();
- this.track[0].tabIndex = 0;
-
- var proxy = jQuery.proxy(this.__inputHandler, this)
- this.input.change(proxy);
- this.input.submit(proxy);
- this.track.keydown(jQuery.proxy(this.__keydownHandler, this));
- this.decrease.mousedown(jQuery.proxy(this.__decreaseHandler, this));
- this.increase.mousedown(jQuery.proxy(this.__increaseHandler, this));
- this.track.mousedown(jQuery.proxy(this.__mousedownHandler, this));
+
+ if (!this.disabled) {
+ this.decreaseButton = this.element.children(".rf-ins-db");
+ this.increaseButton = this.element.children(".rf-ins-ib");
+
+ this.track[0].tabIndex = 0;
+
+ for (var i in selectedClasses) {
+ this[i] += " " + selectedClasses[i];
+ }
+ var proxy = jQuery.proxy(this.__inputHandler, this)
+ this.input.change(proxy);
+ this.input.submit(proxy);
+ this.track.keydown(jQuery.proxy(this.__keydownHandler, this));
+ this.decreaseButton.mousedown(jQuery.proxy(this.__decreaseHandler, this));
+ this.increaseButton.mousedown(jQuery.proxy(this.__increaseHandler, this));
+ this.track.mousedown(jQuery.proxy(this.__mousedownHandler, this));
+ }
},
+ decrease: function (event) {
+ this.setValue(this.value - this.step);
+ },
+
+ increase: function (event) {
+ this.setValue(this.value + this.step);
+ },
+
setValue: function (value) {
+ if (!this.disabled) {
+ this.__setValue(value);
+ }
+ },
+
+ __setValue: function (value) {
if (!isNaN(value)) {
value = Math.round(value / this.step) * this.step; //TODO Add normal support of float values. E.g. '0.3' should be instead of '0.30000000000000004'.
if (value > this.maxValue) {
@@ -86,46 +104,48 @@
if (isNaN(value)) {
this.input.val(this.value);
} else {
- this.setValue(value);
+ this.__setValue(value);
}
},
__keydownHandler: function (event) {
if (event.keyCode == 37) { //LEFT
- this.setValue(Number(this.input.val()) - this.step);
+ this.__setValue(Number(this.input.val()) - this.step);
event.preventDefault();
} else if (event.keyCode == 39) { //RIGHT
- this.setValue(Number(this.input.val()) + this.step);
+ this.__setValue(Number(this.input.val()) + this.step);
event.preventDefault();
}
},
__decreaseHandler: function (event) {
var component = this;
+ component.decrease();
this.intervalId = window.setInterval(function() {
- component.setValue(Number(component.input.val()) - component.step);
+ component.decrease();
}, this.delay);
jQuery(document).one("mouseup", true, jQuery.proxy(this.__clearInterval, this));
- this.decrease.addClass(this.decreaseSelectedClass);
+ this.decreaseButton.addClass(this.decreaseSelectedClass);
event.preventDefault();
},
__increaseHandler: function (event) {
var component = this;
+ component.increase();
this.intervalId = window.setInterval(function() {
- component.setValue(Number(component.input.val()) + component.step);
+ component.increase();
}, this.delay);
jQuery(document).one("mouseup",jQuery.proxy(this.__clearInterval, this));
- this.increase.addClass(this.increaseSelectedClass);
+ this.increaseButton.addClass(this.increaseSelectedClass);
event.preventDefault();
},
__clearInterval: function (event) {
window.clearInterval(this.intervalId);
- if (event.data) { // decrease
- this.decrease.removeClass(this.decreaseSelectedClass);
+ if (event.data) { // decreaseButton
+ this.decreaseButton.removeClass(this.decreaseSelectedClass);
} else {
- this.increase.removeClass(this.increaseSelectedClass);
+ this.increaseButton.removeClass(this.increaseSelectedClass);
}
},
@@ -142,7 +162,7 @@
__mousemoveHandler: function (event) {
var value = this.range * (event.pageX - this.track.position().left) / (this.track.width()
- this.handle.width()) + this.minValue;
- this.setValue(value);
+ this.__setValue(value);
event.preventDefault();
},
Modified: root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml
===================================================================
--- root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml 2010-08-03 13:56:28 UTC (rev 18395)
+++ root/sandbox/ui/inputs/inputnumberslider/src/main/templates/inputnumberslider.template.xml 2010-08-03 16:18:22 UTC (rev 18396)
@@ -44,14 +44,14 @@
|| PositionType.valueOf('top') == component.attributes['inputPosition']}">
<input name="#{clientId}" type="text" class="rf-ins-i" size="3"
value="#{getInputValue(facesContext, component)}" accesskey="#{component.attributes['accesskey']}"
- readonly="#{!component.attributes['enableManualInput']}"
+ disabled="#{component.attributes['disabled']}" readonly="#{!component.attributes['enableManualInput']}"
style="#{component.attributes['showInput'] ? null : 'display: none;'}" />
<c:if test="#{PositionType.valueOf('top') == component.attributes['inputPosition'] and component.attributes['showInput']}">
<br />
</c:if>
</c:if>
<c:if test="#{component.attributes['showArrows']}">
- <a class="rf-ins-db #{component.attributes['decreaseClass']}" href="javascript:void(0);" />
+ <span class="rf-ins-db#{component.attributes['disabled'] ? '-d' : ''} #{component.attributes['decreaseClass']}" />
</c:if>
<span class="rf-ins-ta">
<c:if test="#{component.attributes['showBoundaryValues']}">
@@ -59,11 +59,11 @@
<span class="rf-ins-mx">#{component.attributes['maxValue']}</span>
</c:if>
<span class="rf-ins-t #{component.attributes['trackClass']}">
- <span class="rf-ins-h #{component.attributes['handleClass']}" />
+ <span class="rf-ins-h#{component.attributes['disabled'] ? '-d' : ''} #{component.attributes['handleClass']}" />
</span>
</span>
<c:if test="#{component.attributes['showArrows']}">
- <a class="rf-ins-ib #{component.attributes['increaseClass']}" href="javascript:void(0);" />
+ <span class="rf-ins-ib#{component.attributes['disabled'] ? '-d' : ''} #{component.attributes['increaseClass']}" />
</c:if>
<c:if test="#{PositionType.valueOf('right') == component.attributes['inputPosition']
|| PositionType.valueOf('bottom') == component.attributes['inputPosition']}">
@@ -72,7 +72,7 @@
</c:if>
<input name="#{clientId}" type="text" class="rf-ins-i" size="3"
value="#{getInputValue(facesContext, component)}" accesskey="#{component.attributes['accesskey']}"
- readonly="#{!component.attributes['enableManualInput']}"
+ disabled="#{component.attributes['disabled']}" readonly="#{!component.attributes['enableManualInput']}"
style="#{component.attributes['showInput'] ? null : 'display: none;'}" />
</c:if>
<c:if test="#{component.attributes['showToolTip']}">
@@ -80,6 +80,7 @@
</c:if>
<script type="text/javascript">new RichFaces.ui.InputNumberSlider('#{clientId}', {
delay: #{component.attributes['delay']},
+ disabled: #{component.attributes['disabled']},
maxValue: #{component.attributes['maxValue']},
minValue: #{component.attributes['minValue']},
step: #{component.attributes['step']}
15 years, 1 month
JBoss Rich Faces SVN: r18395 - trunk/cdk/plugins/xinclude/src/main/java/org/apache/cocoon/pipeline/component/sax.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2010-08-03 09:56:28 -0400 (Tue, 03 Aug 2010)
New Revision: 18395
Modified:
trunk/cdk/plugins/xinclude/src/main/java/org/apache/cocoon/pipeline/component/sax/XIncludeTransformer.java
Log:
Fixed bug in XInclude module
Modified: trunk/cdk/plugins/xinclude/src/main/java/org/apache/cocoon/pipeline/component/sax/XIncludeTransformer.java
===================================================================
--- trunk/cdk/plugins/xinclude/src/main/java/org/apache/cocoon/pipeline/component/sax/XIncludeTransformer.java 2010-08-03 13:42:09 UTC (rev 18394)
+++ trunk/cdk/plugins/xinclude/src/main/java/org/apache/cocoon/pipeline/component/sax/XIncludeTransformer.java 2010-08-03 13:56:28 UTC (rev 18395)
@@ -18,6 +18,12 @@
*/
package org.apache.cocoon.pipeline.component.sax;
+import java.io.IOException;
+import java.net.URI;
+import java.util.HashMap;
+import java.util.Map;
+import java.util.Map.Entry;
+
import org.apache.cocoon.pipeline.component.xpointer.XPointer;
import org.apache.cocoon.pipeline.component.xpointer.XPointerContext;
import org.apache.cocoon.pipeline.component.xpointer.parser.ParseException;
@@ -33,12 +39,6 @@
import org.xml.sax.ext.LexicalHandler;
import org.xml.sax.helpers.XMLReaderFactory;
-import java.io.IOException;
-import java.net.URI;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.Map.Entry;
-
public final class XIncludeTransformer implements SAXConsumer {
private static final String DEFAULT_CHARSET = "UTF-8";
private static final String HTTP_ACCEPT = "Accept";
@@ -399,8 +399,11 @@
public void endPrefixMapping(String prefix) throws SAXException {
if (isEvaluatingContent()) {
- getContentHandler().endPrefixMapping(prefix);
- namespaces.remove(prefix);
+ String uri = namespaces.remove(prefix);
+
+ if (!XINCLUDE_NAMESPACE_URI.equals(uri)) {
+ getContentHandler().endPrefixMapping(prefix);
+ }
}
}
15 years, 1 month
JBoss Rich Faces SVN: r18394 - root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo.
by richfaces-svn-commits@lists.jboss.org
Author: konstantin.mishin
Date: 2010-08-03 09:42:09 -0400 (Tue, 03 Aug 2010)
New Revision: 18394
Modified:
root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java
Log:
small fix
Modified: root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java
===================================================================
--- root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java 2010-08-03 12:02:37 UTC (rev 18393)
+++ root/sandbox/examples/components/inputnumberslider-demo/src/main/java/org/richfaces/demo/Bean.java 2010-08-03 13:42:09 UTC (rev 18394)
@@ -30,8 +30,9 @@
@SessionScoped
public class Bean {
+ private static final String[] SKINS = { "blueSky", "deepMarine", "emeraldTown", "NULL", "ruby", "classic",
+ "DEFAULT", "japanCherry", "plain", "wine" };
private String skin = "classic";
- private final String[] SKINS = {"blueSky", "deepMarine", "emeraldTown", "NULL", "ruby", "classic", "DEFAULT", "japanCherry", "plain", "wine"};
private double value;
private String accesskey;
15 years, 1 month
JBoss Rich Faces SVN: r18393 - in root/tests/metamer/trunk/application/src/main: webapp/components and 1 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: ppitonak(a)redhat.com
Date: 2010-08-03 08:02:37 -0400 (Tue, 03 Aug 2010)
New Revision: 18393
Added:
root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JAttachQueueBean.java
root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/
root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/list.xhtml
root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/simple.xhtml
root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/wrapped.xhtml
Modified:
root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java
root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java
Log:
RFPL-734
* a4j:attachQueue added
* unnecessary logging removed from A4JQueueBean
Added: root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JAttachQueueBean.java
===================================================================
--- root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JAttachQueueBean.java (rev 0)
+++ root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JAttachQueueBean.java 2010-08-03 12:02:37 UTC (rev 18393)
@@ -0,0 +1,102 @@
+/*******************************************************************************
+ * JBoss, Home of Professional Open Source
+ * Copyright 2010, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ *******************************************************************************/
+package org.richfaces.tests.metamer.bean;
+
+import java.io.Serializable;
+
+import javax.annotation.PostConstruct;
+import javax.faces.bean.ManagedBean;
+import javax.faces.bean.ViewScoped;
+import org.richfaces.component.UIAttachQueue;
+
+import org.richfaces.tests.metamer.Attributes;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Managed bean for a4j:attachQueue.
+ *
+ * @author <a href="mailto:ppitonak@redhat.com">Pavol Pitonak</a>
+ * @version $Revision$
+ */
+@ManagedBean(name = "a4jAttachQueueBean")
+@ViewScoped
+public class A4JAttachQueueBean implements Serializable {
+
+ private static final long serialVersionUID = -1L;
+ private static Logger logger;
+ private Attributes attributes;
+ private Attributes attributes2;
+ private String text1;
+ private String text2;
+
+ /**
+ * Initializes the managed bean.
+ */
+ @PostConstruct
+ public void init() {
+ logger = LoggerFactory.getLogger(getClass());
+ logger.info("initializing bean " + getClass().getName());
+
+ // initialize attributes
+ attributes = Attributes.getUIComponentAttributes(UIAttachQueue.class, getClass());
+ attributes.setAttribute("rendered", true);
+ attributes.setAttribute("requestDelay", 1500);
+
+ attributes2 = Attributes.getUIComponentAttributes(UIAttachQueue.class, getClass());
+ attributes2.setAttribute("rendered", true);
+ attributes2.setAttribute("requestDelay", 1500);
+
+ }
+
+ public Attributes getAttributes() {
+ return attributes;
+ }
+
+ public void setAttributes(Attributes attributes) {
+ this.attributes = attributes;
+ }
+
+ public Attributes getAttributes2() {
+ return attributes2;
+ }
+
+ public void setAttributes2(Attributes attributes2) {
+ this.attributes2 = attributes2;
+ }
+
+ public String getText1() {
+ return text1;
+ }
+
+ public void setText1(String text1) {
+ this.text1 = text1;
+ }
+
+ public String getText2() {
+ return text2;
+ }
+
+ public void setText2(String text2) {
+ this.text2 = text2;
+ }
+}
Property changes on: root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JAttachQueueBean.java
___________________________________________________________________
Name: svn:keywords
+ Revision
Modified: root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java
===================================================================
--- root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java 2010-08-03 09:43:58 UTC (rev 18392)
+++ root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java 2010-08-03 12:02:37 UTC (rev 18393)
@@ -75,7 +75,6 @@
}
public void setText(String text) {
- logger.error("setText " + text);
this.text = text;
}
}
Modified: root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java
===================================================================
--- root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java 2010-08-03 09:43:58 UTC (rev 18392)
+++ root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java 2010-08-03 12:02:37 UTC (rev 18393)
@@ -92,6 +92,7 @@
components.put("a4jActionListener", "A4J Action Listener");
components.put("a4jAjax", "A4J Ajax");
+ components.put("a4jAttachQueue", "A4J Attach Queue");
components.put("a4jCommandLink", "A4J Command Link");
components.put("a4jCommandButton", "A4J Command Button");
components.put("a4jJSFunction", "A4J JavaScript Function");
Added: root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/list.xhtml
===================================================================
--- root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/list.xhtml (rev 0)
+++ root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/list.xhtml 2010-08-03 12:02:37 UTC (rev 18393)
@@ -0,0 +1,45 @@
+<!--
+JBoss, Home of Professional Open Source
+Copyright 2010, Red Hat, Inc. and individual contributors
+by the @authors tag. See the copyright.txt in the distribution for a
+full listing of individual contributors.
+
+This is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of
+the License, or (at your option) any later version.
+
+This software is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this software; if not, write to the Free
+Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+02110-1301 USA, or see the FSF site: http://www.fsf.org.
+-->
+
+<!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:ta="http://java.sun.com/jsf/composite/testapp">
+
+ <ui:composition template="/templates/list.xhtml">
+
+ <ui:define name="pageTitle">A4J Attach Queue</ui:define>
+
+ <ui:define name="links">
+
+ <ta:testPageLink id="simple" outcome="simple" value="Simple">
+ Page containing <b>a4j:attachQueue</b>, two inputs and input boxes for all its attributes.
+ </ta:testPageLink>
+
+ <ta:testPageLink id="wrapped" outcome="wrapped" value="Wrapped">
+ Page containing <b>a4j:attachQueue</b>, a4j:ajax wrapping two inputs and input boxes for all its attributes.
+ </ta:testPageLink>
+
+ </ui:define>
+
+ </ui:composition>
+
+</html>
Added: root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/simple.xhtml
===================================================================
--- root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/simple.xhtml (rev 0)
+++ root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/simple.xhtml 2010-08-03 12:02:37 UTC (rev 18393)
@@ -0,0 +1,125 @@
+<!--
+JBoss, Home of Professional Open Source
+Copyright 2010, Red Hat, Inc. and individual contributors
+by the @authors tag. See the copyright.txt in the distribution for a
+full listing of individual contributors.
+
+This is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of
+the License, or (at your option) any later version.
+
+This software is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this software; if not, write to the Free
+Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+02110-1301 USA, or see the FSF site: http://www.fsf.org.
+-->
+
+<!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:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:ta="http://java.sun.com/jsf/composite/testapp" xmlns:rich="http://richfaces.org/rich">
+
+ <ui:composition template="/templates/template.xhtml">
+
+ <ui:define name="head">
+ <f:metadata>
+ <f:viewParam name="templates" value="#{templateBean.templates}">
+ <f:converter converterId="templatesListConverter" />
+ </f:viewParam>
+ </f:metadata>
+
+ <script type="text/javascript">
+ var events = 0;
+ var updates = 0;
+ var requests = 0;
+
+ function addEvent() {
+ events++;
+ }
+ function addUpdate() {
+ updates++;
+ }
+ function addRequest() {
+ requests++;
+ }
+
+ function printCounts() {
+ #{rich:element('events')}.innerHTML=events;
+ #{rich:element('updates')}.innerHTML=updates;
+ #{rich:element('requests')}.innerHTML=requests;
+ }
+ </script>
+ </ui:define>
+
+ <ui:define name="outOfTemplateBefore">
+ </ui:define>
+
+ <ui:define name="component">
+ <a4j:queue id="queue1"/>
+ <a4j:queue id="queue2"/>
+
+ <h:inputText id="input1" value="#{a4jAttachQueueBean.text1}" onkeyup="addEvent();">
+ <a4j:ajax event="keyup" render="output1" execute="@form" onbegin="addRequest();"
+ oncomplete="printCounts()" onbeforedomupdate="addUpdate()">
+ <a4j:attachQueue id="a4jAttachQueue1"
+ ignoreDupResponses="#{a4jAttachQueueBean.attributes['ignoreDupResponses'].value}"
+ name="#{a4jAttachQueueBean.attributes['name'].value}"
+ onrequestdequeue="#{a4jAttachQueueBean.attributes['onrequestdequeue'].value}"
+ onrequestqueue="#{a4jAttachQueueBean.attributes['onrequestqueue'].value}"
+ queueId="#{a4jAttachQueueBean.attributes['queueId'].value}"
+ rendered="#{a4jAttachQueueBean.attributes['rendered'].value}"
+ requestDelay="#{a4jAttachQueueBean.attributes['requestDelay'].value}"
+ requestGroupingId="#{a4jAttachQueueBean.attributes['requestGroupingId'].value}"
+ timeout="#{a4jAttachQueueBean.attributes['timeout'].value}"/>
+ </a4j:ajax>
+ </h:inputText>
+
+ <h:inputText id="input2" value="#{a4jAttachQueueBean.text2}" onkeyup="addEvent();">
+ <a4j:ajax event="keyup" render="output1" execute="@form" onbegin="addRequest();"
+ oncomplete="printCounts()" onbeforedomupdate="addUpdate()">
+ <a4j:attachQueue id="a4jAttachQueue2"
+ ignoreDupResponses="#{a4jAttachQueueBean.attributes2['ignoreDupResponses'].value}"
+ name="#{a4jAttachQueueBean.attributes2['name'].value}"
+ onrequestdequeue="#{a4jAttachQueueBean.attributes2['onrequestdequeue'].value}"
+ onrequestqueue="#{a4jAttachQueueBean.attributes2['onrequestqueue'].value}"
+ queueId="#{a4jAttachQueueBean.attributes2['queueId'].value}"
+ rendered="#{a4jAttachQueueBean.attributes2['rendered'].value}"
+ requestDelay="#{a4jAttachQueueBean.attributes2['requestDelay'].value}"
+ requestGroupingId="#{a4jAttachQueueBean.attributes2['requestGroupingId'].value}"
+ timeout="#{a4jAttachQueueBean.attributes2['timeout'].value}"/>
+ </a4j:ajax>
+ </h:inputText>
+
+ <h:panelGrid columns="2">
+ Output 1:
+ <h:outputText id="output1" value="#{a4jAttachQueueBean.text1}" style="font-weight:bold;"/>
+ Output 2:
+ <h:outputText id="output2" value="#{a4jAttachQueueBean.text2}" style="font-weight:bold;"/>
+ Events count:
+ <h:outputText value="0" id="events" />
+ Requests count:
+ <h:outputText value="0" id="requests" />
+ DOM updates count:
+ <h:outputText value="0" id="updates" />
+ </h:panelGrid>
+
+ </ui:define>
+
+ <ui:define name="outOfTemplateAfter">
+ Attributes for first attach queue (first input)
+ <br/>
+ <ta:attributes value="#{a4jAttachQueueBean.attributes}" id="attributes" />
+ <br/>
+ Attributes for second attach queue (second input)
+ <br/>
+ <ta:attributes value="#{a4jAttachQueueBean.attributes2}" id="attributes2" />
+ </ui:define>
+
+ </ui:composition>
+</html>
\ No newline at end of file
Added: root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/wrapped.xhtml
===================================================================
--- root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/wrapped.xhtml (rev 0)
+++ root/tests/metamer/trunk/application/src/main/webapp/components/a4jAttachQueue/wrapped.xhtml 2010-08-03 12:02:37 UTC (rev 18393)
@@ -0,0 +1,104 @@
+<!--
+JBoss, Home of Professional Open Source
+Copyright 2010, Red Hat, Inc. and individual contributors
+by the @authors tag. See the copyright.txt in the distribution for a
+full listing of individual contributors.
+
+This is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of
+the License, or (at your option) any later version.
+
+This software is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this software; if not, write to the Free
+Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+02110-1301 USA, or see the FSF site: http://www.fsf.org.
+-->
+
+<!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:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:ta="http://java.sun.com/jsf/composite/testapp" xmlns:rich="http://richfaces.org/rich">
+
+ <ui:composition template="/templates/template.xhtml">
+
+ <ui:define name="head">
+ <f:metadata>
+ <f:viewParam name="templates" value="#{templateBean.templates}">
+ <f:converter converterId="templatesListConverter" />
+ </f:viewParam>
+ </f:metadata>
+
+ <script type="text/javascript">
+ var events = 0;
+ var updates = 0;
+ var requests = 0;
+
+ function addEvent() {
+ events++;
+ }
+ function addUpdate() {
+ updates++;
+ }
+ function addRequest() {
+ requests++;
+ }
+
+ function printCounts() {
+ #{rich:element('events')}.innerHTML=events;
+ #{rich:element('updates')}.innerHTML=updates;
+ #{rich:element('requests')}.innerHTML=requests;
+ }
+ </script>
+ </ui:define>
+
+ <ui:define name="outOfTemplateBefore">
+ </ui:define>
+
+ <ui:define name="component">
+ <a4j:queue id="queue1"/>
+ <a4j:queue id="queue2"/>
+
+ <a4j:ajax event="keyup" render="output1, output2" execute="@form" onbegin="addRequest();"
+ oncomplete="printCounts()" onbeforedomupdate="addUpdate()">
+ <a4j:attachQueue id="a4jAttachQueue"
+ ignoreDupResponses="#{a4jAttachQueueBean.attributes1['ignoreDupResponses'].value}"
+ name="#{a4jAttachQueueBean.attributes1['name'].value}"
+ onrequestdequeue="#{a4jAttachQueueBean.attributes1['onrequestdequeue'].value}"
+ onrequestqueue="#{a4jAttachQueueBean.attributes1['onrequestqueue'].value}"
+ queueId="#{a4jAttachQueueBean.attributes1['queueId'].value}"
+ rendered="#{a4jAttachQueueBean.attributes1['rendered'].value}"
+ requestDelay="#{a4jAttachQueueBean.attributes1['requestDelay'].value}"
+ requestGroupingId="#{a4jAttachQueueBean.attributes1['requestGroupingId'].value}"
+ timeout="#{a4jAttachQueueBean.attributes1['timeout'].value}"/>
+
+ <h:inputText id="input1" value="#{a4jAttachQueueBean.text1}" onkeyup="addEvent();"/>
+ <h:inputText id="input2" value="#{a4jAttachQueueBean.text2}" onkeyup="addEvent();"/>
+ </a4j:ajax>
+
+ <h:panelGrid columns="2">
+ Output 1:
+ <h:outputText id="output1" value="#{a4jAttachQueueBean.text1}" style="font-weight:bold;"/>
+ Output 2:
+ <h:outputText id="output2" value="#{a4jAttachQueueBean.text2}" style="font-weight:bold;"/>
+ Events count:
+ <h:outputText value="0" id="events" />
+ Requests count:
+ <h:outputText value="0" id="requests" />
+ DOM updates count:
+ <h:outputText value="0" id="updates" />
+ </h:panelGrid>
+
+ </ui:define>
+
+ <ui:define name="outOfTemplateAfter">
+ <ta:attributes value="#{a4jAttachQueueBean.attributes1}" id="attributes" />
+ </ui:define>
+
+ </ui:composition>
+</html>
\ No newline at end of file
15 years, 1 month
JBoss Rich Faces SVN: r18392 - in root/tests/metamer/trunk/application/src/main: webapp/components and 2 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: ppitonak(a)redhat.com
Date: 2010-08-03 05:43:58 -0400 (Tue, 03 Aug 2010)
New Revision: 18392
Added:
root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java
root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/
root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/list.xhtml
root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/simple.xhtml
root/tests/metamer/trunk/application/src/main/webapp/resources/css/a4jQueue.css
Modified:
root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java
Log:
RFPL-733
* added a4j:queue
Added: root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java
===================================================================
--- root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java (rev 0)
+++ root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java 2010-08-03 09:43:58 UTC (rev 18392)
@@ -0,0 +1,81 @@
+/*******************************************************************************
+ * JBoss, Home of Professional Open Source
+ * Copyright 2010, Red Hat, Inc. and individual contributors
+ * by the @authors tag. See the copyright.txt in the distribution for a
+ * full listing of individual contributors.
+ *
+ * This is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU Lesser General Public License as
+ * published by the Free Software Foundation; either version 2.1 of
+ * the License, or (at your option) any later version.
+ *
+ * This software is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * Lesser General Public License for more details.
+ *
+ * You should have received a copy of the GNU Lesser General Public
+ * License along with this software; if not, write to the Free
+ * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+ * 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+ *******************************************************************************/
+package org.richfaces.tests.metamer.bean;
+
+import java.io.Serializable;
+
+import javax.annotation.PostConstruct;
+import javax.faces.bean.ManagedBean;
+import javax.faces.bean.ViewScoped;
+import org.richfaces.component.UIQueue;
+
+import org.richfaces.tests.metamer.Attributes;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Managed bean for a4j:queue.
+ *
+ * @author <a href="mailto:ppitonak@redhat.com">Pavol Pitonak</a>
+ * @version $Revision$
+ */
+@ManagedBean(name = "a4jQueueBean")
+@ViewScoped
+public class A4JQueueBean implements Serializable {
+
+ private static final long serialVersionUID = 486866943531809L;
+ private static Logger logger;
+ private Attributes attributes;
+ private String text;
+
+ /**
+ * Initializes the managed bean.
+ */
+ @PostConstruct
+ public void init() {
+ logger = LoggerFactory.getLogger(getClass());
+ logger.debug("initializing bean " + getClass().getName());
+
+ // initialize attributes
+ attributes = Attributes.getUIComponentAttributes(UIQueue.class, getClass());
+ attributes.setAttribute("rendered", true);
+ attributes.setAttribute("requestDelay", 1500);
+
+ }
+
+ public Attributes getAttributes() {
+ return attributes;
+ }
+
+ public void setAttributes(Attributes attributes) {
+ this.attributes = attributes;
+ }
+
+ public String getText() {
+ return text;
+ }
+
+ public void setText(String text) {
+ logger.error("setText " + text);
+ this.text = text;
+ }
+}
Property changes on: root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/A4JQueueBean.java
___________________________________________________________________
Name: svn:keywords
+ Revision
Modified: root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java
===================================================================
--- root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java 2010-08-03 08:49:05 UTC (rev 18391)
+++ root/tests/metamer/trunk/application/src/main/java/org/richfaces/tests/metamer/bean/RichBean.java 2010-08-03 09:43:58 UTC (rev 18392)
@@ -101,6 +101,7 @@
components.put("a4jParam", "A4J Action Parameter");
components.put("a4jPoll", "A4J Poll");
components.put("a4jPush", "A4J Push");
+ components.put("a4jQueue", "A4J Queue");
components.put("a4jRegion", "A4J Region");
components.put("a4jRepeat", "A4J Repeat");
components.put("commandButton", "JSF Command Button");
Added: root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/list.xhtml
===================================================================
--- root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/list.xhtml (rev 0)
+++ root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/list.xhtml 2010-08-03 09:43:58 UTC (rev 18392)
@@ -0,0 +1,41 @@
+<!--
+JBoss, Home of Professional Open Source
+Copyright 2010, Red Hat, Inc. and individual contributors
+by the @authors tag. See the copyright.txt in the distribution for a
+full listing of individual contributors.
+
+This is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of
+the License, or (at your option) any later version.
+
+This software is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this software; if not, write to the Free
+Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+02110-1301 USA, or see the FSF site: http://www.fsf.org.
+-->
+
+<!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:ta="http://java.sun.com/jsf/composite/testapp">
+
+ <ui:composition template="/templates/list.xhtml">
+
+ <ui:define name="pageTitle">A4J Queue</ui:define>
+
+ <ui:define name="links">
+
+ <ta:testPageLink id="simple" outcome="simple" value="Simple">
+ Simple page that contains <b>a4j:queue</b> and input boxes for all its attributes.
+ </ta:testPageLink>
+
+ </ui:define>
+
+ </ui:composition>
+
+</html>
Added: root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/simple.xhtml
===================================================================
--- root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/simple.xhtml (rev 0)
+++ root/tests/metamer/trunk/application/src/main/webapp/components/a4jQueue/simple.xhtml 2010-08-03 09:43:58 UTC (rev 18392)
@@ -0,0 +1,104 @@
+<!--
+JBoss, Home of Professional Open Source
+Copyright 2010, Red Hat, Inc. and individual contributors
+by the @authors tag. See the copyright.txt in the distribution for a
+full listing of individual contributors.
+
+This is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as
+published by the Free Software Foundation; either version 2.1 of
+the License, or (at your option) any later version.
+
+This software is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this software; if not, write to the Free
+Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+02110-1301 USA, or see the FSF site: http://www.fsf.org.
+-->
+
+<!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:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core"
+ xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:a4j="http://richfaces.org/a4j"
+ xmlns:ta="http://java.sun.com/jsf/composite/testapp" xmlns:rich="http://richfaces.org/rich">
+
+ <ui:composition template="/templates/template.xhtml">
+
+ <ui:define name="head">
+ <f:metadata>
+ <f:viewParam name="templates" value="#{templateBean.templates}">
+ <f:converter converterId="templatesListConverter" />
+ </f:viewParam>
+ </f:metadata>
+ <h:outputStylesheet library="css" name="a4jQueue.css" />
+ <script type="text/javascript">
+ var events = 0;
+ var updates = 0;
+ var requests = 0;
+
+ function addEvent() {
+ events++;
+ }
+ function addUpdate() {
+ updates++;
+ }
+ function addRequest() {
+ requests++;
+ }
+
+ function printCounts() {
+ #{rich:element('events')}.innerHTML=events;
+ #{rich:element('updates')}.innerHTML=updates;
+ #{rich:element('requests')}.innerHTML=requests;
+ }
+ </script>
+ </ui:define>
+
+ <ui:define name="outOfTemplateBefore">
+ </ui:define>
+
+ <ui:define name="component">
+
+ <a4j:queue id="a4jQueue"
+ ignoreDupResponses="#{a4jQueueBean.attributes['ignoreDupResponses'].value}"
+ name="#{a4jQueueBean.attributes['name'].value}"
+ onbeforedomupdate="#{a4jQueueBean.attributes['onbeforedomupdate'].value}"
+ oncomplete="#{a4jQueueBean.attributes['oncomplete'].value}"
+ onerror="#{a4jQueueBean.attributes['onerror'].value}"
+ onevent="#{a4jQueueBean.attributes['event'].value}"
+ onrequestdequeue="#{a4jQueueBean.attributes['onrequestdequeue'].value}"
+ onrequestqueue="#{a4jQueueBean.attributes['onrequestqueue'].value}"
+ onsubmit="#{a4jQueueBean.attributes['onsubmit'].value}"
+ rendered="#{a4jQueueBean.attributes['rendered'].value}"
+ requestDelay="#{a4jQueueBean.attributes['requestDelay'].value}"
+ status="#{a4jQueueBean.attributes['status'].value}"
+ timeout="#{a4jQueueBean.attributes['timeout'].value}"/>
+
+ <h:panelGrid columns="2">
+ <h:outputText value="Type here:" />
+ <h:inputText id="input" value="#{a4jQueueBean.text}" onkeyup="addEvent();" disabled="#{not (facesContext.maximumSeverity==null)}">
+ <a4j:ajax onbegin="addRequest();" event="keyup" render="outtext" oncomplete="printCounts()" onbeforedomupdate="addUpdate()" />
+ </h:inputText>
+
+ <h:outputText value="Repeated text:" />
+ <h:outputText value="#{a4jQueueBean.text}" id="outtext"
+ style="font-weight:bold;" />
+ <h:outputText value="Events count:" />
+ <h:outputText value="0" id="events" />
+ <h:outputText value="Requests count:" />
+ <h:outputText value="0" id="requests" />
+ <h:outputText value="DOM updates count:" />
+ <h:outputText value="0" id="updates" />
+ </h:panelGrid>
+
+ </ui:define>
+
+ <ui:define name="outOfTemplateAfter">
+ <ta:attributes value="#{a4jQueueBean.attributes}" id="attributes" />
+ </ui:define>
+
+ </ui:composition>
+</html>
\ No newline at end of file
Added: root/tests/metamer/trunk/application/src/main/webapp/resources/css/a4jQueue.css
===================================================================
15 years, 1 month
JBoss Rich Faces SVN: r18391 - root/tests/metamer/trunk/application/src/main/webapp/templates.
by richfaces-svn-commits@lists.jboss.org
Author: ppitonak(a)redhat.com
Date: 2010-08-03 04:49:05 -0400 (Tue, 03 Aug 2010)
New Revision: 18391
Modified:
root/tests/metamer/trunk/application/src/main/webapp/templates/template.xhtml
Log:
* common a4j:log's level changed to debug
Modified: root/tests/metamer/trunk/application/src/main/webapp/templates/template.xhtml
===================================================================
--- root/tests/metamer/trunk/application/src/main/webapp/templates/template.xhtml 2010-08-02 23:42:21 UTC (rev 18390)
+++ root/tests/metamer/trunk/application/src/main/webapp/templates/template.xhtml 2010-08-03 08:49:05 UTC (rev 18391)
@@ -50,7 +50,7 @@
</div>
<h:panelGroup id="a4jLogPanel" styleClass="log-panel" layout="block">
- <a4j:log id="a4jLog" height="300px" rendered="#{richBean.log}" />
+ <a4j:log id="a4jLog" height="300px" rendered="#{richBean.log}" level="debug"/>
</h:panelGroup>
<div class="footer">
15 years, 1 month
JBoss Rich Faces SVN: r18390 - in tags: archive and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: alexsmirnov
Date: 2010-08-02 19:42:21 -0400 (Mon, 02 Aug 2010)
New Revision: 18390
Added:
tags/archive/3.2.2.SR1/
Removed:
tags/3.2.2.SR1/
Log:
move outdated 3.2.2.SR1/ tag to archive
Copied: tags/archive/3.2.2.SR1 (from rev 18389, tags/3.2.2.SR1)
15 years, 1 month