JBoss Rich Faces SVN: r17602 - root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior.
by richfaces-svn-commits@lists.jboss.org
Author: Alex.Kolonitsky
Date: 2010-06-11 07:10:01 -0400 (Fri, 11 Jun 2010)
New Revision: 17602
Modified:
root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java
Log:
save selector setter
Modified: root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java
===================================================================
--- root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java 2010-06-11 10:59:21 UTC (rev 17601)
+++ root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java 2010-06-11 11:10:01 UTC (rev 17602)
@@ -96,7 +96,7 @@
} else if (compare(PropertyKeys.target, name)) {
setTarget((String) value);
} else if (compare(PropertyKeys.selector, name)) {
- setSelector((String) name);
+ setSelector((String) value);
}
}
}
14 years, 6 months
JBoss Rich Faces SVN: r17601 - root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior.
by richfaces-svn-commits@lists.jboss.org
Author: Alex.Kolonitsky
Date: 2010-06-11 06:59:21 -0400 (Fri, 11 Jun 2010)
New Revision: 17601
Modified:
root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java
Log:
delete unused property
Modified: root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java
===================================================================
--- root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java 2010-06-11 00:14:38 UTC (rev 17600)
+++ root/ui/misc/trunk/componentcontrol/src/main/java/org/richfaces/component/behavior/ComponentControlBehavior.java 2010-06-11 10:59:21 UTC (rev 17601)
@@ -42,7 +42,7 @@
private List<UIComponent> children;
enum PropertyKeys {
- event, target, selector, parameters, operation
+ event, target, selector, operation
}
public List<UIComponent> getChildren() {
14 years, 6 months
JBoss Rich Faces SVN: r17600 - root/cdk/tags/richfaces-cdk-4.0.0.Alpha2/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model.
by richfaces-svn-commits@lists.jboss.org
Author: alexsmirnov
Date: 2010-06-10 20:14:38 -0400 (Thu, 10 Jun 2010)
New Revision: 17600
Modified:
root/cdk/tags/richfaces-cdk-4.0.0.Alpha2/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java
Log:
merge client behavior renderer type fix
Modified: root/cdk/tags/richfaces-cdk-4.0.0.Alpha2/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java
===================================================================
--- root/cdk/tags/richfaces-cdk-4.0.0.Alpha2/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java 2010-06-10 23:35:01 UTC (rev 17599)
+++ root/cdk/tags/richfaces-cdk-4.0.0.Alpha2/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java 2010-06-11 00:14:38 UTC (rev 17600)
@@ -47,7 +47,7 @@
*
* @return the id
*/
- @XmlElement(name = "client-behavior-renderer-id", namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE)
+ @XmlElement(name = "client-behavior-renderer-type", namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE)
public FacesId getId() {
return id;
}
14 years, 6 months
JBoss Rich Faces SVN: r17599 - root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model.
by richfaces-svn-commits@lists.jboss.org
Author: alexsmirnov
Date: 2010-06-10 19:35:01 -0400 (Thu, 10 Jun 2010)
New Revision: 17599
Modified:
root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java
Log:
fix client behafior renderer element name
Modified: root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java
===================================================================
--- root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java 2010-06-10 21:35:37 UTC (rev 17598)
+++ root/cdk/trunk/plugins/generator/src/main/java/org/richfaces/cdk/xmlconfig/model/BehaviorRendererBean.java 2010-06-10 23:35:01 UTC (rev 17599)
@@ -47,7 +47,7 @@
*
* @return the id
*/
- @XmlElement(name = "client-behavior-renderer-id", namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE)
+ @XmlElement(name = "client-behavior-renderer-type", namespace = ComponentLibrary.FACES_CONFIG_NAMESPACE)
public FacesId getId() {
return id;
}
14 years, 6 months
JBoss Rich Faces SVN: r17598 - in root/core/branches/jsr-330/jsr330-impl/src: test/java/org/richfaces/jsr330 and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: alexsmirnov
Date: 2010-06-10 17:35:37 -0400 (Thu, 10 Jun 2010)
New Revision: 17598
Added:
root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/BarProvider.java
root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/FooProvider.java
Modified:
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Binding.java
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DependencyInjector.java
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DynamicBinding.java
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/InjectorImpl.java
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ObjectFactory.java
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ProviderWrapper.java
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/StaticBinding.java
root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Target.java
root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/InjectorTest.java
root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/TestProviderInjection.java
Log:
Fixed Provider binding implementation
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Binding.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Binding.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Binding.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -7,5 +7,7 @@
public Object get();
void init(InjectorImpl injectorImpl);
+
+ public abstract Binding getProvider();
}
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DependencyInjector.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DependencyInjector.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DependencyInjector.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -32,4 +32,6 @@
public <T> T create(Class<T> type);
+ public <T> T create(Class<T> type,String name);
+
}
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DynamicBinding.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DynamicBinding.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/DynamicBinding.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -106,6 +106,10 @@
}
}
+ public Binding getProvider() {
+ return new StaticBinding(this);
+ }
+
void invokeInjectionMethods(Object instance) throws Exception {
for (Method method : injectedMethods.keySet()) {
method.invoke(instance, getArgumentValues(injectedMethods.get(method)));
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/InjectorImpl.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/InjectorImpl.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/InjectorImpl.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -2,22 +2,26 @@
import java.util.ArrayList;
import java.util.Collection;
-import java.util.HashMap;
import java.util.Map;
+import java.util.concurrent.ConcurrentHashMap;
import javax.inject.Provider;
public class InjectorImpl implements DependencyInjector {
- private final Map<Target,Binding> bindings = new HashMap<Target, Binding>();
+ private final Map<Target,Binding> bindings = new ConcurrentHashMap<Target, Binding>();
@SuppressWarnings("unchecked")
- public <T> T create(Class<T> type) {
- Target target = Target.create(type);
+ public <T> T create(Class<T> type,String name) {
+ Target target = Target.create(type,name);
return (T) getBinding(target).get();
}
+ public <T> T create(Class<T> type) {
+ return create(type, null);
+ }
+
public void init(BindingModule ... modules){
for (BindingModule bindingModule : modules) {
bindingModule.configure(this);
@@ -53,43 +57,43 @@
Binding binding = registerImplementation(type, type.getRawType());
binding.init(this);
return binding;
+ } else if(type.isProvider()){
+ return getBinding(type.toProviderTarget()).getProvider();
} else {
throw new DependencyException("Type "+type+" has not been registered");
}
}
- public Binding registerProvider(Target type, Provider<?> provider){
+ public Binding registerProviderInstance(Target type, Provider<?> provider){
StaticBinding binding = new StaticBinding(provider);
- registerProviderWrapper(type, binding);
+ registerProviderBinding(type, binding);
return binding;
}
- public Binding registerProvider(Target type, Class<? extends Provider<?>> provider){
+ public Binding registerProviderImplementation(Target type, Class<? extends Provider<?>> provider){
DynamicBinding binding = new DynamicBinding(provider);
- registerProviderWrapper(type, binding);
+ registerProviderBinding(type, binding);
return binding;
}
- private void registerProviderWrapper(Target type, Binding binding) {
- bindings.put(type.toProvider(), binding);
- ProviderWrapper wrapper = new ProviderWrapper(binding);
+ private void registerProviderBinding(Target type, Binding binding) {
+ Binding wrapper = new ProviderWrapper(binding);
bindings.put(type, wrapper);
}
public Binding registerImplementation(Target type, Class<?> implementation){
DynamicBinding provider = new DynamicBinding(implementation);
- registerImplementationProvider(type, provider);
+ registerImplementationBinding(type, provider);
return provider;
}
public Binding registerInstance(Target type, Object instance){
StaticBinding provider = new StaticBinding(instance);
- registerImplementationProvider(type, provider);
+ registerImplementationBinding(type, provider);
return provider;
}
- private void registerImplementationProvider(Target type, Binding provider) {
+ private void registerImplementationBinding(Target type, Binding provider) {
bindings.put(type, provider);
- bindings.put(type.toProvider(), new StaticBinding(provider));
}
}
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ObjectFactory.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ObjectFactory.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ObjectFactory.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -18,6 +18,10 @@
private ObjectFactory() {
}
+ public static <T> T create(Class<T> target,String name) {
+ return getInjector().create(target,name);
+ }
+
public static <T> T create(Class<T> target) {
return getInjector().create(target);
}
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ProviderWrapper.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ProviderWrapper.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/ProviderWrapper.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -42,24 +42,21 @@
* @see org.richfaces.jsr330.Binding#get()
*/
public Object get() {
- // TODO Auto-generated method stub
- return getProvider().get();
+ return ((Provider) getProvider().get()).get();
}
/* (non-Javadoc)
* @see org.richfaces.jsr330.Binding#getProvider()
*/
- private Provider<?> getProvider() {
- // TODO Auto-generated method stub
- return (Provider<?>) binding.get();
+ public Binding getProvider() {
+ return binding;
}
/* (non-Javadoc)
* @see org.richfaces.jsr330.Binding#init(org.richfaces.jsr330.InjectorImpl)
*/
public void init(InjectorImpl injectorImpl) {
- // TODO Auto-generated method stub
-
+ this.binding.init(injectorImpl);
}
}
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/StaticBinding.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/StaticBinding.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/StaticBinding.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -45,4 +45,8 @@
// do nothing
}
+ public Binding getProvider() {
+ return new StaticBinding(this);
+ }
+
}
Modified: root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Target.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Target.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/main/java/org/richfaces/jsr330/Target.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -85,6 +85,18 @@
return target;
}
+ public Target toProviderTarget(){
+ if(isProvider()){
+ return new Target(this.actualTypeArguments[0],name);
+ } else {
+ throw new DependencyException("Type "+this+" not is a Provider type");
+ }
+ }
+
+ public boolean isProvider(){
+ return Provider.class.isAssignableFrom(rawType) && (1==actualTypeArguments.length);
+ }
+
public boolean isConcrete() {
return !Modifier.isAbstract((getRawType()).getModifiers());
}
@@ -166,5 +178,20 @@
return this.actualTypeArguments;
}
-
+ @Override
+ public String toString() {
+ StringBuilder builder = new StringBuilder();
+ builder.append(rawType.getName());
+ if(getActualTypeArguments().length>0){
+ builder.append("< ");
+ for (Type argument : getActualTypeArguments()) {
+ builder.append(getRawClass(argument).getSimpleName()).append(' ');
+ }
+ builder.append('>');
+ }
+ if(null != name){
+ builder.append(" :").append(name);
+ }
+ return builder.toString();
+ }
}
Added: root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/BarProvider.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/BarProvider.java (rev 0)
+++ root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/BarProvider.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -0,0 +1,11 @@
+package org.richfaces.jsr330;
+
+import javax.inject.Provider;
+
+public class BarProvider implements Provider<String> {
+
+ public String get() {
+ return "bar";
+ }
+
+}
Property changes on: root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/BarProvider.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Added: root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/FooProvider.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/FooProvider.java (rev 0)
+++ root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/FooProvider.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -0,0 +1,39 @@
+/*
+ * $Id$
+ *
+ * License Agreement.
+ *
+ * Rich Faces - Natural Ajax for Java Server Faces (JSF)
+ *
+ * Copyright (C) 2007 Exadel, Inc.
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+ * License version 2.1 as published by the Free Software Foundation.
+ *
+ * This library 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 library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+package org.richfaces.jsr330;
+
+import javax.inject.Provider;
+
+/**
+ * <p class="changed_added_4_0"></p>
+ * @author asmirnov(a)exadel.com
+ *
+ */
+public class FooProvider implements Provider<String> {
+
+ public String get() {
+ return "foo";
+ }
+
+}
Property changes on: root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/FooProvider.java
___________________________________________________________________
Name: svn:mime-type
+ text/plain
Modified: root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/InjectorTest.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/InjectorTest.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/InjectorTest.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -8,7 +8,7 @@
public class InjectorTest {
@Test
- public void injectConstructor() throws Exception {
+ public void injectByConstructor() throws Exception {
InjectorImpl injector = new InjectorImpl();
injector.init(new BindingModule(){
@@ -25,7 +25,7 @@
}
@Test
- public void injectField() throws Exception {
+ public void injectByField() throws Exception {
InjectorImpl injector = new InjectorImpl();
injector.init(new BindingModule(){
@@ -42,7 +42,7 @@
}
@Test
- public void injectMethod() throws Exception {
+ public void injectByMethod() throws Exception {
InjectorImpl injector = new InjectorImpl();
injector.init(new BindingModule(){
@@ -57,8 +57,9 @@
assertTrue(testInterface instanceof TestMethodInjection);
assertEquals("bar",testInterface.hello());
}
+
@Test
- public void injectProvider() throws Exception {
+ public void injectByProvider() throws Exception {
InjectorImpl injector = new InjectorImpl();
injector.init(new BindingModule(){
@@ -74,4 +75,23 @@
assertEquals("bar",testInterface.hello());
}
+ @Test
+ public void injectProvider() throws Exception {
+ InjectorImpl injector = new InjectorImpl();
+ injector.init(new BindingModule(){
+
+ public void configure(InjectorImpl injector) {
+ injector.registerImplementation(Target.create(TestInterface.class), TestProviderInjection.class);
+ injector.registerProviderInstance(Target.create(String.class, "foo"), new FooProvider());
+ injector.registerProviderImplementation(Target.create(String.class, "bar"), BarProvider.class);
+ }
+
+ });
+ TestInterface testInterface = injector.create(TestInterface.class);
+ assertTrue(testInterface instanceof TestProviderInjection);
+ assertEquals("foo",testInterface.hello());
+ TestProviderInjection instance = (TestProviderInjection) testInterface;
+ assertEquals("bar",instance.bar);
+ assertEquals("foo",instance.foo);
+ }
}
Modified: root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/TestProviderInjection.java
===================================================================
--- root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/TestProviderInjection.java 2010-06-10 16:38:03 UTC (rev 17597)
+++ root/core/branches/jsr-330/jsr330-impl/src/test/java/org/richfaces/jsr330/TestProviderInjection.java 2010-06-10 21:35:37 UTC (rev 17598)
@@ -36,6 +36,11 @@
String param;
+ @Inject
+ @Named("bar")
+ String bar;
+
+ String foo;
/**
* <p class="changed_added_4_0"></p>
* @param param the param to set
@@ -49,4 +54,8 @@
return param;
}
+ @Inject
+ public void setFoo(@Named("foo")String foo) {
+ this.foo = foo;
+ }
}
14 years, 6 months
JBoss Rich Faces SVN: r17597 - in root/examples/richfaces-showcase: trunk/src/main/webapp/richfaces/dataTable and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: ilya_shaikovsky
Date: 2010-06-10 12:38:03 -0400 (Thu, 10 Jun 2010)
New Revision: 17597
Modified:
root/examples/richfaces-showcase/branches/richfaces-showcase-4.0.0.Alpha2/src/main/webapp/richfaces/dataTable/tableStyling.xhtml
root/examples/richfaces-showcase/trunk/src/main/webapp/richfaces/dataTable/tableStyling.xhtml
Log:
https://jira.jboss.org/browse/RF-8749
Modified: root/examples/richfaces-showcase/branches/richfaces-showcase-4.0.0.Alpha2/src/main/webapp/richfaces/dataTable/tableStyling.xhtml
===================================================================
--- root/examples/richfaces-showcase/branches/richfaces-showcase-4.0.0.Alpha2/src/main/webapp/richfaces/dataTable/tableStyling.xhtml 2010-06-10 15:42:02 UTC (rev 17596)
+++ root/examples/richfaces-showcase/branches/richfaces-showcase-4.0.0.Alpha2/src/main/webapp/richfaces/dataTable/tableStyling.xhtml 2010-06-10 16:38:03 UTC (rev 17597)
@@ -9,11 +9,11 @@
<ui:composition>
<style>
-.stable tr:nth-child(even) {
+.even-row {
background-color: #FCFFFE;
}
-.stable tr:nth-child(odd) {
+.odd-row {
background-color: #ECF3FE;
}
@@ -63,6 +63,10 @@
<script>
$('.stable tr').mouseover(function(){$(this).addClass('active-row')});
$('.stable tr').mouseout(function(){$(this).removeClass('active-row')});
+
+ $('.stable tr:odd').addClass('odd-row');
+ $('.stable tr:even').addClass('even-row');
+
</script>
</ui:composition>
</html>
\ No newline at end of file
Modified: root/examples/richfaces-showcase/trunk/src/main/webapp/richfaces/dataTable/tableStyling.xhtml
===================================================================
--- root/examples/richfaces-showcase/trunk/src/main/webapp/richfaces/dataTable/tableStyling.xhtml 2010-06-10 15:42:02 UTC (rev 17596)
+++ root/examples/richfaces-showcase/trunk/src/main/webapp/richfaces/dataTable/tableStyling.xhtml 2010-06-10 16:38:03 UTC (rev 17597)
@@ -9,11 +9,11 @@
<ui:composition>
<style>
-.stable tr:nth-child(even) {
+.even-row {
background-color: #FCFFFE;
}
-.stable tr:nth-child(odd) {
+.odd-row {
background-color: #ECF3FE;
}
@@ -63,6 +63,10 @@
<script>
$('.stable tr').mouseover(function(){$(this).addClass('active-row')});
$('.stable tr').mouseout(function(){$(this).removeClass('active-row')});
+
+ $('.stable tr:odd').addClass('odd-row');
+ $('.stable tr:even').addClass('even-row');
+
</script>
</ui:composition>
</html>
\ No newline at end of file
14 years, 6 months
JBoss Rich Faces SVN: r17596 - in root/archetypes: richfaces-component/trunk/src/main/resources/archetype-resources and 11 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: Alex.Kolonitsky
Date: 2010-06-10 11:42:02 -0400 (Thu, 10 Jun 2010)
New Revision: 17596
Added:
root/archetypes/richfaces-component/trunk/readme.txt
Modified:
root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/api/pom.xml
root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/readme.txt
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/META-INF/maven/archetype-metadata.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/bom/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/api/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/impl/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/ui/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/parent/pom.xml
root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/pom.xml
Log:
RFPL-602 Update component module archetypes
Added: root/archetypes/richfaces-component/trunk/readme.txt
===================================================================
--- root/archetypes/richfaces-component/trunk/readme.txt (rev 0)
+++ root/archetypes/richfaces-component/trunk/readme.txt 2010-06-10 15:42:02 UTC (rev 17596)
@@ -0,0 +1,31 @@
+RichFaces 4 Archetype
+
+This archetype creates a folder/pom.xml structure for component (like in tables)
+
+/<artifact-id>
+ /api
+ src/main/java
+ pom.xml
+ /impl
+ src/main/java
+ pom.xml
+ /ui
+ src/main/java
+ pom.xml
+ pom.xml
+
+
+To generate a project from the archetype, run
+
+mvn archetype:generate -DarchetypeGroupId=org.richfaces.archetypes -DarchetypeArtifactId=richfaces-component
+ -Dcategory=<version> -Dname=<name>
+
+in such case will be created artifacts with:
+ category : <category>
+ name : <name>
+ groupId : org.richfaces.ui.<category>
+ artifact : <category>-<name>
+ version : 4.0.0-SNAPSHOT
+
+TODO link to wiki page
+TODO example with panels
\ No newline at end of file
Modified: root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/api/pom.xml
===================================================================
--- root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/api/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/api/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -25,10 +25,11 @@
<parent>
<groupId>${groupId}.${category}</groupId>
- <artifactId>${name}-aggregator</artifactId>
+ <artifactId>${artifactId}-aggregator</artifactId>
<version>4.0.0-SNAPSHOT</version>
</parent>
+ <groupId>${groupId}.${category}</groupId>
<artifactId>${artifactId}-api</artifactId>
<name>Richfaces UI Components: ${artifactId} api</name>
<packaging>jar</packaging>
Modified: root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/pom.xml
===================================================================
--- root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-component/trunk/src/main/resources/archetype-resources/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -28,9 +28,10 @@
<version>4.0.0-SNAPSHOT</version>
</parent>
+ <groupId>${groupId}.${category}</groupId>
<artifactId>${artifactId}-aggregator</artifactId>
<packaging>pom</packaging>
- <name>Richfaces UI Components: ${name} aggregator</name>
+ <name>Richfaces UI Components: ${artifactId} aggregator</name>
<modules>
<module>api</module>
Modified: root/archetypes/richfaces-components-aggregator/trunk/readme.txt
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/readme.txt 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/readme.txt 2010-06-10 15:42:02 UTC (rev 17596)
@@ -1,9 +1,33 @@
RichFaces 4 Archetype
+This archetype creates a folder/pom.xml structure for component (like in tables)
-This archetype creates a simple RichFaces 4 application. To generate a project from the archetype, run
+/<category>
+ /bom
+ pom.xml
+ /parent
+ pom.xml
+ /dist
+ /api
+ pom.xml
+ /impl
+ pom.xml
+ /ui
+ pom.xml
+ pom.xml
+ pom.xml
- mvn archetype:generate -DarchetypeGroupId=org.richfaces.archetypes -DarchetypeArtifactId=richfaces-components-aggregator
- -DarchetypeVersion=<version> -DgroupId=<yourGroupId> -DartifactId=<yourArtifactId> -Dversion=1.0-SNAPSHOT
+To generate a project from the archetype, run
+mvn archetype:generate -DarchetypeGroupId=org.richfaces.archetypes -DarchetypeArtifactId=richfaces-components-aggregator
+ -Dcategory=<category>
+
+in such case will be created artifacts with:
+ category : <category>
+ groupId : org.richfaces.ui.<category>
+ artifact : <category>-<name>
+ version : 4.0.0-SNAPSHOT
+
+TODO link to wiki page
+TODO example with panels
\ No newline at end of file
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/META-INF/maven/archetype-metadata.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/META-INF/maven/archetype-metadata.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/META-INF/maven/archetype-metadata.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -30,7 +30,7 @@
<defaultValue>components</defaultValue>
</requiredProperty>
<requiredProperty key="artifactId">
- <defaultValue>richfaces-ui-${category}</defaultValue>
+ <defaultValue>${category}</defaultValue>
</requiredProperty>
<requiredProperty key="version">
<defaultValue>4.0.0-SNAPSHOT</defaultValue>
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -1 +1,73 @@
-remove this file, it is maven-archetype-plugin bug
\ No newline at end of file
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ 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.
+-->
+
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <groupId>org.richfaces</groupId>
+ <artifactId>richfaces-parent</artifactId>
+ <version>7</version>
+ </parent>
+
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>${category}-aggregator</artifactId>
+ <version>4.0.0-SNAPSHOT</version>
+ <packaging>pom</packaging>
+ <name>Richfaces UI Components: ${category} aggregator</name>
+
+ <modules>
+ <module>bom</module>
+ <module>parent</module>
+ <module>dist</module>
+ </modules>
+
+ <build>
+ <pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-release-plugin</artifactId>
+ <configuration>
+ <!-- The dist requires clean install for prepare -->
+ <preparationGoals>clean install</preparationGoals>
+ </configuration>
+ </plugin>
+ </plugins>
+ </pluginManagement>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-release-plugin</artifactId>
+ <configuration>
+ <!-- The dist requires clean install for prepare -->
+ <preparationGoals>clean install</preparationGoals>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+
+ <scm>
+ <connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/root/ui/${category}/trunk</connection>
+ <developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/root/ui/${category}/trunk</developerConnection>
+ <url>http://fisheye.jboss.org/browse/richfaces</url>
+ </scm>
+</project>
\ No newline at end of file
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/bom/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/bom/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/bom/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -29,9 +29,9 @@
</parent>
<groupId>${groupId}.${category}</groupId>
- <artifactId>${artifactId}-bom</artifactId>
+ <artifactId>richfaces-ui-${category}-bom</artifactId>
<version>4.0.0-SNAPSHOT</version>
- <name>Richfaces UI Components: ${category} BOM</name>
+ <name>Richfaces UI Components: ${category} bom</name>
<packaging>pom</packaging>
<properties>
@@ -50,17 +50,17 @@
<dependency>
<groupId>${project.groupId}</groupId>
- <artifactId>${artifactId}-ui</artifactId>
+ <artifactId>richfaces-ui-${artifactId}-ui</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
- <artifactId>${artifactId}-impl</artifactId>
+ <artifactId>richfaces-ui-${artifactId}-impl</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>${project.groupId}</groupId>
- <artifactId>${artifactId}-api</artifactId>
+ <artifactId>richfaces-ui-${artifactId}-api</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/api/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/api/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/api/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -21,15 +21,15 @@
<modelVersion>4.0.0</modelVersion>
<parent>
- <groupId>${groupId}</groupId>
- <artifactId>${artifactId}-assembler</artifactId>
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>richfaces-ui-${category}-parent</artifactId>
<version>${version}</version>
</parent>
<groupId>${groupId}</groupId>
- <artifactId>${artifactId}-api</artifactId>
+ <artifactId>richfaces-ui-${category}-api</artifactId>
<packaging>jar</packaging>
- <name>Richfaces UI Iteration API</name>
+ <name>Richfaces UI ${category} api</name>
<properties>
<assembly.projects.group>${groupId}.${category}</assembly.projects.group>
@@ -39,8 +39,8 @@
<dependencyManagement>
<dependencies>
<dependency>
- <groupId>${groupId}.${artifactId}</groupId>
- <artifactId>${artifactId}-bom</artifactId>
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>richfaces-ui-${category}-bom</artifactId>
<version>${project.version}</version>
<scope>import</scope>
<type>pom</type>
@@ -145,8 +145,8 @@
</profiles>
<scm>
- <connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/root/ui/${category}/trun...</connection>
- <developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/root/ui/${category}/trunk/d...</developerConnection>
+ <connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/root/ui/${category}/trun...</connection>
+ <developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/root/ui/${category}/trunk/d...</developerConnection>
<url>http://fisheye.jboss.org/browse/richfaces</url>
</scm>
</project>
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/impl/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/impl/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/impl/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -21,16 +21,15 @@
<modelVersion>4.0.0</modelVersion>
<parent>
- <groupId>${groupId}</groupId>
- <artifactId>${category}-assembler</artifactId>
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>richfaces-ui-${category}-parent</artifactId>
<version>${version}</version>
</parent>
<groupId>${groupId}</groupId>
- <artifactId>${artifactId}</artifactId>
- <version>${version}</version>
+ <artifactId>richfaces-ui-${category}-impl</artifactId>
<packaging>jar</packaging>
- <name>Richfaces UI Iteration API</name>
+ <name>Richfaces UI ${category} api</name>
<properties>
<assembly.projects.group>${groupId}.${category}</assembly.projects.group>
@@ -40,8 +39,8 @@
<dependencyManagement>
<dependencies>
<dependency>
- <groupId>${groupId}.${artifactId}</groupId>
- <artifactId>${artifactId}-bom</artifactId>
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>richfaces-ui-${category}-bom</artifactId>
<version>${project.version}</version>
<scope>import</scope>
<type>pom</type>
@@ -55,7 +54,7 @@
<!-- artifacts for javadoc generation -->
<dependency>
<groupId>${project.groupId}</groupId>
- <artifactId>${artifactId}-api</artifactId>
+ <artifactId>richfaces-ui-${artifactId}-api</artifactId>
<version>${project.version}</version>
</dependency>
@@ -153,8 +152,8 @@
</profiles>
<scm>
- <connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/root/ui/${category}/trun...</connection>
- <developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/root/ui/${category}/trunk/d...</developerConnection>
+ <connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/root/ui/${category}/trun...</connection>
+ <developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/root/ui/${category}/trunk/d...</developerConnection>
<url>http://fisheye.jboss.org/browse/richfaces</url>
</scm>
</project>
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -23,13 +23,12 @@
<parent>
<groupId>${groupId}.${category}</groupId>
- <artifactId>${category}-parent</artifactId>
- <version>4.0.0-SNAPSHOT</version>
+ <artifactId>richfaces-ui-${category}-parent</artifactId>
+ <version>${version}</version>
</parent>
<groupId>${groupId}.${category}</groupId>
- <artifactId>${artifactId}-assembler</artifactId>
- <version>4.0.0-SNAPSHOT</version>
+ <artifactId>richfaces-ui-${artifactId}-assembler</artifactId>
<packaging>pom</packaging>
<name>Richfaces UI ${category} assembler</name>
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/ui/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/ui/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/dist/ui/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -22,16 +22,15 @@
<modelVersion>4.0.0</modelVersion>
<parent>
- <groupId>${groupId}</groupId>
- <artifactId>${artifactId}-assembler</artifactId>
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>richfaces-ui-${category}-parent</artifactId>
<version>${version}</version>
</parent>
<groupId>${groupId}</groupId>
- <artifactId>${artifactId}</artifactId>
- <version>${version}</version>
+ <artifactId>richfaces-ui-${category}-ui</artifactId>
<packaging>jar</packaging>
- <name>Richfaces UI Iteration UI</name>
+ <name>Richfaces UI ${category} ui</name>
<properties>
<assembly.projects.group>${groupId}.${category}</assembly.projects.group>
@@ -41,8 +40,8 @@
<dependencyManagement>
<dependencies>
<dependency>
- <groupId>${groupId}.${artifactId}</groupId>
- <artifactId>${artifactId}-bom</artifactId>
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>richfaces-ui-${category}-bom</artifactId>
<version>${project.version}</version>
<scope>import</scope>
<type>pom</type>
@@ -56,7 +55,7 @@
<!-- artifacts for javadoc generation -->
<dependency>
<groupId>${project.groupId}</groupId>
- <artifactId>${artifactId}-impl</artifactId>
+ <artifactId>richfaces-ui-${category}-impl</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
@@ -199,8 +198,8 @@
</profiles>
<scm>
- <connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/root/ui/${category}/trun...</connection>
- <developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/root/ui/${category}/trunk/d...</developerConnection>
+ <connection>scm:svn:http://anonsvn.jboss.org/repos/richfaces/root/ui/${category}/trun...</connection>
+ <developerConnection>scm:svn:https://svn.jboss.org/repos/richfaces/root/ui/${category}/trunk/d...</developerConnection>
<url>http://fisheye.jboss.org/browse/richfaces</url>
</scm>
</project>
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/parent/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/parent/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/parent/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -29,7 +29,7 @@
</parent>
<groupId>${groupId}.${category}</groupId>
- <artifactId>${category}-parent</artifactId>
+ <artifactId>richfaces-ui-${category}-parent</artifactId>
<version>${version}</version>
<name>Richfaces UI Components: ${category} parent</name>
<packaging>pom</packaging>
@@ -42,8 +42,8 @@
<dependencyManagement>
<dependencies>
<dependency>
- <groupId>${project.groupId}</groupId>
- <artifactId>${artifactId}-bom</artifactId>
+ <groupId>${groupId}.${category}</groupId>
+ <artifactId>richfaces-ui-${category}-bom</artifactId>
<version>${project.version}</version>
<scope>import</scope>
<type>pom</type>
Modified: root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/pom.xml
===================================================================
--- root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/pom.xml 2010-06-10 14:22:51 UTC (rev 17595)
+++ root/archetypes/richfaces-components-aggregator/trunk/src/main/resources/archetype-resources/trunk/pom.xml 2010-06-10 15:42:02 UTC (rev 17596)
@@ -29,10 +29,10 @@
</parent>
<groupId>${groupId}.${category}</groupId>
- <artifactId>${artifactId}-aggregator</artifactId>
+ <artifactId>${category}-aggregator</artifactId>
<version>4.0.0-SNAPSHOT</version>
<packaging>pom</packaging>
- <name>Richfaces UI Components: ${category} Aggregator</name>
+ <name>Richfaces UI Components: ${category} aggregator</name>
<modules>
<module>bom</module>
14 years, 6 months
JBoss Rich Faces SVN: r17595 - in root/ui-sandbox: inputs and 8 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: pyaschenko
Date: 2010-06-10 10:22:51 -0400 (Thu, 10 Jun 2010)
New Revision: 17595
Added:
root/ui-sandbox/inputs/
root/ui-sandbox/inputs/branches/
root/ui-sandbox/inputs/tags/
root/ui-sandbox/inputs/trunk/
root/ui-sandbox/inputs/trunk/autocomplete/
root/ui-sandbox/inputs/trunk/autocomplete/src/
root/ui-sandbox/inputs/trunk/autocomplete/src/main/
root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/
root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/
root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/
root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/
root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/1.html
root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/autocomplete.js
root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/richfaces-selection.js
Log:
autocomplete prototype draft
Added: root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/1.html
===================================================================
--- root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/1.html (rev 0)
+++ root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/1.html 2010-06-10 14:22:51 UTC (rev 17595)
@@ -0,0 +1,79 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/1999/REC-html401-19991224/loose.dtd">
+
+<html>
+<head>
+ <title>Untitled</title>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <title>Test Page</title>
+ <script type="text/javascript" src="..\..\..\..\..\..\..\..\..\..\core\trunk\impl\src\main\resources\META-INF\resources\jquery.js "></script>
+ <script type="text/javascript" src="..\..\..\..\..\..\..\..\..\..\core\trunk\impl\src\main\resources\META-INF\resources\richfaces.js "></script>
+ <script type="text/javascript" src="..\..\..\..\..\..\..\..\..\..\core\trunk\impl\src\main\resources\META-INF\resources\richfaces-event.js "></script>
+ <script type="text/javascript" src="..\..\..\..\..\..\..\..\..\..\core\trunk\impl\src\main\resources\META-INF\resources\richfaces-base-component.js "></script>
+ <script type="text/javascript" src="richfaces-selection.js"></script>
+ <script type="text/javascript" src="autocomplete.js"></script>
+ <style>
+ * {font-size : 11px; font-family : verdana; color : #000000}
+
+ .cb_field_width{ width : 150px;}
+ .cb_list_width{ width : 250px;}
+ .cb_list_height{ height : 100px;}
+
+ .cb_font{color : #000000/*generalTextColor*/}
+ .cb_input {border : 0px; background : none; width : 100%;}
+
+ .cb_field{ position : inline-block; border : 1px solid #A6A6A6/*panelBorderColor*/; display : inline-block; background : url(images/bg_field.png) top left repeat-x/*gradient - from additionalBackgroundColor to controlBackgroundColor, background-color - controlBackgroundColor*/; }
+
+ .cb_button{ background : url(images/bg_btn.png) top left repeat-x #C0D1E7/*gradient - from headerGradientColor to headerBackgroundColor, background-color - headerBackgroundColor*/; text-align : center; border-left : 1px solid #A6A6A6/*panelBorderColor*/; width : 15px; position : absolute; top : 0px; right : 0px; height : 200px; padding-top : 1px }
+ .cb_button_arrow{ background : url(images/down.gif) center no-repeat; cursor : pointer;}
+
+ .cb_list_cord{ position : relative; font-size : 0px;display : none}/*DDL is hidden!!!!!*/
+ .cb_list_position{ position : absolute; top: 0px; left: -1px; }
+ .cb_list_decoration{ border : 1px solid #A6A6A6 /*panelBorderColor*/; padding : 0px; background : #FFFFFF; /*tableBackgroundColor*/}
+ .cb_list_scroll{ overflow : auto; overflow-x : hidden;}
+ .cb_option{ padding : 2px; white-space : nowrap; cursor : default;}
+ .cb_select{ padding : 1px; width : 100%; background-color: #DFE8F6; border : 1px dotted #a3bae9;/*generalTextColor*/}
+
+ .cb_list_shadow{ position : absolute; width : 260px; height : 109px; margin-left : -4px; margin-top : -2px;}
+
+ </style>
+</head>
+
+<body style="margin : 30px">
+
+
+Text block text block text block text block text block text block text block text block
+<div id="myCombo" class=" cb_field_width cb_field">
+ <div style=" position : relative; overflow : hidden; text-align : left; padding-right : 21px;">
+ <input id="myComboInput" type="Text" class="cb_font cb_input">
+ <div id='myComboButton' class="cb_button">
+ <img src="images/down.gif" width="15" height="15" alt="" border="0">
+ </div>
+ </div>
+
+ <div id="myComboList" class="cb_list_cord">
+ <img src="images/bg_shadow.png" class="cb_list_shadow">
+ <div class="cb_list_position cb_list_width">
+ <div class="cb_list_decoration">
+ <div class="cb_list_scroll cb_list_height">
+ <div class="cb_option cb_font">Option 1</div>
+ <div class="cb_option cb_font">Option 2</div>
+ <div class="cb_option cb_font">Option 3</div>
+ <div class="cb_option cb_font">Option 4</div>
+ <div class="cb_option cb_font cb_select">Option 6</div>
+ <div class="cb_option cb_font">Option 7</div>
+ <div class="cb_option cb_font">Option 8</div>
+ <div class="cb_option cb_font">Option 9</div>
+ <div class="cb_option cb_font">Option 0</div>
+ </div>
+ </div>
+ </div>
+ </div>
+ <script type="text/javascript">
+ new RichFaces.ui.AutoComplete("myComboList", "myComboInput", {buttonId:'myComboButton'});
+ </script>
+</div>
+ text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block text block
+
+
+</body>
+</html>
Added: root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/autocomplete.js
===================================================================
--- root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/autocomplete.js (rev 0)
+++ root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/autocomplete.js 2010-06-10 14:22:51 UTC (rev 17595)
@@ -0,0 +1,75 @@
+(function ($, rf) {
+
+ rf.ui = rf.ui || {};
+ // Constructor definition
+ rf.ui.AutoComplete = function(componentId, fieldId, options) {
+ // call constructor of parent class
+ $super.constructor.call(this, componentId);
+ $p.attachToDom(componentId);
+ this.componentId = componentId;
+ this.fieldId = fieldId;
+ this.options = $.extend({}, defaultOptions, options);
+ this.hasFocus = 0;
+ this.namespace = rf.Event.createNamespace(this.name, this.componentId);
+ bindEventHandlers.call(this);
+ };
+
+ var $p ={};
+
+ // Extend component class and add protected methods from parent class to our container
+ $p = rf.BaseComponent.extend(rf.BaseComponent, rf.ui.AutoComplete, $p);
+
+ // define super class link
+ var $super = rf.ui.AutoComplete.$super;
+
+ var defaultOptions = {
+ };
+
+ var KEYS = {
+ };
+
+ var bindEventHandlers = function() {
+ if (this.options.buttonId) {
+ rf.Event.bindById(this.options.buttonId, "click."+this.namespace, onButtonShow, this);
+ var inputEventHandlers = {};
+ inputEventHandlers["focus."+this.namespace] = onFocus;
+ rf.Event.bindById(this.fieldId, inputEventHandlers, this);
+ }
+ }
+
+ var onButtonShow = function (event) {
+ if (this.isVisible) {
+ this.hide(event);
+ } else {
+ this.show(event);
+ }
+ }
+
+ var onHide = function (event) {
+ $(rf.getDomElement(this.componentId)).hide();
+ this.isVisible = false;
+ }
+
+ var onFocus = function (event) {
+ alert("aaa");
+ this.destroy();
+ this.hasFocus ++;
+ }
+
+ // Add new properties and methods
+ $.extend(rf.ui.AutoComplete.prototype, (function () {
+ return {
+ name:"AutoComplete",
+ show: function (event) {
+ $(rf.getDomElement(this.componentId)).show();
+ this.isVisible = true;
+ },
+ hide: onHide,
+ destroy: function () {
+ rf.Event.unbindById(this.options.buttonId, "."+this.namespace);
+ rf.Event.unbindById(this.fieldId, "."+this.namespace);
+ $super.destroy.call(this);
+ }
+ };
+ })());
+})(jQuery, RichFaces);
\ No newline at end of file
Added: root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/richfaces-selection.js
===================================================================
--- root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/richfaces-selection.js (rev 0)
+++ root/ui-sandbox/inputs/trunk/autocomplete/src/main/resources/META-INF/resources/script/richfaces-selection.js 2010-06-10 14:22:51 UTC (rev 17595)
@@ -0,0 +1,45 @@
+(function (richfaces) {
+
+ richfaces.Selection = richfaces.Selection || {};
+
+ richfaces.Selection.set = function (field, start, end) {
+ if(field.setSelectionRange) {
+ field.focus();
+ field.setSelectionRange(start, end);
+ } else if (field.createTextRange){
+ var range = field.createTextRange();
+ range.collapse(true);
+ range.moveEnd('character', pos);
+ range.moveStart('character', pos);
+ range.select();
+ }
+ }
+
+ richfaces.Selection.getStart = function(field)
+ {
+ if (field.setSelectionRange) {
+ return field.selectionStart;
+ } else if (document.selection && document.selection.createRange) {
+ var r = document.selection.createRange().duplicate();
+ r.moveEnd('character', field.value.length);
+ if (r.text == '') return field.value.length;
+ return field.value.lastIndexOf(r.text);
+ }
+ }
+
+ richfaces.Selection.getEnd = function(field)
+ {
+ if (field.setSelectionRange) {
+ return field.selectionEnd;
+ } else if (document.selection && document.selection.createRange) {
+ var r = document.selection.createRange().duplicate();
+ r.moveStart('character', -field.value.length);
+ return r.text.length;
+ }
+ }
+
+ richfaces.Selection.setCaretTo = function (field, pos)
+ {
+ richfaces.Selection.set(field, pos, pos);
+ }
+})(window.RichFaces || (window.RichFaces={}));
\ No newline at end of file
14 years, 6 months
JBoss Rich Faces SVN: r17594 - root/core/trunk/impl/src/main/resources/META-INF/resources.
by richfaces-svn-commits@lists.jboss.org
Author: pyaschenko
Date: 2010-06-10 10:21:37 -0400 (Thu, 10 Jun 2010)
New Revision: 17594
Modified:
root/core/trunk/impl/src/main/resources/META-INF/resources/richfaces-base-component.js
Log:
documentation comment added
Modified: root/core/trunk/impl/src/main/resources/META-INF/resources/richfaces-base-component.js
===================================================================
--- root/core/trunk/impl/src/main/resources/META-INF/resources/richfaces-base-component.js 2010-06-10 14:19:40 UTC (rev 17593)
+++ root/core/trunk/impl/src/main/resources/META-INF/resources/richfaces-base-component.js 2010-06-10 14:21:37 UTC (rev 17594)
@@ -150,7 +150,8 @@
* @function
* @name RichFaces.BaseComponent#destroy
*
- * */
+ * */
+ // TODO: add to article
destroy: function() {
}
};
14 years, 6 months
JBoss Rich Faces SVN: r17593 - in root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component: html and 1 other directory.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2010-06-10 10:19:40 -0400 (Thu, 10 Jun 2010)
New Revision: 17593
Modified:
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIColumnGroup.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlColumnGroup.java
Log:
Fixed CheckStyle violations in iteration
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIColumnGroup.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIColumnGroup.java 2010-06-10 14:17:06 UTC (rev 17592)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIColumnGroup.java 2010-06-10 14:19:40 UTC (rev 17593)
@@ -27,14 +27,12 @@
import javax.faces.component.UIComponent;
import javax.faces.component.UIPanel;
import javax.faces.context.FacesContext;
-import javax.faces.event.AbortProcessingException;
import org.ajax4jsf.model.DataVisitor;
import org.richfaces.renderkit.RowHolderBase;
public abstract class UIColumnGroup extends UIPanel implements Row, Column {
-
public Iterator<UIComponent> columns() {
return new DataTableColumnsIterator(this);
}
@@ -55,4 +53,4 @@
//TODO nick - implement in the proper way
visitor.process(context, null, argument);
}
- }
+}
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlColumnGroup.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlColumnGroup.java 2010-06-10 14:17:06 UTC (rev 17592)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlColumnGroup.java 2010-06-10 14:19:40 UTC (rev 17593)
@@ -1,11 +1,6 @@
package org.richfaces.component.html;
-import javax.faces.component.UIComponent;
-import javax.faces.context.FacesContext;
-import javax.faces.event.AbortProcessingException;
-
import org.richfaces.component.UIColumnGroup;
-import org.richfaces.component.UIDataTableBase;
public class HtmlColumnGroup extends UIColumnGroup {
14 years, 6 months