JBoss Rich Faces SVN: r17962 - root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2010-07-12 11:22:08 -0400 (Mon, 12 Jul 2010)
New Revision: 17962
Modified:
root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss
Log:
Updated comboBox skinning
Modified: root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss 2010-07-12 15:07:22 UTC (rev 17961)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss 2010-07-12 15:22:08 UTC (rev 17962)
@@ -18,7 +18,7 @@
}
input.cb_input {
- border: 0px;
+ border-width: 0px;
background: none;
width: 100%;
}
@@ -72,7 +72,7 @@
border-style: solid;
border-color: '#{richSkin.panelBorderColor}';
padding: 0px;
- background: '#{richSkin.tableBackgroundColor}';
+ background-color: '#{richSkin.tableBackgroundColor}';
}
.cb_list_scroll {
14 years, 6 months
JBoss Rich Faces SVN: r17961 - root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2010-07-12 11:07:22 -0400 (Mon, 12 Jul 2010)
New Revision: 17961
Modified:
root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss
Log:
Updated comboBox skinning
Modified: root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss 2010-07-12 15:05:54 UTC (rev 17960)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss 2010-07-12 15:07:22 UTC (rev 17961)
@@ -1,9 +1,3 @@
-* {
- font-size: 11px;
- font-family: verdana;
- color: #000000
-}
-
.cb_field_width {
width: 100px;
}
@@ -17,30 +11,35 @@
min-height: 20px;
}
-input.cb_font {
+.cb_input.cb_font, .cb_option.cb_font {
color: '#{richSkin.generalTextColor}';
+ font-size: '#{richSkin.generalSizeFont}';
+ font-family: '#{richSkin.generalFamilyFont}';
}
input.cb_input {
- border-width: 0px;
+ border: 0px;
background: none;
width: 100%;
}
.cb_field {
position: inline-block;
+ border-width: 1px;
+ border-style: solid;
border-color: '#{richSkin.panelBorderColor}';
display: inline-block;
background-image: "url(#{resource['org.richfaces.renderkit.html.images.ComboBoxFieldGradient']})";
background-repeat: repeat-x;
background-position: top left;
+ background-color: '#{richSkin.controlBackgroundColor}';
}
.cb_button {
background-image: "url(#{resource['org.richfaces.renderkit.html.images.ComboBoxButtonGradient']})";
background-repeat: repeat-x;
background-position: top left;
- background-color: #C0D1E7;
+ background-color: '#{richSkin.headerBackgroundColor}';
text-align: center;
border-left-style: solid;
border-left-width: 1px;
@@ -73,7 +72,7 @@
border-style: solid;
border-color: '#{richSkin.panelBorderColor}';
padding: 0px;
- background-color: '#{richSkin.tableBackgroundColor}';
+ background: '#{richSkin.tableBackgroundColor}';
}
.cb_list_scroll {
14 years, 6 months
JBoss Rich Faces SVN: r17960 - root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2010-07-12 11:05:54 -0400 (Mon, 12 Jul 2010)
New Revision: 17960
Added:
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubTableFixedChildrenIterator.java
Log:
rename
Added: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubTableFixedChildrenIterator.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubTableFixedChildrenIterator.java (rev 0)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubTableFixedChildrenIterator.java 2010-07-12 15:05:54 UTC (rev 17960)
@@ -0,0 +1,40 @@
+/*
+ * 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.component;
+
+import javax.faces.component.UIComponent;
+
+
+/**
+ * @author asmirnov
+ *
+ */
+public class SubTableFixedChildrenIterator extends DataTableFixedChildrenIterator {
+
+ public SubTableFixedChildrenIterator(UIDataTableBase dataTable) {
+ super(dataTable);
+ }
+
+ protected UIComponent getNextFacet() {
+ return null;
+ }
+}
14 years, 6 months
JBoss Rich Faces SVN: r17959 - in root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces: component/html and 2 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2010-07-12 11:04:09 -0400 (Mon, 12 Jul 2010)
New Revision: 17959
Removed:
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubtableFixedChildrenIterator.java
Modified:
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/DataTableDataIterator.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java
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/HtmlDataGrid.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataTable.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTable.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTableToggleControl.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionFilteringListener.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionSortingListener.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionToggleListener.java
Log:
add license headings
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/DataTableDataIterator.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/DataTableDataIterator.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/DataTableDataIterator.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -20,7 +20,6 @@
* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
*/
-
package org.richfaces.component;
import java.util.Iterator;
Deleted: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubtableFixedChildrenIterator.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubtableFixedChildrenIterator.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/SubtableFixedChildrenIterator.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,40 +0,0 @@
-/*
- * 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.component;
-
-import javax.faces.component.UIComponent;
-
-
-/**
- * @author asmirnov
- *
- */
-public class SubtableFixedChildrenIterator extends DataTableFixedChildrenIterator {
-
- public SubtableFixedChildrenIterator(UIDataTableBase dataTable) {
- super(dataTable);
- }
-
- protected UIComponent getNextFacet() {
- return null;
- }
-}
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.component;
import java.util.Iterator;
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-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlColumnGroup.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.component.html;
import org.richfaces.component.UIColumnGroup;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataGrid.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataGrid.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataGrid.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.component.html;
import org.richfaces.component.UIDataGrid;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataTable.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataTable.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataTable.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.component.html;
import org.richfaces.component.UIDataTable;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTable.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTable.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTable.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.component.html;
import org.richfaces.component.UISubTable;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTableToggleControl.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTableToggleControl.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlSubTableToggleControl.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.component.html;
import org.richfaces.component.UISubTableToggleControl;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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;
import java.io.IOException;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.taglib;
import javax.faces.view.facelets.ComponentConfig;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionFilteringListener.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionFilteringListener.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionFilteringListener.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.taglib;
import javax.el.MethodExpression;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionSortingListener.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionSortingListener.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionSortingListener.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.taglib;
import javax.el.MethodExpression;
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionToggleListener.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionToggleListener.java 2010-07-12 14:53:33 UTC (rev 17958)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/MethodExpressionToggleListener.java 2010-07-12 15:04:09 UTC (rev 17959)
@@ -1,3 +1,25 @@
+/*
+ * 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.taglib;
import javax.el.MethodExpression;
14 years, 6 months
JBoss Rich Faces SVN: r17958 - root/examples/iteration-demo/trunk/src/main/webapp.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2010-07-12 10:53:33 -0400 (Mon, 12 Jul 2010)
New Revision: 17958
Modified:
root/examples/iteration-demo/trunk/src/main/webapp/dataGrid.xhtml
Log:
Modified: root/examples/iteration-demo/trunk/src/main/webapp/dataGrid.xhtml
===================================================================
--- root/examples/iteration-demo/trunk/src/main/webapp/dataGrid.xhtml 2010-07-12 14:49:04 UTC (rev 17957)
+++ root/examples/iteration-demo/trunk/src/main/webapp/dataGrid.xhtml 2010-07-12 14:53:33 UTC (rev 17958)
@@ -1,66 +1,61 @@
-<?xml version='1.0' encoding='UTF-8'?>
-<!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:fn="http://java.sun.com/jsp/jstl/functions"
- xmlns:h="http://java.sun.com/jsf/html"
- xmlns:f="http://java.sun.com/jsf/core"
- xmlns:c="http://java.sun.com/jsp/jstl/core"
- xmlns:ui="http://java.sun.com/jsf/facelets"
- xmlns:rich="http://richfaces.org/rich"
- xmlns:ds="http://richfaces.org/datascroller">
-<!--
-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.
--->
- <h:head>
- <title>Richfaces DataGrid</title>
- <style>
- .label{
- font-weight:bold;
- }
- </style>
- </h:head>
-
- <h:body>
- <h:form>
- <rich:dataTable value="#{dataBean.employeeList}" var="record" rows="10">
- <f:facet name="header">
- <h:outputText value="Current date: #{dataBean.date}"/>
- </f:facet>
- <rich:column>
- <h:panelGrid columns="2">
- <h:outputText value="Name:" styleClass="label"></h:outputText>
- <h:outputText value="#{record.name}" />
- <h:outputText value="Title" styleClass="label"></h:outputText>
- <h:outputText value="#{record.title}" />
- <h:outputText value="E-mail:" styleClass="label"></h:outputText>
- <h:outputText value="#{record.EMail}" />
- </h:panelGrid>
- </rich:column>
- <f:facet name="footer">
- <ds:dataScroller />
- </f:facet>
- </rich:dataTable>
- </h:form>
- </h:body>
-</html>
+<!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:it="http://richfaces.org/iteration"
+ xmlns:a4j="http://richfaces.org/a4j"
+ >
+
+<!--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.
+-->
+
+<f:view contentType="text/html" />
+
+<h:head>
+ <title>Richfaces Tables</title>
+</h:head>
+
+<h:body>
+ <h:form id="form1">
+ <it:dataGrid columns="3" var="record" value="#{dataBean.employeeList}">
+ <f:facet name="header">
+ <h:outputText value="header"/>
+ </f:facet>
+
+ <f:facet name="footer">
+ <h:outputText value="footer"/>
+ </f:facet>
+
+ <f:facet name="сaption">
+ <h:outputText value="caption"/>
+ </f:facet>
+
+ <h:outputText value="#{record.name}"/>
+ <h:outputText value="#{record.title}"/>
+ <h:outputText value="#{record.EMail}"/>
+ </it:dataGrid>
+ </h:form>
+</h:body>
+</html>
14 years, 6 months
JBoss Rich Faces SVN: r17957 - in root/ui/iteration/trunk/tables/ui/src/main: java/org/richfaces/component/html and 4 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2010-07-12 10:49:04 -0400 (Mon, 12 Jul 2010)
New Revision: 17957
Added:
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataGrid.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java
root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/resources/datagrid.ecss
Modified:
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableRenderer.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataTableRenderer.java
root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/SubTableRenderer.java
root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.faces-config.xml
root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.taglib.xml
Log:
add datagrid impl with css styles, move put/get to the Attributes map methods from AbstarctTableBaseRenderer to the AbstractRowsRenderer
Added: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java (rev 0)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/UIDataGrid.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -0,0 +1,55 @@
+package org.richfaces.component;
+
+import java.util.Iterator;
+
+import javax.faces.component.UIComponent;
+
+/**
+ * @author Anton Belevich
+ *
+ */
+public class UIDataGrid extends UISequence implements Row {
+
+ public static final String HEADER_FACET_NAME = "header";
+
+ public static final String FOOTER_FACET_NAME = "footer";
+
+ public static final String CAPTION_FACET_NAME = "caption";
+
+ public static final String NODATA_FACET_NAME = "nodata";
+
+ enum PropertyKeys {
+ columns
+ }
+
+ public int getColumns() {
+ return (Integer)getStateHelper().eval(PropertyKeys.columns, 1);
+ }
+
+ public void setColumns(int count) {
+ getStateHelper().put(PropertyKeys.columns, count);
+ }
+
+ public Iterator<UIComponent> columns() {
+ //DataGrid doesn't work with column components
+ return null;
+ }
+
+ public UIComponent getHeaderFacet() {
+ return getFacet(HEADER_FACET_NAME);
+ }
+
+ public UIComponent getFooterFacet() {
+ return getFacet(FOOTER_FACET_NAME);
+ }
+
+ public UIComponent getCaptionFacet() {
+ return getFacet(CAPTION_FACET_NAME);
+ }
+
+ public UIComponent getNoDataFacet() {
+ return getFacet(NODATA_FACET_NAME);
+ }
+
+
+}
Added: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataGrid.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataGrid.java (rev 0)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/component/html/HtmlDataGrid.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -0,0 +1,12 @@
+package org.richfaces.component.html;
+
+import org.richfaces.component.UIDataGrid;
+
+public class HtmlDataGrid extends UIDataGrid {
+
+ public static final String COMPONENT_TYPE = "org.richfaces.DataGrid";
+
+ public HtmlDataGrid() {
+ setRendererType("org.richfaces.DataGridRenderer");
+ }
+}
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java 2010-07-12 14:37:10 UTC (rev 17956)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractRowsRenderer.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -77,4 +77,12 @@
public boolean getRendersChildren() {
return true;
}
+
+ protected String get(FacesContext context, String key) {
+ return (String)context.getAttributes().get(key);
+ }
+
+ protected void put(FacesContext context, String key, String value) {
+ context.getAttributes().put(key, value);
+ }
}
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java 2010-07-12 14:37:10 UTC (rev 17956)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableBaseRenderer.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -144,18 +144,10 @@
return get(context, id + CELL_ELEMENT_KEY);
}
- private String get(FacesContext context, String key) {
- return (String)context.getAttributes().get(key);
- }
-
- protected void put(FacesContext context, String id, String key, String value) {
- context.getAttributes().put(id + key, value);
- }
-
protected void saveRowStyles(FacesContext context, String id, String firstRowClass, String rowClass, String cellClass) {
- put(context, id, FIRST_ROW_CLASS_KEY, firstRowClass);
- put(context, id, ROW_CLASS_KEY, rowClass);
- put(context, id, CELL_CLASS_KEY, cellClass);
+ put(context, id + FIRST_ROW_CLASS_KEY, firstRowClass);
+ put(context, id + ROW_CLASS_KEY, rowClass);
+ put(context, id + CELL_CLASS_KEY, cellClass);
}
public void encodeStyleClass(ResponseWriter writer, FacesContext context, UIComponent component,
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableRenderer.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableRenderer.java 2010-07-12 14:37:10 UTC (rev 17956)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/AbstractTableRenderer.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -147,7 +147,7 @@
int rowCount = dataTableBase.getRowCount();
- put(facesContext, dataTableBase.getClientId(facesContext), CELL_ELEMENT_KEY, HTML.TD_ELEM);
+ put(facesContext, dataTableBase.getClientId(facesContext) + CELL_ELEMENT_KEY, HTML.TD_ELEM);
Object key = dataTableBase.getRowKey();
dataTableBase.captureOrigValue(facesContext);
Added: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java (rev 0)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataGridRenderer.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -0,0 +1,184 @@
+package org.richfaces.renderkit;
+
+import java.io.IOException;
+
+import javax.faces.application.ResourceDependencies;
+import javax.faces.application.ResourceDependency;
+import javax.faces.component.UIComponent;
+import javax.faces.context.FacesContext;
+import javax.faces.context.ResponseWriter;
+
+import org.ajax4jsf.renderkit.RendererUtils.HTML;
+import org.richfaces.component.UIDataGrid;
+
+/**
+ * @author Anton Belevich
+ *
+ */
+
+@ResourceDependencies({@ResourceDependency(library = "javax.faces", name = "jsf.js"),
+ @ResourceDependency(name = "jquery.js"), @ResourceDependency(name = "richfaces.js"),
+ @ResourceDependency(name = "richfaces-event.js"), @ResourceDependency(name = "richfaces-base-component.js"),
+ @ResourceDependency(name = "datagrid.ecss")})
+public class DataGridRenderer extends AbstractRowsRenderer {
+
+ private static final EncodeStrategy THEAD = new EncodeStrategy () {
+
+ public void begin(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+
+ UIDataGrid dataGrid = (UIDataGrid)component;
+ int columns = dataGrid.getColumns();
+
+ writer.startElement(HTML.THEAD_ELEMENT, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-thead", null);
+ writer.startElement(HTML.TR_ELEMENT, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-h", null);
+ writer.startElement(HTML.TH_ELEM, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-h-c", null);
+ writer.writeAttribute(HTML.COLSPAN_ATTRIBUTE, columns, null);
+ }
+
+ public void end(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+ writer.endElement(HTML.TH_ELEM);
+ writer.endElement(HTML.TR_ELEMENT);
+ writer.endElement(HTML.THEAD_ELEMENT);
+ }
+ };
+
+ private static final EncodeStrategy TFOOT = new EncodeStrategy () {
+
+ public void begin(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+
+ UIDataGrid dataGrid = (UIDataGrid)component;
+ int columns = dataGrid.getColumns();
+
+ writer.startElement(HTML.TFOOT_ELEMENT, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-tfoot", null);
+ writer.startElement(HTML.TR_ELEMENT, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-f", null);
+ writer.startElement(HTML.TD_ELEM, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-f-c", null);
+ writer.writeAttribute(HTML.COLSPAN_ATTRIBUTE, columns, null);
+ }
+
+ public void end(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+ writer.endElement(HTML.TD_ELEM);
+ writer.endElement(HTML.TR_ELEMENT);
+ writer.endElement(HTML.THEAD_ELEMENT);
+ }
+ };
+
+ private static final EncodeStrategy CAPTION = new EncodeStrategy() {
+ public void begin(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+ writer.startElement(HTML.CAPTION_ELEMENT, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-cap", null);
+ }
+
+ public void end(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+ writer.endElement(HTML.CAPTION_ELEMENT);
+ }
+ };
+
+ private static final EncodeStrategy NODATA = new EncodeStrategy() {
+ public void begin(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+ writer.startElement(HTML.CAPTION_ELEMENT, component);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-nd-c", null);
+ }
+
+ public void end(ResponseWriter writer, FacesContext context, UIComponent component, Object[] params)
+ throws IOException {
+ writer.endElement(HTML.CAPTION_ELEMENT);
+ }
+ };
+
+
+ @Override
+ public void encodeRow(ResponseWriter writer, FacesContext facesContext, RowHolderBase rowHolder) throws IOException {
+ UIDataGrid dataGrid = (UIDataGrid) rowHolder.getRow();
+
+ int columns = dataGrid.getColumns();
+ int processRow = rowHolder.getCurrentRow();
+
+ if (columns > 0 && (processRow % columns == 0)) {
+ if (processRow != 0) {
+ writer.endElement(HTML.TR_ELEMENT);
+ }
+ writer.startElement(HTML.TR_ELEMENT, dataGrid);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-r", null);
+ }
+
+ writer.startElement(HTML.TD_ELEM, dataGrid);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg-c", null);
+ getUtils().encodeId(facesContext, dataGrid);
+ renderChildren(facesContext, dataGrid);
+ writer.endElement(HTML.TD_ELEM);
+ }
+
+ public void encodeHeader(ResponseWriter writer, FacesContext facesContext, UIDataGrid dataGrid) throws IOException {
+ UIComponent footerFacet = dataGrid.getHeaderFacet();
+ encodeFacet(writer, facesContext, footerFacet, THEAD, dataGrid);
+ }
+
+ public void encodeFooter(ResponseWriter writer, FacesContext facesContext, UIDataGrid dataGrid) throws IOException {
+ UIComponent footerFacet = dataGrid.getFooterFacet();
+ encodeFacet(writer, facesContext, footerFacet, TFOOT, dataGrid);
+ }
+
+ public void encodeCaption(ResponseWriter writer, FacesContext facesContext, UIDataGrid dataGrid) throws IOException {
+ UIComponent captionFacet = dataGrid.getCaptionFacet();
+ encodeFacet(writer, facesContext, captionFacet, CAPTION, dataGrid);
+ }
+
+ private void encodeNoData(ResponseWriter writer, FacesContext facesContext, UIDataGrid dataGrid) throws IOException {
+ UIComponent noDataFacet = dataGrid.getNoDataFacet();
+ encodeFacet(writer, facesContext, noDataFacet, NODATA, dataGrid);
+ }
+
+ private void encodeFacet(ResponseWriter writer, FacesContext facesContext, UIComponent facet, EncodeStrategy strategy, UIDataGrid dataGrid) throws IOException{
+ if(facet != null && facet.isRendered()) {
+ strategy.begin(writer, facesContext, dataGrid, null);
+ facet.encodeAll(facesContext);
+ strategy.end(writer, facesContext, dataGrid, null);
+ }
+ }
+
+ @Override
+ protected void doEncodeChildren(ResponseWriter writer, FacesContext facesContext, UIComponent component)
+ throws IOException {
+ UIDataGrid dataGrid = (UIDataGrid)component;
+ writer.startElement(HTML.TABLE_ELEMENT, dataGrid);
+ writer.writeAttribute(HTML.ID_ATTRIBUTE, dataGrid.getClientId(facesContext), null);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg", null);
+
+ encodeCaption(writer, facesContext, dataGrid);
+ encodeHeader(writer, facesContext, dataGrid);
+ encodeFooter(writer, facesContext, dataGrid);
+
+ writer.startElement(HTML.TBODY_ELEMENT, dataGrid);
+ writer.writeAttribute(HTML.CLASS_ATTRIBUTE, "rf-dg", null);
+ if(dataGrid.getRowCount() > 0) {
+ processRows(writer, facesContext, dataGrid, null);
+ } else {
+ encodeNoData(writer, facesContext, dataGrid);
+ }
+ writer.endElement(HTML.TBODY_ELEMENT);
+ writer.endElement(HTML.TABLE_ELEMENT);
+ }
+
+ @Override
+ public RowHolderBase createRowHolder(FacesContext context, UIComponent component, Object[] options) {
+ return new RowHolder(context, (UIDataGrid)component);
+ }
+
+ @Override
+ protected Class<? extends UIComponent> getComponentClass() {
+ return UIDataGrid.class;
+ }
+}
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataTableRenderer.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataTableRenderer.java 2010-07-12 14:37:10 UTC (rev 17956)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/DataTableRenderer.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -379,7 +379,7 @@
}
protected void setupTableStartElement(FacesContext context, UIComponent component) {
- put(context, component.getClientId(context), CELL_ELEMENT_KEY, HTML.TH_ELEM);
+ put(context, component.getClientId(context) + CELL_ELEMENT_KEY, HTML.TH_ELEM);
}
public EncodeStrategy getHiddenContainerStrategy(UIDataTableBase dataTableBase) {
Modified: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/SubTableRenderer.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/SubTableRenderer.java 2010-07-12 14:37:10 UTC (rev 17956)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/renderkit/SubTableRenderer.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -383,7 +383,7 @@
}
protected void setupTableStartElement(FacesContext context, UIComponent component) {
- put(context, component.getClientId(context), CELL_ELEMENT_KEY, HTML.TD_ELEM);
+ put(context, component.getClientId(context) + CELL_ELEMENT_KEY, HTML.TD_ELEM);
}
protected UIDataTableBase findParent(UISubTable subTable) {
Added: root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java (rev 0)
+++ root/ui/iteration/trunk/tables/ui/src/main/java/org/richfaces/taglib/DataGridHandler.java 2010-07-12 14:49:04 UTC (rev 17957)
@@ -0,0 +1,28 @@
+package org.richfaces.taglib;
+
+import javax.faces.view.facelets.ComponentConfig;
+import javax.faces.view.facelets.ComponentHandler;
+import javax.faces.view.facelets.MetaRuleset;
+
+/**
+ * @author Anton Belevich
+ *
+ */
+public class DataGridHandler extends ComponentHandler {
+
+ private static final String ELEMENTS = "elements";
+
+ private static final String ROWS = "rows";
+
+ public DataGridHandler(ComponentConfig config) {
+ super(config);
+ }
+
+ @Override
+ protected MetaRuleset createMetaRuleset(Class type) {
+ MetaRuleset metaRuleset = super.createMetaRuleset(type);
+ metaRuleset.alias(ELEMENTS, ROWS);
+ return metaRuleset;
+ }
+
+}
Added: root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/resources/datagrid.ecss
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/resources/datagrid.ecss (rev 0)
+++ root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/resources/datagrid.ecss 2010-07-12 14:49:04 UTC (rev 17957)
@@ -0,0 +1,100 @@
+.rf-dg{
+ background-color:'#{richSkin.tableBackgroundColor}';
+ border-collapse:collapse;
+ border-left-width:'#{richSkin.tableBorderWidth}';
+ border-left-style:solid;
+ border-left-color:'#{richSkin.tableBorderColor}';
+ border-top-width:'#{richSkin.tableBorderWidth}';
+ border-top-style:solid;
+ border-top-color:'#{richSkin.tableBorderColor}';
+ empty-cells:show;
+}
+
+.rf-dg-nd-c{
+ border-bottom-width:'#{richSkin.tableBorderWidth}';
+ border-bottom-style:solid;
+ border-bottom-color:'#{richSkin.tableBorderColor}';
+ border-right-width:'#{richSkin.tableBorderWidth}';
+ border-right-style:solid;
+ border-right-color:'#{richSkin.tableBorderColor}';
+ color:'#{richSkin.generalTextColor}';
+ font-family:'#{richSkin.generalFamilyFont}';
+ font-size:'#{richSkin.generalSizeFont}';
+ padding:4px;
+}
+
+
+.rf-dg-cap{
+}
+
+.rf-dg-r{
+}
+
+.rf-dg-f-r{
+}
+
+.rf-dg-c{
+ border-bottom-width:'#{richSkin.tableBorderWidth}';
+ border-bottom-style:solid;
+ border-bottom-color:'#{richSkin.tableBorderColor}';
+ border-right-width:'#{richSkin.tableBorderWidth}';
+ border-right-style:solid;
+ border-right-color:'#{richSkin.tableBorderColor}';
+ color:'#{richSkin.generalTextColor}';
+ font-family:'#{richSkin.generalFamilyFont}';
+ font-size:'#{richSkin.generalSizeFont}';
+ padding:4px;
+}
+
+.rf-dg-h{
+}
+
+.rf-dg-h-f{
+}
+
+.rf-dg-h-c{
+ border-bottom-width:'#{richSkin.tableBorderWidth}';
+ border-bottom-style:solid;
+ border-bottom-color:'#{richSkin.tableBorderColor}';
+ border-right-width:'#{richSkin.tableBorderWidth}';
+ border-right-style:solid;
+ border-right-color:'#{richSkin.tableBorderColor}';
+ background-color : '#{richSkin.tableHeaderBackgroundColor}';
+ background-image : "url(#{resource['org.richfaces.renderkit.html.images.ColumnHeaderGradientImage']})";
+ background-position: top left;
+ color:'#{richSkin.tableHeaderTextColor}';
+ font-family:'#{richSkin.generalFamilyFont}';
+ font-size:'#{richSkin.generalSizeFont}';
+ font-weight:bold;
+ padding:4px;
+ text-align:center;
+}
+
+.rf-dg-th{
+ border-bottom-width:'#{richSkin.tableBorderWidth}';
+ border-bottom-style:solid;
+ border-bottom-color:'#{richSkin.tableBorderColor}';
+}
+
+.rf-dg-f {
+
+}
+
+.rf-dg-f-f{
+}
+
+.rf-dg-f-c{
+ border-bottom-width:'#{richSkin.tableBorderWidth}';
+ border-bottom-style:solid;
+ border-bottom-color:'#{richSkin.tableBorderColor}';
+ border-right-width:'#{richSkin.tableBorderWidth}';
+ border-right-style:solid;
+ border-right-color:'#{richSkin.tableBorderColor}';
+ color:'#{richSkin.generalTextColor}';
+ background-color:'#{richSkin.tableFooterBackgroundColor}';
+ font-family:'#{richSkin.generalFamilyFont}';
+ font-size:'#{richSkin.generalSizeFont}';
+ font-weight:bold;
+ padding:4px;
+ text-align:center;
+}
\ No newline at end of file
Modified: root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.faces-config.xml
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.faces-config.xml 2010-07-12 14:37:10 UTC (rev 17956)
+++ root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.faces-config.xml 2010-07-12 14:49:04 UTC (rev 17957)
@@ -69,7 +69,15 @@
<cdk:generate xmlns:cdk="http://richfaces.org/cdk/extensions">false</cdk:generate>
</component-extension>
</component>
+ <component>
+ <component-type>org.richfaces.DataGrid</component-type>
+ <component-class>org.richfaces.component.html.HtmlDataGrid</component-class>
+ <component-extension>
+ <cdk:generate xmlns:cdk="http://richfaces.org/cdk/extensions">false</cdk:generate>
+ </component-extension>
+ </component>
+
<render-kit>
<render-kit-id>HTML_BASIC</render-kit-id>
<renderer>
@@ -97,6 +105,10 @@
<renderer-type>org.richfaces.SubTableToggleControl</renderer-type>
<renderer-class>org.richfaces.renderkit.html.SubTableToggleControlRenderer</renderer-class>
</renderer>
-
+ <renderer>
+ <component-family>org.richfaces.Data</component-family>
+ <renderer-type>org.richfaces.DataGridRenderer</renderer-type>
+ <renderer-class>org.richfaces.renderkit.DataGridRenderer</renderer-class>
+ </renderer>
</render-kit>
</faces-config>
\ No newline at end of file
Modified: root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.taglib.xml
===================================================================
--- root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.taglib.xml 2010-07-12 14:37:10 UTC (rev 17956)
+++ root/ui/iteration/trunk/tables/ui/src/main/resources/META-INF/tables.taglib.xml 2010-07-12 14:49:04 UTC (rev 17957)
@@ -46,5 +46,12 @@
<renderer-type>org.richfaces.SubTableToggleControlRenderer</renderer-type>
</component>
</tag>
+ <tag>
+ <tag-name>dataGrid</tag-name>
+ <component>
+ <component-type>org.richfaces.DataGrid</component-type>
+ <renderer-type>org.richfaces.DataGridRenderer</renderer-type>
+ </component>
+ </tag>
</facelet-taglib>
14 years, 6 months
JBoss Rich Faces SVN: r17956 - root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces.
by richfaces-svn-commits@lists.jboss.org
Author: pyaschenko
Date: 2010-07-12 10:37:10 -0400 (Mon, 12 Jul 2010)
New Revision: 17956
Modified:
root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.js
root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/SelectBase.js
Log:
https://jira.jboss.org/browse/RF-8875
Modified: root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.js
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.js 2010-07-12 14:14:09 UTC (rev 17955)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.js 2010-07-12 14:37:10 UTC (rev 17956)
@@ -225,25 +225,6 @@
scrollToSelectedItem.call(this);
!noAutoFill && autoFill.call(this, this.inputValue, this.getSelectedItemValue());
},
-
- // value - string or index number
- /*setInputValue: function (value) {
- var type = typeof value;
- var input = rf.getDomElement(this.fieldId);
-
- if (type == "string") {
- this.inputValue = value;
- $super.setInputValue.call(this, value);
- } else {
- if (type != "number") {
- value = this.index;
- }
- if (value >=0 && value < this.items.length) {
- this.inputValue = getData(this.items.eq(this.index))[0];
- $super.setInputValue.call(this, this.inputValue);
- }
- }
- },*/
selectPrevItem: function () {
this.selectItem(-1, true);
Modified: root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/SelectBase.js
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/SelectBase.js 2010-07-12 14:14:09 UTC (rev 17955)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/SelectBase.js 2010-07-12 14:37:10 UTC (rev 17956)
@@ -202,9 +202,9 @@
this.hide();
return false;
break;
- /*case rf.KEYS.ESC:
+ case rf.KEYS.ESC:
this.hide();
- break;*/
+ break;
default:
if (!this.options.selectOnly) {
var _this = this;
14 years, 6 months
JBoss Rich Faces SVN: r17955 - root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/component.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2010-07-12 10:14:09 -0400 (Mon, 12 Jul 2010)
New Revision: 17955
Modified:
root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/component/AbstractComboBox.java
Log:
Added explicit renderers declaration to components
Modified: root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/component/AbstractComboBox.java
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/component/AbstractComboBox.java 2010-07-12 13:59:28 UTC (rev 17954)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/component/AbstractComboBox.java 2010-07-12 14:14:09 UTC (rev 17955)
@@ -34,6 +34,7 @@
import org.richfaces.cdk.annotations.Attribute;
import org.richfaces.cdk.annotations.JsfComponent;
+import org.richfaces.cdk.annotations.JsfRenderer;
import org.richfaces.cdk.annotations.Signature;
import org.richfaces.cdk.annotations.Tag;
import org.richfaces.cdk.annotations.TagType;
@@ -45,7 +46,9 @@
* @author Nick Belaevski
*
*/
-@JsfComponent(tag = @Tag(type = TagType.Facelets, handler = "org.richfaces.view.facelets.ComboBoxHandler"))
+@JsfComponent(tag = @Tag(type = TagType.Facelets, handler = "org.richfaces.view.facelets.ComboBoxHandler"),
+ renderer = @JsfRenderer(type = "org.richfaces.ComboBoxRenderer")
+)
public abstract class AbstractComboBox extends UIInput implements MetaComponentResolver, MetaComponentEncoder {
public static final String ITEMS_META_COMPONENT_ID = "items";
14 years, 6 months
JBoss Rich Faces SVN: r17954 - in root/ui-sandbox/inputs/trunk/combobox: src/main/java/org/richfaces/renderkit and 3 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2010-07-12 09:59:28 -0400 (Mon, 12 Jul 2010)
New Revision: 17954
Added:
root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/
root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/
root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxBaseGradient.java
root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxButtonGradient.java
root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxFieldGradient.java
Removed:
root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/combo_list_button.png
root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/combo_list_field.png
Modified:
root/ui-sandbox/inputs/trunk/combobox/pom.xml
root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss
Log:
ComboBox skinning
Modified: root/ui-sandbox/inputs/trunk/combobox/pom.xml
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/pom.xml 2010-07-12 13:44:49 UTC (rev 17953)
+++ root/ui-sandbox/inputs/trunk/combobox/pom.xml 2010-07-12 13:59:28 UTC (rev 17954)
@@ -66,7 +66,6 @@
<dependency>
<groupId>${jsf2.api.groupid}</groupId>
<artifactId>${jsf2.api.artifactid}</artifactId>
- <version>2.0.2</version>
<!--
TODO: remove this dependency it should inherited from perent poms
-->
Added: root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxBaseGradient.java
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxBaseGradient.java (rev 0)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxBaseGradient.java 2010-07-12 13:59:28 UTC (rev 17954)
@@ -0,0 +1,126 @@
+/*
+ * 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.renderkit.html.images;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.GradientPaint;
+import java.awt.Graphics2D;
+import java.awt.Rectangle;
+import java.io.DataInput;
+import java.io.DataOutput;
+import java.io.IOException;
+import java.util.Date;
+import java.util.Map;
+
+import javax.faces.context.FacesContext;
+
+import org.richfaces.resource.CacheableResource;
+import org.richfaces.resource.DynamicResource;
+import org.richfaces.resource.ImageType;
+import org.richfaces.resource.Java2DUserResource;
+import org.richfaces.resource.StateHolderResource;
+import org.richfaces.skin.Skin;
+import org.richfaces.skin.SkinFactory;
+
+/**
+ * @author Nick Belaevski
+ *
+ */
+@DynamicResource
+public abstract class ComboBoxBaseGradient implements Java2DUserResource, CacheableResource, StateHolderResource {
+
+ private static final Dimension DIMENSION = new Dimension(18, 8);
+
+ private String topColorSkinParameter;
+
+ private String bottomColorSkinParameter;
+
+ private Color topColor;
+
+ private Color bottomColor;
+
+ public Map<String, String> getResponseHeaders() {
+ return null;
+ }
+
+ public Date getLastModified() {
+ return null;
+ }
+
+ public ImageType getImageType() {
+ return ImageType.PNG;
+ }
+
+ public Dimension getDimension() {
+ return DIMENSION;
+ }
+
+ public void paint(Graphics2D graphics2d, Dimension dimension) {
+ GradientPaint paint = new GradientPaint(0, 0, topColor, 0, dimension.height, bottomColor);
+ graphics2d.setPaint(paint);
+ graphics2d.fill(new Rectangle(dimension));
+ }
+
+ public boolean isCacheable(FacesContext context) {
+ return true;
+ }
+
+ public Date getExpires(FacesContext context) {
+ return null;
+ }
+
+ public int getTimeToLive(FacesContext context) {
+ return 0;
+ }
+
+ public String getEntityTag(FacesContext context) {
+ return null;
+ }
+
+ public void writeState(FacesContext context, DataOutput dataOutput) throws IOException {
+ Skin skin = SkinFactory.getInstance().getSkin(context);
+
+ Integer topColor = skin.getColorParameter(context, topColorSkinParameter);
+ Integer bottomColor = skin.getColorParameter(context, bottomColorSkinParameter);
+
+ dataOutput.writeInt(topColor);
+ dataOutput.writeInt(bottomColor);
+ }
+
+ public void readState(FacesContext context, DataInput dataInput) throws IOException {
+ topColor = new Color(dataInput.readInt());
+ bottomColor = new Color(dataInput.readInt());
+ }
+
+ public boolean isTransient() {
+ return false;
+ }
+
+ protected void setTopColorSkinParameter(String topColorSkinParameter) {
+ this.topColorSkinParameter = topColorSkinParameter;
+ }
+
+ protected void setBottomColorSkinParameter(String bottomColorSkinParameter) {
+ this.bottomColorSkinParameter = bottomColorSkinParameter;
+ }
+}
Added: root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxButtonGradient.java
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxButtonGradient.java (rev 0)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxButtonGradient.java 2010-07-12 13:59:28 UTC (rev 17954)
@@ -0,0 +1,39 @@
+/*
+ * 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.renderkit.html.images;
+
+import org.richfaces.resource.DynamicResource;
+import org.richfaces.skin.Skin;
+
+/**
+ * @author Nick Belaevski
+ *
+ */
+@DynamicResource
+public class ComboBoxButtonGradient extends ComboBoxBaseGradient {
+
+ public ComboBoxButtonGradient() {
+ setTopColorSkinParameter(Skin.HEADER_GRADIENT_COLOR);
+ setBottomColorSkinParameter(Skin.HEADER_BACKGROUND_COLOR);
+ }
+
+}
Added: root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxFieldGradient.java
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxFieldGradient.java (rev 0)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/java/org/richfaces/renderkit/html/images/ComboBoxFieldGradient.java 2010-07-12 13:59:28 UTC (rev 17954)
@@ -0,0 +1,38 @@
+/*
+ * 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.renderkit.html.images;
+
+import org.richfaces.resource.DynamicResource;
+import org.richfaces.skin.Skin;
+
+/**
+ * @author Nick Belaevski
+ *
+ */
+@DynamicResource
+public class ComboBoxFieldGradient extends ComboBoxBaseGradient {
+
+ public ComboBoxFieldGradient() {
+ setTopColorSkinParameter(Skin.ADDITIONAL_BACKGROUND_COLOR);
+ setBottomColorSkinParameter(Skin.CONTROL_BACKGROUND_COLOR);
+ }
+}
Modified: root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss
===================================================================
--- root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss 2010-07-12 13:44:49 UTC (rev 17953)
+++ root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/ComboBox.ecss 2010-07-12 13:59:28 UTC (rev 17954)
@@ -18,33 +18,33 @@
}
input.cb_font {
- color: #000000 /*generalTextColor*/
+ color: '#{richSkin.generalTextColor}';
}
input.cb_input {
- border: 0px;
+ border-width: 0px;
background: none;
width: 100%;
}
.cb_field {
position: inline-block;
- border: 1px solid #A6A6A6 /*panelBorderColor*/;
+ border-color: '#{richSkin.panelBorderColor}';
display: inline-block;
- background-image: "url(#{resource['org.richfaces:combo_list_field.png']})";
+ background-image: "url(#{resource['org.richfaces.renderkit.html.images.ComboBoxFieldGradient']})";
background-repeat: repeat-x;
background-position: top left;
- /*gradient - from additionalBackgroundColor to controlBackgroundColor, background-color - controlBackgroundColor*/;
}
.cb_button {
- background-image: "url(#{resource['org.richfaces:combo_list_button.png']})";
+ background-image: "url(#{resource['org.richfaces.renderkit.html.images.ComboBoxButtonGradient']})";
background-repeat: repeat-x;
background-position: top left;
background-color: #C0D1E7;
- /*gradient - from headerGradientColor to headerBackgroundColor, background-color - headerBackgroundColor*/;
text-align: center;
- border-left: 1px solid #A6A6A6 /*panelBorderColor*/;
+ border-left-style: solid;
+ border-left-width: 1px;
+ border-left-color: '#{richSkin.panelBorderColor}';
width: 15px;
position: absolute;
top: 0px;
@@ -69,9 +69,11 @@
} /*DDL is hidden!!!!!*/
.cb_list_decoration {
- border: 1px solid #A6A6A6 /*panelBorderColor*/;
+ border-width: 1px;
+ border-style: solid;
+ border-color: '#{richSkin.panelBorderColor}';
padding: 0px;
- background: #FFFFFF; /*tableBackgroundColor*/
+ background-color: '#{richSkin.tableBackgroundColor}';
}
.cb_list_scroll {
@@ -90,7 +92,9 @@
padding: 1px;
width: 100%;
background-color: #DFE8F6;
- border: 1px dotted #a3bae9; /*generalTextColor*/
+ border-width: 1px;
+ border-style: dotted;
+ border-color: '#{richSkin.generalTextColor}';
}
.cb_shadow {
Deleted: root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/combo_list_button.png
===================================================================
(Binary files differ)
Deleted: root/ui-sandbox/inputs/trunk/combobox/src/main/resources/META-INF/resources/org.richfaces/combo_list_field.png
===================================================================
(Binary files differ)
14 years, 6 months
JBoss Rich Faces SVN: r17953 - root/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/a4jActionListener.
by richfaces-svn-commits@lists.jboss.org
Author: ppitonak(a)redhat.com
Date: 2010-07-12 09:44:49 -0400 (Mon, 12 Jul 2010)
New Revision: 17953
Modified:
root/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/a4jActionListener/A4JActionListenerTestCase.java
Log:
* test for invoking listener by type refactored
Modified: root/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/a4jActionListener/A4JActionListenerTestCase.java
===================================================================
--- root/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/a4jActionListener/A4JActionListenerTestCase.java 2010-07-12 13:15:29 UTC (rev 17952)
+++ root/tests/metamer/trunk/ftest-source/src/main/java/org/richfaces/tests/metamer/ftest/a4jActionListener/A4JActionListenerTestCase.java 2010-07-12 13:44:49 UTC (rev 17953)
@@ -19,9 +19,9 @@
* 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.ftest.a4jActionListener;
+import org.jboss.test.selenium.encapsulated.JavaScript;
import static org.jboss.test.selenium.utils.URLUtils.buildUrl;
import static org.testng.Assert.assertEquals;
import static org.testng.Assert.assertFalse;
@@ -30,6 +30,8 @@
import org.jboss.test.selenium.locator.ElementLocator;
import org.jboss.test.selenium.locator.JQueryLocator;
+import org.jboss.test.selenium.waiting.ajax.JavaScriptCondition;
+import org.jboss.test.selenium.waiting.selenium.SeleniumCondition;
import org.richfaces.tests.metamer.ftest.AbstractTestappTestCase;
import org.testng.annotations.AfterMethod;
import org.testng.annotations.Test;
@@ -63,11 +65,11 @@
public void testInvokeListenerByType(String templates) {
final String hashCodeRegExp = "@[0-9a-fA-F]{1,}$";
final String msg = "Implementation of ActionListener created and called: "
- + "org.richfaces.tests.metamer.bean.A4JActionListenerBean$ActionListenerImpl";
+ + "org.richfaces.tests.metamer.bean.A4JActionListenerBean$ActionListenerImpl";
selenium.click(invokeButtonType);
waitGui.until(elementPresent.locator(message));
- String output1 = selenium.getText(message);
+ final String output1 = selenium.getText(message);
assertEquals(output1.replaceAll(hashCodeRegExp, ""), msg, "Message after first invocation of listener by type.");
@@ -77,15 +79,14 @@
// do the same once again
selenium.click(invokeButtonType);
- waitGui.until(elementPresent.locator(message));
- String output2 = selenium.getText(message);
- assertEquals(output2.replaceAll(hashCodeRegExp, ""), msg, "Message after second invocation of listener by type");
+ waitModel.failWith("New object of class ActionListenerImpl should be instantiated.").until(
+ new SeleniumCondition() {
- // check that a new object of ActionListenerImpl was created
- String hashcode1 = output1.replace(msg, "");
- String hashcode2 = output2.replace(msg, "");
- assertFalse(hashcode1.equals(hashcode2), "New object of class ActionListenerImpl should be instantiated.");
+ public boolean isTrue() {
+ return !output1.equals(selenium.getText(message));
+ }
+ });
count = selenium.getCount(message);
assertEquals(count, 1, "Only one message should be displayed on the page.");
14 years, 6 months