JBoss Rich Faces SVN: r9994 - in trunk/sandbox/ui/extendedDataTable/src/main: resources/org/richfaces/renderkit/html/css and 1 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: piotr.buda
Date: 2008-08-08 10:54:04 -0400 (Fri, 08 Aug 2008)
New Revision: 9994
Modified:
trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedRowsRenderer.java
trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss
trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx
Log:
Removed obsolete CSS classes, renamed all dr-* classes
Modified: trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedRowsRenderer.java
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedRowsRenderer.java 2008-08-08 13:47:02 UTC (rev 9993)
+++ trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedRowsRenderer.java 2008-08-08 14:54:04 UTC (rev 9994)
@@ -199,8 +199,6 @@
"captionStyle");
writer.startElement("caption", table);
if (captionClass != null) {
- //TODO nick - dr-* classes are legacy and can be removed safely.
- // CSS styling can be defined in rich-* classes instead
captionClass = "extdt-caption rich-extdt-caption "
+ captionClass;
} else {
Modified: trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java 2008-08-08 13:47:02 UTC (rev 9993)
+++ trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java 2008-08-08 14:54:04 UTC (rev 9994)
@@ -187,7 +187,7 @@
writer,
table,
colums,
- "extdt-dr-menucell extdt-subheadercell rich-extdt-subheadercell",
+ "extdt-menucell extdt-subheadercell rich-extdt-subheadercell",
headerClass, "header", "th", numberOfColumns);
/* encoding additional empty column used in resizing columns */
writer.startElement("th", table);
@@ -645,7 +645,6 @@
// TODO - encode column attributes.
writer.startElement(HTML.DIV_ELEM, table);
writer.writeAttribute("class", "extdt-cell-div", null);
- // writer.writeAttribute("class", "dt-sdt-bcbody", null); //KAW
// IE
renderChildren(context, column);
writer.endElement(HTML.DIV_ELEM);
@@ -1564,7 +1563,7 @@
writer.writeAttribute(HTML.id_ATTRIBUTE, clientId + ":sepSpan",
null);
writer
- .writeAttribute(HTML.class_ATTRIBUTE, "dt-sdt-hsep",
+ .writeAttribute(HTML.class_ATTRIBUTE, "extdt-hsep",
null);
writer.endElement(HTML.SPAN_ELEM);
@@ -1573,19 +1572,19 @@
+ "left";
writer.startElement(HTML.SPAN_ELEM, column);
writer.writeAttribute(HTML.id_ATTRIBUTE, spanId, null);
- writer.writeAttribute(HTML.class_ATTRIBUTE, "dt-sdt-hdrop",
+ writer.writeAttribute(HTML.class_ATTRIBUTE, "extdt-hdrop",
null);
writer.writeAttribute(HTML.style_ATTRIBUTE,
"visibility: hidden;", null);
writer.startElement(HTML.SPAN_ELEM, column);
writer.writeAttribute(HTML.class_ATTRIBUTE,
- "dt-sdt-hdrop-top dt-sdt-hdrop-top-left", null);
+ "extdt-hdrop-top extdt-hdrop-top-left", null);
writer.writeAttribute(HTML.style_ATTRIBUTE,
"visibility: hidden;", null);
writer.endElement(HTML.SPAN_ELEM);
writer.startElement(HTML.SPAN_ELEM, column);
writer.writeAttribute(HTML.class_ATTRIBUTE,
- "dt-sdt-hdrop-bottom dt-sdt-hdrop-bottom-left", null);
+ "extdt-hdrop-bottom extdt-hdrop-bottom-left", null);
writer.writeAttribute(HTML.style_ATTRIBUTE,
"visibility: hidden;", null);
writer.endElement(HTML.SPAN_ELEM);
@@ -1596,19 +1595,19 @@
spanId = tableId + "_hdrop_" + dataColumn.getId() + "right";
writer.startElement(HTML.SPAN_ELEM, column);
writer.writeAttribute(HTML.id_ATTRIBUTE, spanId, null);
- writer.writeAttribute(HTML.class_ATTRIBUTE, "dt-sdt-hdrop",
+ writer.writeAttribute(HTML.class_ATTRIBUTE, "extdt-hdrop",
null);
writer.writeAttribute(HTML.style_ATTRIBUTE,
"visibility: hidden;", null);
writer.startElement(HTML.SPAN_ELEM, column);
writer.writeAttribute(HTML.class_ATTRIBUTE,
- "dt-sdt-hdrop-top dt-sdt-hdrop-top-right", null);
+ "extdt-hdrop-top extdt-hdrop-top-right", null);
writer.writeAttribute(HTML.style_ATTRIBUTE,
"visibility: hidden;", null);
writer.endElement(HTML.SPAN_ELEM);
writer.startElement(HTML.SPAN_ELEM, column);
writer.writeAttribute(HTML.class_ATTRIBUTE,
- "dt-sdt-hdrop-bottom dt-sdt-hdrop-bottom-right", null);
+ "extdt-hdrop-bottom extdt-hdrop-bottom-right", null);
writer.writeAttribute(HTML.style_ATTRIBUTE,
"visibility: hidden;", null);
writer.endElement(HTML.SPAN_ELEM);
Modified: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss 2008-08-08 13:47:02 UTC (rev 9993)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss 2008-08-08 14:54:04 UTC (rev 9994)
@@ -7,54 +7,20 @@
<f:verbatim>
.extdt-empty-cell{
}
- /**
- * Body cell declaration
- * dr-sdt-bc - reqired
- * dr-sdt-bcDef - default, used if no custom styles defined in body template
- */
- .dt-sdt-bc {
- box-sizing: border-box;
- -moz-box-sizing: border-box;
- -moz-outline: none;
- -moz-user-focus: normal;
- cursor: default;
- border-right: 1px solid;
- border-bottom: 1px solid;
- }
- .extdt-dr-table {
- table-layout: fixed;
- }
+ .extdt-table-layout {
+ table-layout: fixed;
+ }
+
+ .extdt-table-filterrow {
+ }
- .extdt-table-filterrow{
- }
-
- .dt-sdt-rb {
- font-weight: normal;
- white-space: nowrap;
- box-sizing: border-box;
- -moz-box-sizing: border-box;
- }
-
- .extdt-subheadercell {
- overflow: hidden;
- }
-
- .dt-sdt-bcbody {
- cursor: default;
- font-weight: normal;
- white-space: nowrap;
- overflow: hidden;
- -o-text-overflow: ellipsis;
- text-overflow: ellipsis;
- -moz-box-sizing: border-box;
- -moz-outline: none;
- width: 100%;
- height: 20px;
- }
+ .extdt-subheadercell {
+ overflow: hidden;
+ }
- .extdt-dr-menucell{
- }
+ .extdt-menucell{
+ }
.extdt-maindiv {
}
@@ -66,7 +32,6 @@
}
.extdt-fakeierow {
-
}
.extdt-thead {
@@ -129,7 +94,7 @@
background-position:center;
}
- .dr-sdt-hsplit {
+ .extdt-hsplit {
width:1px;
border-right: 1px dashed;
cursor: e-resize;
@@ -194,7 +159,7 @@
/**
* Header cells drop target
*/
- .dt-sdt-hdrop {
+ .extdt-hdrop {
cursor: pointer;
font-size: 1px;
width: 10px;
@@ -207,7 +172,7 @@
z-index: 61;
}
- .dt-sdt-hdrop-top {
+ .extdt-hdrop-top {
/*background-image: url(col-move-top.gif);*/
background-repeat: no-repeat;
/*background-position: top center;*/
@@ -218,17 +183,17 @@
top: -9px;
}
- .dt-sdt-hdrop-top-left{
+ .extdt-hdrop-top-left {
background-position: top left;
left: -5px;
}
- .dt-sdt-hdrop-top-right{
+ .extdt-hdrop-top-right {
background-position: top right;
right: -4px;
}
- .dt-sdt-hdrop-bottom {
+ .extdt-hdrop-bottom {
/*background-image: url(col-move-top.gif);*/
background-repeat: no-repeat;
/*background-position: bottom center;*/
@@ -243,12 +208,12 @@
padding: 4px;
}
- .dt-sdt-hdrop-bottom-left{
+ .extdt-hdrop-bottom-left{
background-position: bottom left;
left: -5px;
}
- .dt-sdt-hdrop-bottom-right{
+ .extdt-hdrop-bottom-right{
background-position: bottom right;
right: -4px;
}
@@ -280,7 +245,7 @@
/**
* Header cells separator
*/
- .dt-sdt-hsep {
+ .extdt-hsep {
/* background-image: url(grid-split.gif);*/
background-position: center;
background-repeat: repeat-y;
@@ -323,13 +288,13 @@
</u:style>
</u:selector>
-<u:selector name=".dr-sdt-hsplit" >
+<u:selector name=".extdt-hsplit" >
<u:style name="background-image">
<f:resource f:key="/org/richfaces/renderkit/html/images/s.gif"/>
</u:style>
</u:selector>
-<u:selector name=".dt-sdt-hdrop" >
+<u:selector name=".extdt-hdrop" >
<u:style name="background-image">
<f:resource f:key="/org/richfaces/renderkit/html/images/s.gif"/>
</u:style>
@@ -349,7 +314,7 @@
</u:style>
</u:selector>
-<u:selector name=".extdt-dr-table" >
+<u:selector name=".extdt-table-layout" >
<u:style name="background-color" skin="tableBackgroundColor" /> <!--tableBackgroundColor-->
<!-- <u:style name="border-collapse" value="inherit" /> fix RF-535 -->
<u:style name="empty-cells" value="show" />
@@ -393,19 +358,19 @@
</u:style>
</u:selector>
-<u:selector name=".dt-sdt-hdrop-top">
+<u:selector name=".extdt-hdrop-top">
<u:style name="background-image">
<f:resource f:key="/org/richfaces/renderkit/html/images/col-move-top.gif"/>
</u:style>
</u:selector>
-<u:selector name=".dt-sdt-hdrop-bottom">
+<u:selector name=".extdt-hdrop-bottom">
<u:style name="background-image">
<f:resource f:key="/org/richfaces/renderkit/html/images/col-move-bottom.gif"/>
</u:style>
</u:selector>
-<u:selector name=".dt-sdt-hsep">
+<u:selector name=".extdt-hsep">
<u:style name="background-image">
<f:resource f:key="/org/richfaces/renderkit/html/images/s.gif"/>
</u:style>
@@ -445,21 +410,6 @@
<u:style name="font-family" skin="generalFamilyFont"/> <!--generalFamilyFont-->
</u:selector>
-<u:selector name=".dr-subtable-cell" >
- <u:style name="border-right" value="solid"> <!--tableBorderColor-->
- <f:verbatim skin="tableBorderWidth" />
- <f:verbatim skin="tableBorderColor" />
- </u:style>
- <u:style name="border-bottom" value="solid"> <!--tableBorderColor-->
- <f:verbatim skin="tableBorderWidth" />
- <f:verbatim skin="tableBorderColor" />
- </u:style>
- <u:style name="padding" value="4px 4px 4px 4px"/>
- <u:style name="font-size" skin="generalSizeFont"/> <!--generalSizeFont-->
- <u:style name="color" skin="generalTextColor"/> <!--generalTextColor-->
- <u:style name="font-family" skin="generalFamilyFont"/> <!--generalFamilyFont-->
-</u:selector>
-
<u:selector name=".extdt-header" >
<u:style name="background-color" skin="headerBackgroundColor"/> <!--headerBackgroundColor-->
<u:style name="background-image" > <!--from headerGradientColor to headerBackgroundColor-->
@@ -604,62 +554,11 @@
</u:style> -->
</u:selector>
-<u:selector name=".dr-subtable-firstrow .dr-subtable-cell" >
- <!-- <u:style name="border" value="2px solid #c0c0c0"/>-->
-</u:selector>
-
-<u:selector name=".dr-subtable-header" >
- <u:style name="background-color" skin="additionalBackgroundColor"/> <!--additionalBackgroundColor-->
-</u:selector>
-
-<u:selector name=".dr-subtable-headercell" >
- <u:style name="border-right" value="solid"> <!--tableBorderColor-->
- <f:verbatim skin="tableBorderWidth" />
- <f:verbatim skin="tableBorderColor" />
- </u:style>
- <u:style name="border-bottom" value="solid"> <!--tableBorderColor-->
- <f:verbatim skin="tableBorderWidth" />
- <f:verbatim skin="tableBorderColor" />
- </u:style>
- <u:style name="padding" value="4px 4px 4px 4px"/>
- <u:style name="text-align" value="center"/>
- <u:style name="font-size" skin="generalSizeFont"/> <!--generalSizeFont-->
- <u:style name="color" skin="generalTextColor"/> <!--generalTextColor-->
- <u:style name="font-family" skin="generalFamilyFont"/> <!--generalFamilyFont-->
-</u:selector>
-
-
-<u:selector name=".dr-subtable-footer" >
- <u:style name="background-color" skin="tableSubfooterBackgroundColor"/> <!--tableSubfooterBackgroundColor-->
-</u:selector>
-
-<u:selector name=".dr-subtable-footercell" >
- <u:style name="border-right" value="solid"> <!--tableBorderColor-->
- <f:verbatim skin="tableBorderWidth" />
- <f:verbatim skin="tableBorderColor" />
- </u:style>
- <u:style name="border-bottom" value="solid"> <!--tableBorderColor-->
- <f:verbatim skin="tableBorderWidth" />
- <f:verbatim skin="tableBorderColor" />
- </u:style>
- <u:style name="padding" value="4px 4px 4px 4px"/>
- <u:style name="text-align" value="left"/>
-</u:selector>
-
-<u:selector name=".rich-sort-asc">
- <u:style name="background-image">
- <f:resource f:key="org.richfaces.renderkit.html.iconimages.DataTableIconSortAsc"/>
- </u:style>
-</u:selector>
-<u:selector name=".rich-sort-desc">
- <u:style name="background-image">
- <f:resource f:key="org.richfaces.renderkit.html.iconimages.DataTableIconSortDesc"/>
- </u:style>
-</u:selector>
<u:selector name=".extdt-row-selected">
<u:style name="background-color" skin="additionalBackgroundColor" />
</u:selector>
-<u:selector name=".dr-sdt-row-active">
+
+<u:selector name=".extdt-row-active">
<u:style name="color" skin="tabDisabledTextColor" />
</u:selector>
Modified: trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx 2008-08-08 13:47:02 UTC (rev 9993)
+++ trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx 2008-08-08 14:54:04 UTC (rev 9994)
@@ -39,6 +39,7 @@
/org/richfaces/renderkit/html/script/controlUtils.js,
/org/richfaces/renderkit/html/scripts/extended-data-table.js,
+ /org/richfaces/renderkit/html/scripts/drag-indicator.js,
/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js,
/org/richfaces/renderkit/html/scripts/ext-dt-simple-draggable.js,
@@ -57,17 +58,6 @@
to rendered areas manually in order to be handled correctly by AJAX updates
-->
- <div id="#{clientId}:dataTable_indicator" class="drgind_fly drgind_default drag_indicator" style="display: none;" >
- <f:call name="encodeNamespace" />
-
- <script type="text/javascript">
- //<![CDATA[
- #{this:encodeDragDropChildScripts(context, component)};
- //]]>
- </script>
- </div>
- <span id="#{clientId}:dataTable_indicator_span" />
-
<div
id="#{clientId}"
class="extdt-maindiv"
@@ -77,10 +67,20 @@
<div id="#{clientId}:od" class="extdt-outerdiv"
style="width:100%; height:100%;"
>
+ <div id="#{clientId}:dataTable_indicator" class="drgind_fly drgind_default drag_indicator" style="display: none;" >
+ <f:call name="encodeNamespace" />
+
+ <script type="text/javascript">
+ //<![CDATA[
+ #{this:encodeDragDropChildScripts(context, component)};
+ //]]>
+ </script>
+ </div>
+ <span id="#{clientId}:dataTable_indicator_span" />
<div id="#{clientId}:innerd" class="extdt-innerdiv" style="height:100%;width:100%;">
- <div id="#{clientId}:cs" class="dr-sdt-hsplit" style="display: none;"/>
+ <div id="#{clientId}:cs" class="extdt-hsplit" style="display: none;"/>
<table id="#{clientId}:tu"
- class="extdt-dr-table rich-table #{component.attributes['styleClass']}"
+ class="extdt-table-layout rich-table #{component.attributes['styleClass']}"
style="visibility:hidden;"
width="100%"
>
@@ -94,7 +94,7 @@
<td colspan="#{columnsCount}" style="padding: 0px;">
<div id="#{clientId}:sd" class="extdt-content" style="height:50px;width:100%;">
<table id="#{clientId}:n" width="100%"
- class="extdt-dr-table rich-table #{component.attributes['styleClass']}"
+ class="extdt-table-layout rich-table #{component.attributes['styleClass']}"
style="#{component.attributes['style']}"
>
<f:call name="utils.encodePassThruWithExclusions">
16 years, 5 months
JBoss Rich Faces SVN: r9993 - trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts.
by richfaces-svn-commits@lists.jboss.org
Author: piotr.buda
Date: 2008-08-08 09:47:02 -0400 (Fri, 08 Aug 2008)
New Revision: 9993
Modified:
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js
Log:
DnD JS names change
Modified: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js 2008-08-08 13:40:19 UTC (rev 9992)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js 2008-08-08 13:47:02 UTC (rev 9993)
@@ -144,53 +144,4 @@
elt.ils_rejectClass = rejectClass;
}
-DefaultExtDragIndicatorView =
-[
- new E('table',
- {
- 'style':'height : 100%; z-index: 2;',
- 'className':'drgind_internal',
- 'cellspacing':'0',
- 'cellpadding':'3',
- 'border':'0'
- },
- [
- new E('tbody',{},
- [
- new E('tr',{},
- [
- new E('td',
- {
- 'className':'drgind_marker'
- },
- [
- new ET(function (context) { return Richfaces.eval("marker", context)})
- ]
- ),
- new E('td',
- {
- 'className':'drgind_text'
- },
- [
- new E('div',
- {
- 'className':'drgind_wordcut drgind_text_content'
- },
- [
- new ET(function (context) { return Richfaces.eval("label", context)})
- ]
- )
- ]
- )
- ]
- )
- ]
- )
- ]
- ),
- new E('div',
- {
- 'className':'drgind_shadow'
- }
- )
-];
+
16 years, 5 months
JBoss Rich Faces SVN: r9992 - trunk/ui/contextMenu/src/main/config/component.
by richfaces-svn-commits@lists.jboss.org
Author: smukhina
Date: 2008-08-08 09:40:19 -0400 (Fri, 08 Aug 2008)
New Revision: 9992
Modified:
trunk/ui/contextMenu/src/main/config/component/contextMenu.xml
Log:
http://jira.jboss.com/jira/browse/RF-696
Tables of attributes, correcting attributes descriptions
Modified: trunk/ui/contextMenu/src/main/config/component/contextMenu.xml
===================================================================
--- trunk/ui/contextMenu/src/main/config/component/contextMenu.xml 2008-08-08 13:14:23 UTC (rev 9991)
+++ trunk/ui/contextMenu/src/main/config/component/contextMenu.xml 2008-08-08 13:40:19 UTC (rev 9992)
@@ -103,7 +103,7 @@
<name>attachTiming</name>
<classname>java.lang.String</classname>
<description>
- Defines the timing when the menu is attached to the target element. Default value is "onavailable".
+ Defines the timing when the menu is attached to the target element. Possible values "onload", "immediate", "onavailable" (default). Default value is "onavailable".
</description>
<defaultvalue>"onavailable"</defaultvalue>
</property>
16 years, 5 months
JBoss Rich Faces SVN: r9991 - trunk/cdk/generator/src/main/java/org/ajax4jsf/templatecompiler/elements/vcp.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2008-08-08 09:14:23 -0400 (Fri, 08 Aug 2008)
New Revision: 9991
Modified:
trunk/cdk/generator/src/main/java/org/ajax4jsf/templatecompiler/elements/vcp/HeaderResourceElement.java
Log:
https://jira.jboss.org/jira/browse/RF-4119
Modified: trunk/cdk/generator/src/main/java/org/ajax4jsf/templatecompiler/elements/vcp/HeaderResourceElement.java
===================================================================
--- trunk/cdk/generator/src/main/java/org/ajax4jsf/templatecompiler/elements/vcp/HeaderResourceElement.java 2008-08-08 13:10:40 UTC (rev 9990)
+++ trunk/cdk/generator/src/main/java/org/ajax4jsf/templatecompiler/elements/vcp/HeaderResourceElement.java 2008-08-08 13:14:23 UTC (rev 9991)
@@ -72,7 +72,7 @@
List paths = new ArrayList(tokenizer.countTokens());
List keyz = new ArrayList(tokenizer.countTokens());
while (tokenizer.hasMoreTokens()) {
- String token = tokenizer.nextToken();
+ String token = tokenizer.nextToken().trim();
String path;
if (token.startsWith(NEW)) {
16 years, 5 months
JBoss Rich Faces SVN: r9990 - trunk/test-applications/jsp/src/main/java/validator.
by richfaces-svn-commits@lists.jboss.org
Author: mvitenkov
Date: 2008-08-08 09:10:40 -0400 (Fri, 08 Aug 2008)
New Revision: 9990
Modified:
trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java
Log:
Modified: trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java
===================================================================
--- trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java 2008-08-08 13:08:30 UTC (rev 9989)
+++ trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java 2008-08-08 13:10:40 UTC (rev 9990)
@@ -9,6 +9,7 @@
import javax.faces.model.SelectItem;
import org.ajax4jsf.event.AjaxEvent;
+import org.ajax4jsf.model.KeepAlive;
import org.hibernate.validator.AssertFalse;
import org.hibernate.validator.AssertTrue;
import org.hibernate.validator.CreditCardNumber;
@@ -35,7 +36,7 @@
private boolean assertTrue;
@Future(message="Future validation failed!")
private Calendar dateValue;
- @Pattern(regex="^\b1234\b*$") //Searh "1234" as a whole word
+
private int intValue;
@EAN(message="EAN validation failed")
private String ean;
16 years, 5 months
JBoss Rich Faces SVN: r9989 - trunk/test-applications/jsp/src/main/java/validator.
by richfaces-svn-commits@lists.jboss.org
Author: mvitenkov
Date: 2008-08-08 09:08:30 -0400 (Fri, 08 Aug 2008)
New Revision: 9989
Modified:
trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java
Log:
Modified: trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java
===================================================================
--- trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java 2008-08-08 13:08:17 UTC (rev 9988)
+++ trunk/test-applications/jsp/src/main/java/validator/ValidatorBean.java 2008-08-08 13:08:30 UTC (rev 9989)
@@ -65,7 +65,17 @@
private String rangeValue;
@NotEmpty(message="rich:beanValidator work")
private String newValue;
+ @Pattern(regex="^1234*$") //Searh "1234" as a whole word
+ private String patternValue;
+ public String getPatternValue() {
+ return patternValue;
+ }
+
+ public void setPatternValue(String patternValue) {
+ this.patternValue = patternValue;
+ }
+
public String getRangeValue() {
return rangeValue;
}
@@ -244,8 +254,8 @@
public ValidatorBean(){
this.ajaxSingle = true;
- this.text = "mvitenkov(a)exadel.com";
- this.intValue = 1234;
+ this.text = "mvitenkov(a)exadel.com";
+ this.patternValue = "1234";
this.dateValue = Calendar.getInstance();
dateValue.set(Calendar.MONTH,8);
dateValue.set(Calendar.DATE,5);
16 years, 5 months
JBoss Rich Faces SVN: r9988 - trunk/test-applications/jsp/src/main/webapp/Validator.
by richfaces-svn-commits@lists.jboss.org
Author: mvitenkov
Date: 2008-08-08 09:08:17 -0400 (Fri, 08 Aug 2008)
New Revision: 9988
Modified:
trunk/test-applications/jsp/src/main/webapp/Validator/Validator.jsp
Log:
Modified: trunk/test-applications/jsp/src/main/webapp/Validator/Validator.jsp
===================================================================
--- trunk/test-applications/jsp/src/main/webapp/Validator/Validator.jsp 2008-08-08 12:39:52 UTC (rev 9987)
+++ trunk/test-applications/jsp/src/main/webapp/Validator/Validator.jsp 2008-08-08 13:08:17 UTC (rev 9988)
@@ -3,162 +3,174 @@
<%@ taglib uri="http://richfaces.org/a4j" prefix="a4j"%>
<%@ taglib uri="http://richfaces.org/rich" prefix="rich"%>
<f:subview id="validatorSubviewID">
-<a4j:region>
- <rich:panel>
- <f:facet name="header">
- <h:outputText>Single input field with label and message. Validated by AJAX on every changing.</h:outputText>
- </f:facet>
- <h:outputLabel for="ltext" value="#{lengthBean.textDescription}" />
- <h:inputText id="ltext" value="#{lengthBean.text}">
- <rich:ajaxValidator event="onchange" />
- </h:inputText>
- <rich:message for="ltext" showDetail="true" showSummary="true" />
- </rich:panel>
- <h2>Input fields with label and message in the JSF dataTable. Each
- field validated by AJAX on "onchange" event</h2>
- <rich:graphValidator value="#{data}" binding="#{data.graphValidatorComponent}" id="graphValidatorID"
- rendered="#{data.rendered}">
- <rich:dataTable value="#{data.beans}" var="bean" id="table">
+ <a4j:region>
+ <rich:panel>
<f:facet name="header">
- <h:outputText
- value="Validate values in the data table. Total sum for an all integer values validated for a value less then 20" />
+ <h:outputText>Single input field with label and message. Validated by AJAX on every changing.</h:outputText>
</f:facet>
-
- <h:column>
+ <h:outputLabel for="ltext" value="#{lengthBean.textDescription}" />
+ <h:inputText id="ltext" value="#{lengthBean.text}">
+ <rich:ajaxValidator event="onchange" />
+ </h:inputText>
+ <rich:message for="ltext" showDetail="true" showSummary="true" />
+ </rich:panel>
+ <h2>Input fields with label and message in the JSF dataTable.
+ Each field validated by AJAX on "onchange" event</h2>
+ <rich:graphValidator value="#{data}"
+ binding="#{data.graphValidatorComponent}" id="graphValidatorID"
+ rendered="#{data.rendered}">
+ <rich:dataTable value="#{data.beans}" var="bean" id="table">
<f:facet name="header">
- <h:outputText value="text field" />
+ <h:outputText
+ value="Validate values in the data table. Total sum for an all integer values validated for a value less then 20" />
</f:facet>
- <h:outputLabel for="text" value="#{bean.textDescription}" />
- <h:inputText id="text" value="#{bean.text}">
- <rich:ajaxValidator event="onchange" />
- </h:inputText>
- </h:column>
- <h:column>
- <f:facet name="header">
- <h:outputText value="integer field" />
+
+ <h:column>
+ <f:facet name="header">
+ <h:outputText value="text field" />
+ </f:facet>
+ <h:outputLabel for="text" value="#{bean.textDescription}" />
+ <h:inputText id="text" value="#{bean.text}">
+ <rich:ajaxValidator event="onchange" />
+ </h:inputText>
+ </h:column>
+ <h:column>
+ <f:facet name="header">
+ <h:outputText value="integer field" />
+ </f:facet>
+ <h:outputLabel for="intValue" value="#{bean.intDescription}" />
+ <h:inputText id="intValue" value="#{bean.intValue}">
+ <rich:ajaxValidator event="onchange" />
+ </h:inputText>
+ <rich:message for="intValue" showDetail="true" showSummary="true" />
+ </h:column>
+ <f:facet name="footer">
+ <h:panelGroup>
+ <h:outputText>in addition to fields validation, total sum for an all integer values validated for a value less then 20.</h:outputText>
+ <a4j:commandButton value="Submit all fields"></a4j:commandButton>
+ </h:panelGroup>
</f:facet>
- <h:outputLabel for="intValue" value="#{bean.intDescription}" />
- <h:inputText id="intValue" value="#{bean.intValue}">
- <rich:ajaxValidator event="onchange" />
- </h:inputText>
- <rich:message for="intValue" showDetail="true" showSummary="true" />
- </h:column>
- <f:facet name="footer">
- <h:panelGroup>
- <h:outputText>in addition to fields validation, total sum for an all integer values validated for a value less then 20.</h:outputText>
- <a4j:commandButton value="Submit all fields"></a4j:commandButton>
- </h:panelGroup>
- </f:facet>
- </rich:dataTable>
- </rich:graphValidator>
+ </rich:dataTable>
+ </rich:graphValidator>
</a4j:region>
<br />
<%--<rich:graphValidator value="#{graphValidator}">--%>
- <h:panelGrid columns="2" border="2" id="panelGridID">
+ <h:panelGrid columns="2" border="2" id="panelGridID">
- <f:facet name="header">
- <h:outputText value="Ajax Validator test" />
- </f:facet>
+ <f:facet name="header">
+ <h:outputText value="Ajax Validator test" />
+ </f:facet>
- <h:outputLabel for="mailValue" value="Mail validation:" />
- <h:panelGroup>
- <h:inputText value="#{validator.text}" id="mailValue">
- <rich:ajaxValidator ajaxSingle="#{validator.ajaxSingle}" binding="#{validator.ajaxValidatorComponent}"
- data="{param1:'param1',param2:'param2'}" disableDefault="#{validator.disableDefault}" event="onchange" eventsQueue="#{validator.eventsQueue}"
- focus="mailValue" id="ajaxValidatorID" ignoreDupResponses="#{validator.ignoreDupResponses}" immediate="#{validator.immediate}"
- limitToList="#{validator.limitToList}" onbeforedomupdate="#{event.onbeforedomupdate}" oncomplete="#{event.oncomplete}" onsubmit="#{event.onsubmit}"
- parentProperties="#{validator.parentProperties}" process="mailValue,booleanValue,assertTrue,eanValue,creditValue" rendered="#{validator.rendered}"
- renderRegionOnly="#{validator.renderRegionOnly}" requestDelay="#{validator.requestDelay}" reRender="mailValue,booleanValue,assertTrue,eanValue,creditValue"
- selfRendered="#{validator.selfRendered}" status="mailValue" submitted="#{validator.submitted}" timeout="#{validator.timeout}"></rich:ajaxValidator>
- </h:inputText>
- <rich:message for="mailValue" showDetail="true" showSummary="true" />
- </h:panelGroup>
+ <h:outputLabel for="mailValue" value="Mail validation:" />
+ <h:panelGroup>
+ <h:inputText value="#{validator.text}" id="mailValue">
+ <rich:ajaxValidator binding="#{validator.ajaxValidatorComponent}"
+ data="{param1:'param1',param2:'param2'}"
+ disableDefault="#{validator.disableDefault}" event="onchange"
+ eventsQueue="#{validator.eventsQueue}" focus="mailValue"
+ id="ajaxValidatorID"
+ ignoreDupResponses="#{validator.ignoreDupResponses}"
+ immediate="#{validator.immediate}"
+ limitToList="#{validator.limitToList}"
+ onbeforedomupdate="#{event.onbeforedomupdate}"
+ oncomplete="#{event.oncomplete}" onsubmit="#{event.onsubmit}"
+ parentProperties="#{validator.parentProperties}"
+ process="mailValue,booleanValue,assertTrue,eanValue,creditValue"
+ rendered="#{validator.rendered}"
+ renderRegionOnly="#{validator.renderRegionOnly}"
+ requestDelay="#{validator.requestDelay}"
+ reRender="mailValue,booleanValue,assertTrue,eanValue,creditValue"
+ selfRendered="#{validator.selfRendered}" status="mailValue"
+ submitted="#{validator.submitted}" timeout="#{validator.timeout}"></rich:ajaxValidator>
+ </h:inputText>
+ <rich:message for="mailValue" showDetail="true" showSummary="true" />
+ </h:panelGroup>
- <h:outputLabel for="booleanValue" value="AssertFalse validation:" />
- <h:panelGroup>
- <h:selectBooleanCheckbox value="#{validator.booleanValue}"
- id="booleanValue">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:selectBooleanCheckbox>
- <rich:message for="booleanValue" showDetail="true"
- showSummary="true" />
- </h:panelGroup>
+ <h:outputLabel for="booleanValue" value="AssertFalse validation:" />
+ <h:panelGroup>
+ <h:selectBooleanCheckbox value="#{validator.booleanValue}"
+ id="booleanValue">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:selectBooleanCheckbox>
+ <rich:message for="booleanValue" showDetail="true" showSummary="true" />
+ </h:panelGroup>
- <h:outputLabel for="assertTrue" value="AssertTrue validation:" />
- <h:panelGroup>
- <h:selectBooleanCheckbox value="#{validator.assertTrue}"
- id="assertTrue">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:selectBooleanCheckbox>
- <rich:message for="assertTrue" showDetail="true" showSummary="true" />
- </h:panelGroup>
-
+ <h:outputLabel for="assertTrue" value="AssertTrue validation:" />
+ <h:panelGroup>
+ <h:selectBooleanCheckbox value="#{validator.assertTrue}"
+ id="assertTrue">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:selectBooleanCheckbox>
+ <rich:message for="assertTrue" showDetail="true" showSummary="true" />
+ </h:panelGroup>
+
<h:outputLabel for="dateValue" value="Future validation:" />
<h:panelGroup>
- <h:inputText value="#{validator.dateValue}" id="dateValue" converter="dateValueConverter">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:inputText>
- <rich:message for="dateValue" showDetail="true" showSummary="true" />
+ <h:inputText value="#{validator.dateValue}" id="dateValue"
+ converter="dateValueConverter">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:inputText>
+ <rich:message for="dateValue" showDetail="true" showSummary="true" />
</h:panelGroup>
- <%--
+
<h:outputLabel for="patternValue" value="Pattern(1234) validation:" />
<h:panelGroup>
- <h:inputText value="#{validator.intValue}" id="patternValue">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:inputText>
- <rich:message for="patternValue" showDetail="true" showSummary="true" />
+ <h:inputText value="#{validator.patternValue}" id="patternValue">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:inputText>
+ <rich:message for="patternValue" showDetail="true" showSummary="true" />
</h:panelGroup>
- --%>
- <h:outputLabel for="eanValue" value="EAN validation:" />
- <h:panelGroup>
- <h:inputText value="#{validator.ean}" id="eanValue">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:inputText>
- <rich:message for="eanValue" showDetail="true" showSummary="true" />
- </h:panelGroup>
- <h:outputLabel for="creditValue" value="CreditCardNumber validation:" />
- <h:panelGroup>
- <h:inputText value="#{validator.creditValue}" id="creditValue">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:inputText>
- <rich:message for="creditValue" showDetail="true" showSummary="true" />
- </h:panelGroup>
+ <h:outputLabel for="eanValue" value="EAN validation:" />
+ <h:panelGroup>
+ <h:inputText value="#{validator.ean}" id="eanValue">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:inputText>
+ <rich:message for="eanValue" showDetail="true" showSummary="true" />
+ </h:panelGroup>
- <h:outputLabel for="sizeValues" value="Size validation:" />
- <h:panelGroup>
- <h:selectOneMenu value="#{validator.sizeValue}">
- <f:selectItems id="sizeValues" value="#{validator.sizeValues}"></f:selectItems>
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:selectOneMenu>
- <rich:message for="sizeValues" showDetail="true" showSummary="true" />
- </h:panelGroup>
+ <h:outputLabel for="creditValue" value="CreditCardNumber validation:" />
+ <h:panelGroup>
+ <h:inputText value="#{validator.creditValue}" id="creditValue">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:inputText>
+ <rich:message for="creditValue" showDetail="true" showSummary="true" />
+ </h:panelGroup>
- <h:outputLabel for="digit" value="Digits validation:(x.xxx)" />
- <h:panelGroup>
- <h:inputText value="#{validator.digit}" id="digit">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:inputText>
- <rich:message for="digit" showDetail="true" showSummary="true" />
- </h:panelGroup>
+ <h:outputLabel for="sizeValues" value="Size validation:" />
+ <h:panelGroup>
+ <h:selectOneMenu value="#{validator.sizeValue}">
+ <f:selectItems id="sizeValues" value="#{validator.sizeValues}"></f:selectItems>
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:selectOneMenu>
+ <rich:message for="sizeValues" showDetail="true" showSummary="true" />
+ </h:panelGroup>
- <h:outputLabel for="range" value="Range validation(0-15):" />
- <h:panelGroup>
- <h:inputText value="#{validator.rangeValue}" id="range">
- <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
- </h:inputText>
- <rich:message for="range" showDetail="true" showSummary="true" />
- </h:panelGroup>
+ <h:outputLabel for="digit" value="Digits validation:(x.xxx)" />
+ <h:panelGroup>
+ <h:inputText value="#{validator.digit}" id="digit">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:inputText>
+ <rich:message for="digit" showDetail="true" showSummary="true" />
+ </h:panelGroup>
- <h:outputText value="total length should be less than 50" />
- <a4j:commandButton value="validate all fields" reRender="panelGridID"></a4j:commandButton>
+ <h:outputLabel for="range" value="Range validation(0-15):" />
+ <h:panelGroup>
+ <h:inputText value="#{validator.rangeValue}" id="range">
+ <rich:ajaxValidator event="onchange"></rich:ajaxValidator>
+ </h:inputText>
+ <rich:message for="range" showDetail="true" showSummary="true" />
+ </h:panelGroup>
- <f:facet name="footer">
- <h:outputText value="...together with graphValidator" />
- </f:facet>
+ <h:outputText value="total length should be less than 50" />
+ <a4j:commandButton value="validate all fields" reRender="panelGridID"></a4j:commandButton>
- </h:panelGrid>
+ <f:facet name="footer">
+ <h:outputText value="...together with graphValidator" />
+ </f:facet>
+
+ </h:panelGrid>
<%--</rich:graphValidator>--%>
16 years, 5 months
JBoss Rich Faces SVN: r9987 - trunk/ui/combobox/src/main/config/component.
by richfaces-svn-commits@lists.jboss.org
Author: abelevich
Date: 2008-08-08 08:39:52 -0400 (Fri, 08 Aug 2008)
New Revision: 9987
Modified:
trunk/ui/combobox/src/main/config/component/combobox.xml
Log:
https://jira.jboss.org/jira/browse/RF-3287
Modified: trunk/ui/combobox/src/main/config/component/combobox.xml
===================================================================
--- trunk/ui/combobox/src/main/config/component/combobox.xml 2008-08-08 12:37:39 UTC (rev 9986)
+++ trunk/ui/combobox/src/main/config/component/combobox.xml 2008-08-08 12:39:52 UTC (rev 9987)
@@ -296,6 +296,11 @@
<name>maxlength</name>
<classname>int</classname>
</property>
+ <property hidden="true" existintag="false" exist="false" >
+ <name>accesskey</name>
+ <classname>java.lang.String</classname>
+ <description></description>
+ </property>
</properties>
</component>
</components>
16 years, 5 months
JBoss Rich Faces SVN: r9986 - branches/3.1.x/framework/impl/src/main/java/org/ajax4jsf/application.
by richfaces-svn-commits@lists.jboss.org
Author: nbelaevski
Date: 2008-08-08 08:37:39 -0400 (Fri, 08 Aug 2008)
New Revision: 9986
Modified:
branches/3.1.x/framework/impl/src/main/java/org/ajax4jsf/application/AjaxStateManager.java
Log:
https://jira.jboss.org/jira/browse/RF-4108
https://jira.jboss.org/jira/browse/RF-4120
Modified: branches/3.1.x/framework/impl/src/main/java/org/ajax4jsf/application/AjaxStateManager.java
===================================================================
--- branches/3.1.x/framework/impl/src/main/java/org/ajax4jsf/application/AjaxStateManager.java 2008-08-08 10:19:53 UTC (rev 9985)
+++ branches/3.1.x/framework/impl/src/main/java/org/ajax4jsf/application/AjaxStateManager.java 2008-08-08 12:37:39 UTC (rev 9986)
@@ -29,6 +29,7 @@
import java.io.ObjectInputStream;
import java.io.ObjectOutput;
import java.io.ObjectOutputStream;
+import java.io.ObjectStreamClass;
import java.io.Serializable;
import java.lang.reflect.Constructor;
import java.util.ArrayList;
@@ -262,7 +263,14 @@
if (ContextInitParameters.isSerializeServerState(context)) {
ObjectInputStream ois = null;
try {
- ois = new ObjectInputStream(new ByteArrayInputStream((byte[]) state));
+ ois = new ObjectInputStream(new ByteArrayInputStream((byte[]) state)) {
+
+ protected Class resolveClass(ObjectStreamClass desc)
+ throws IOException, ClassNotFoundException {
+ return Class.forName(desc.getName(), true,
+ Thread.currentThread().getContextClassLoader());
+ }
+ };
return ois.readObject();
} catch (Exception e) {
throw new FacesException(e);
16 years, 5 months
JBoss Rich Faces SVN: r9985 - in trunk/sandbox/ui/extendedDataTable/src: main/java and 8 other directories.
by richfaces-svn-commits@lists.jboss.org
Author: piotr.buda
Date: 2008-08-08 06:19:53 -0400 (Fri, 08 Aug 2008)
New Revision: 9985
Added:
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-draggable.js
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-dropzone.js
trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/renderer/
trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/renderer/ExtendedDataTableRendererTest.java
Removed:
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-draggable.js
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-dropzone.js
trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/JSFComponentTest.java
Modified:
trunk/sandbox/ui/extendedDataTable/src/main/config/component/ExtendedDataTable.xml
trunk/sandbox/ui/extendedDataTable/src/main/java/
trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/component/UIExtendedDataTable.java
trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java
trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/html/TableDragDropRenderer.java
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss
trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js
trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx
Log:
Bugfix, changes to styles/javascript
Modified: trunk/sandbox/ui/extendedDataTable/src/main/config/component/ExtendedDataTable.xml
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/config/component/ExtendedDataTable.xml 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/config/component/ExtendedDataTable.xml 2008-08-08 10:19:53 UTC (rev 9985)
@@ -2,44 +2,44 @@
<!DOCTYPE components PUBLIC "-//AJAX4JSF//CDK Generator config/EN" "http://labs.jboss.com/jbossrichfaces/component-config.dtd">
<components>
<component>
- <name>org.richfaces.ExtendedDataTable</name>
- <family>org.richfaces.ExtendedDataTable</family>
- <classname>org.richfaces.component.html.HtmlExtendedDataTable</classname>
- <superclass>org.richfaces.component.UIExtendedDataTable</superclass>
- <description>
- <![CDATA[
+ <name>org.richfaces.ExtendedDataTable</name>
+ <family>org.richfaces.ExtendedDataTable</family>
+ <classname>org.richfaces.component.html.HtmlExtendedDataTable</classname>
+ <superclass>org.richfaces.component.UIExtendedDataTable</superclass>
+ <description>
+ <![CDATA[
]]>
- </description>
- <renderer generate="true" override="true">
- <name>org.richfaces.ExtendedDataTableRenderer</name>
- <template>org/richfaces/htmlExtendedDataTable.jspx</template>
- </renderer>
- <tag>
- <name>extendedDataTable</name>
- <classname>org.richfaces.taglib.ExtendedDataTableTag</classname>
- <superclass>
- org.ajax4jsf.webapp.taglib.HtmlComponentTagBase
- </superclass>
- </tag>
- <!--
- <taghandler>
- <classname>org.ajax4jsf.tag.TestHandler</classname>
- </taghandler>
- -->
- &ui_component_attributes;
- &ui_data_attributes;
- &html_universal_attributes;
- &html_table_attributes;
- &html_events;
- &spec_table_attributes;
- <property>
- <name>onselectionchange</name>
- <classname>java.lang.String</classname>
- <description>
- HTML: script expression to invoke on changing of rows selection
- </description>
- </property>
- <property>
+ </description>
+ <renderer generate="true" override="true">
+ <name>org.richfaces.ExtendedDataTableRenderer</name>
+ <template>org/richfaces/htmlExtendedDataTable.jspx</template>
+ </renderer>
+ <tag>
+ <name>extendedDataTable</name>
+ <classname>org.richfaces.taglib.ExtendedDataTableTag</classname>
+ <superclass>
+ org.ajax4jsf.webapp.taglib.HtmlComponentTagBase
+ </superclass>
+ </tag>
+ <!--
+ <taghandler>
+ <classname>org.ajax4jsf.tag.TestHandler</classname>
+ </taghandler>
+ -->
+ &ui_component_attributes;
+ &ui_data_attributes;
+ &html_universal_attributes;
+ &html_table_attributes;
+ &html_events;
+ &spec_table_attributes;
+ <property>
+ <name>onselectionchange</name>
+ <classname>java.lang.String</classname>
+ <description>
+ HTML: script expression to invoke on changing of rows selection
+ </description>
+ </property>
+ <property>
<name>selectionMode</name>
<classname>java.lang.String</classname>
<description>
@@ -48,191 +48,191 @@
none: no rows can be selected.
</description>
<defaultvalue>
- "single"
+ "single"
</defaultvalue>
</property>
- <property>
- <name>height</name>
- <classname>java.lang.String</classname>
- <description>Defines a height of the component. Default value is 500px</description>
- <defaultvalue>"500px"</defaultvalue>
- </property>
- <property>
- <name>selectedClass</name>
- <classname>java.lang.String</classname>
- <description>
- CSS class for selected rows
- </description>
- </property>
- <property>
- <name>activeClass</name>
- <classname>java.lang.String</classname>
- <description>
- CSS class for active row
- </description>
- </property>
-
- <property>
- <name>ajaxKeys</name>
- <classname>java.util.Set</classname>
- <description>This attribute defines row keys that are updated after an AJAX request</description>
- </property>
- <property>
- <name>border</name>
- <classname>java.lang.String</classname>
- <description>This attributes specifies the width of the frame around a component</description>
- <defaultvalue>"0"</defaultvalue>
- </property>
- <property>
- <name>cellpadding</name>
- <classname>java.lang.String</classname>
- <description>This attribute specifies the amount of space between the border of the cell and its contents</description>
- <defaultvalue>"0"</defaultvalue>
- </property>
- <property>
- <name>cellspacing</name>
- <classname>java.lang.String</classname>
- <description>This attribute specifies the amount of space between the border of the cell and its contents. The attribute also specifies the amount of space to leave between cells
- </description>
- <defaultvalue>"0"</defaultvalue>
- </property>
- <property>
- <name>captionClass</name>
- <classname>java.lang.String</classname>
- <description>Space-separated list of CSS style class(es) that are be applied to caption for this component</description>
- <defaultvalue>""</defaultvalue>
- </property>
- <property>
- <name>captionStyle</name>
- <classname>java.lang.String</classname>
- <description>CSS style(s) is/are to be applied to caption when this component is rendered</description>
- </property>
- <property>
- <name>headerClass</name>
- <classname>java.lang.String</classname>
- <description>Space-separated list of CSS style class(es) that are be applied to header for this component
- </description>
- <defaultvalue>""</defaultvalue>
- </property>
- <property>
- <name>footerClass</name>
- <classname>java.lang.String</classname>
- <description>Space-separated list of CSS style class(es) that are be applied to footer for this component
- </description>
- <defaultvalue>""</defaultvalue>
- </property>
-
- <property>
- <name>componentState</name>
- <classname>org.ajax4jsf.model.DataComponentState</classname>
- <description>It defines EL-binding for a component state for saving or redefinition</description>
- </property>
- <property hidden="true" existintag="false" exist="false" >
- <name>rowKey</name>
- <classname>java.lang.Object</classname>
- <description>
- RowKey is a representation of an identifier for a specific data row
- </description>
- </property>
- <property>
- <name>rowKeyVar</name>
- <classname>java.lang.String</classname>
- <description>The attribute provides access to a row key in a Request scope</description>
- </property>
- <property>
- <name>stateVar</name>
- <classname>java.lang.String</classname>
- <description>
- The attribute provides access to a component state on the client side
- </description>
- </property>
- <property>
- <name>value</name>
- <classname>java.lang.Object</classname>
- <description>
- The current value for this component
- </description>
- </property>
- <!-- rows javascript events -->
- <property>
- <name>onRowClick</name>
- <classname>java.lang.String</classname>
- <description>
- HTML: a script expression; a pointer button is clicked on row
- </description>
- </property>
- <property>
- <name>onRowDblClick</name>
- <classname>java.lang.String</classname>
- <description>HTML: a script expression; a pointer button is double-clicked on row
- </description>
- </property>
- <property>
- <name>onRowMouseUp</name>
- <classname>java.lang.String</classname>
- <description>HTML: script expression; a pointer button is released on row
- </description>
- </property>
- <property>
- <name>onRowMouseDown</name>
- <classname>java.lang.String</classname>
- <description>HTML: script expression; a pointer button is pressed down on row
- </description>
- </property>
- <property>
- <name>onRowMouseOver</name>
- <classname>java.lang.String</classname>
- <description>HTML: a script expression; a pointer is moved onto of row
- </description>
- </property>
- <property>
- <name>onRowMouseOut</name>
- <classname>java.lang.String</classname>
- <description>HTML: a script expression; a pointer is moved away of row
- </description>
- </property>
- <property>
- <name>onRowMouseMove</name>
- <classname>java.lang.String</classname>
- <description>HTML: a script expression; a pointer is moved within of row
- </description>
- </property>
- <property>
- <name>sortPriority</name>
- <classname>java.util.Collection</classname>
- <description>Defines a set of column ids in the order the columns could be set</description>
- </property>
- <property hidden="true" existintag="false" exist="false" >
- <name>sortFields</name>
- </property>
- <property hidden="true" existintag="false" exist="false" >
- <name>filterFields</name>
- </property>
- <property>
- <name>sortMode</name>
- <classname>java.lang.String</classname>
- <description>
- Defines mode of sorting. Possible values are 'single' for sorting of one column and 'multi' for some.
- </description>
- </property>
- <property hidden="true" existintag="false" exist="false" >
- <name>summary</name>
- <classname>java.lang.Object</classname>
- </property>
-
- <property elonly="true">
- <name>tableState</name>
- <classname>java.lang.String</classname>
- <description>
- ValueBinding pointing at a property of a String to hold table state
- </description>
- </property>
-
- <property attachedstate="true" elonly="true">
- <name>selection</name>
- <classname>org.richfaces.model.selection.Selection</classname>
- <description>Value binding representing selected rows</description>
- </property>
-
- </component>
+ <property>
+ <name>height</name>
+ <classname>java.lang.String</classname>
+ <description>Defines a height of the component. Default value is 500px</description>
+ <defaultvalue>"500px"</defaultvalue>
+ </property>
+ <property>
+ <name>selectedClass</name>
+ <classname>java.lang.String</classname>
+ <description>
+ CSS class for selected rows
+ </description>
+ </property>
+ <property>
+ <name>activeClass</name>
+ <classname>java.lang.String</classname>
+ <description>
+ CSS class for active row
+ </description>
+ </property>
+
+ <property>
+ <name>ajaxKeys</name>
+ <classname>java.util.Set</classname>
+ <description>This attribute defines row keys that are updated after an AJAX request</description>
+ </property>
+ <property>
+ <name>border</name>
+ <classname>java.lang.String</classname>
+ <description>This attributes specifies the width of the frame around a component</description>
+ <defaultvalue>"0"</defaultvalue>
+ </property>
+ <property>
+ <name>cellpadding</name>
+ <classname>java.lang.String</classname>
+ <description>This attribute specifies the amount of space between the border of the cell and its contents</description>
+ <defaultvalue>"0"</defaultvalue>
+ </property>
+ <property>
+ <name>cellspacing</name>
+ <classname>java.lang.String</classname>
+ <description>This attribute specifies the amount of space between the border of the cell and its contents. The attribute also specifies the amount of space to leave between cells
+ </description>
+ <defaultvalue>"0"</defaultvalue>
+ </property>
+ <property>
+ <name>captionClass</name>
+ <classname>java.lang.String</classname>
+ <description>Space-separated list of CSS style class(es) that are be applied to caption for this component</description>
+ <defaultvalue>""</defaultvalue>
+ </property>
+ <property>
+ <name>captionStyle</name>
+ <classname>java.lang.String</classname>
+ <description>CSS style(s) is/are to be applied to caption when this component is rendered</description>
+ </property>
+ <property>
+ <name>headerClass</name>
+ <classname>java.lang.String</classname>
+ <description>Space-separated list of CSS style class(es) that are be applied to header for this component
+ </description>
+ <defaultvalue>""</defaultvalue>
+ </property>
+ <property>
+ <name>footerClass</name>
+ <classname>java.lang.String</classname>
+ <description>Space-separated list of CSS style class(es) that are be applied to footer for this component
+ </description>
+ <defaultvalue>""</defaultvalue>
+ </property>
+
+ <property>
+ <name>componentState</name>
+ <classname>org.ajax4jsf.model.DataComponentState</classname>
+ <description>It defines EL-binding for a component state for saving or redefinition</description>
+ </property>
+ <property hidden="true" existintag="false" exist="false" >
+ <name>rowKey</name>
+ <classname>java.lang.Object</classname>
+ <description>
+ RowKey is a representation of an identifier for a specific data row
+ </description>
+ </property>
+ <property>
+ <name>rowKeyVar</name>
+ <classname>java.lang.String</classname>
+ <description>The attribute provides access to a row key in a Request scope</description>
+ </property>
+ <property>
+ <name>stateVar</name>
+ <classname>java.lang.String</classname>
+ <description>
+ The attribute provides access to a component state on the client side
+ </description>
+ </property>
+ <property>
+ <name>value</name>
+ <classname>java.lang.Object</classname>
+ <description>
+ The current value for this component
+ </description>
+ </property>
+ <!-- rows javascript events -->
+ <property>
+ <name>onRowClick</name>
+ <classname>java.lang.String</classname>
+ <description>
+ HTML: a script expression; a pointer button is clicked on row
+ </description>
+ </property>
+ <property>
+ <name>onRowDblClick</name>
+ <classname>java.lang.String</classname>
+ <description>HTML: a script expression; a pointer button is double-clicked on row
+ </description>
+ </property>
+ <property>
+ <name>onRowMouseUp</name>
+ <classname>java.lang.String</classname>
+ <description>HTML: script expression; a pointer button is released on row
+ </description>
+ </property>
+ <property>
+ <name>onRowMouseDown</name>
+ <classname>java.lang.String</classname>
+ <description>HTML: script expression; a pointer button is pressed down on row
+ </description>
+ </property>
+ <property>
+ <name>onRowMouseOver</name>
+ <classname>java.lang.String</classname>
+ <description>HTML: a script expression; a pointer is moved onto of row
+ </description>
+ </property>
+ <property>
+ <name>onRowMouseOut</name>
+ <classname>java.lang.String</classname>
+ <description>HTML: a script expression; a pointer is moved away of row
+ </description>
+ </property>
+ <property>
+ <name>onRowMouseMove</name>
+ <classname>java.lang.String</classname>
+ <description>HTML: a script expression; a pointer is moved within of row
+ </description>
+ </property>
+ <property>
+ <name>sortPriority</name>
+ <classname>java.util.Collection</classname>
+ <description>Defines a set of column ids in the order the columns could be set</description>
+ </property>
+ <property hidden="true" existintag="false" exist="false" >
+ <name>sortFields</name>
+ </property>
+ <property hidden="true" existintag="false" exist="false" >
+ <name>filterFields</name>
+ </property>
+ <property>
+ <name>sortMode</name>
+ <classname>java.lang.String</classname>
+ <description>
+ Defines mode of sorting. Possible values are 'single' for sorting of one column and 'multi' for some.
+ </description>
+ </property>
+ <property hidden="true" existintag="false" exist="false" >
+ <name>summary</name>
+ <classname>java.lang.Object</classname>
+ </property>
+
+ <property elonly="true">
+ <name>tableState</name>
+ <classname>java.lang.String</classname>
+ <description>
+ ValueBinding pointing at a property of a String to hold table state
+ </description>
+ </property>
+
+ <property attachedstate="true" elonly="true">
+ <name>selection</name>
+ <classname>org.richfaces.model.selection.Selection</classname>
+ <description>Value binding representing selected rows</description>
+ </property>
+
+ </component>
</components>
Property changes on: trunk/sandbox/ui/extendedDataTable/src/main/java
___________________________________________________________________
Name: svn:ignore
+ META-INF
Modified: trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/component/UIExtendedDataTable.java
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/component/UIExtendedDataTable.java 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/component/UIExtendedDataTable.java 2008-08-08 10:19:53 UTC (rev 9985)
@@ -225,8 +225,6 @@
// try to add group column id as first
//TODO nick - is it ok to change user's priorities collection here?
- //PBU it is used in grouping mode - grouping column must be sorted
- //as first
if (priority.contains(groupColId)) {
priority.remove(groupColId);
}
Modified: trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/AbstractExtendedTableRenderer.java 2008-08-08 10:19:53 UTC (rev 9985)
@@ -211,6 +211,7 @@
UIExtendedDataTable table, Iterator<UIColumn> headers,
String skinCellClass, String headerClass, String facetName,
String element) throws IOException {
+
if (filteringEnabled(table)) {
writer.startElement(HTML.TR_ELEMENT, table);
writer.writeAttribute(HTML.id_ATTRIBUTE, table
@@ -232,8 +233,7 @@
/**
* Checks if column has filtering enabled
*
- * @param dataColumn
- * column to inspect
+ * @param dataColumn column to inspect
* @return true if filtering is enabled, false otherwise
* @author pbuda
*/
@@ -246,8 +246,7 @@
/**
* Checks whether filtering is enabled in this table
*
- * @param table
- * table to inspect
+ * @param table table to inspect
* @return true if filtering is enabled, false otherwise
* @author pbuda
*/
Modified: trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/html/TableDragDropRenderer.java
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/html/TableDragDropRenderer.java 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/java/org/richfaces/renderkit/html/TableDragDropRenderer.java 2008-08-08 10:19:53 UTC (rev 9985)
@@ -95,7 +95,7 @@
responseWriter.write("elt.markers['" + DEFAULT + "'] = \"");
responseWriter.write(getPredefinedMarker(context, REJECT));
responseWriter.write("\";\n");
- responseWriter.write("createDragIndicator(elt, '', '');\n");
+ responseWriter.write("createExtDragIndicator(elt, '', '');\n");
}
}.encodeChildScripts(context, component);
Modified: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/css/extendedDataTable.xcss 2008-08-08 10:19:53 UTC (rev 9985)
@@ -5,15 +5,6 @@
<f:verbatim>
-
- ul,ol,li{
- margin: 0;
- padding: 0;
- }
- ol,ul{
- list-style: none;
- }
-
.extdt-empty-cell{
}
/**
Modified: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js 2008-08-08 10:19:53 UTC (rev 9985)
@@ -1,209 +1,196 @@
-DragIndicator = {
+ExtDragIndicator = {
init: function(event) {
- var ieVersion = RichFaces.getIEVersion();
- DragIndicator.isIE6 = (ieVersion && ieVersion < 7);
+ var ieVersion = RichFaces.getIEVersion();
+ ExtDragIndicator.isIE6 = (ieVersion && ieVersion < 7);
},
setContent: function(name, single, params) {
- Element.clearChildren(this);
+ Element.clearChildren(this);
- var p = DnD.getDnDDefaultParams(this);
-
- if (!p) {
- p = {};
- }
+ var p = DnD.getDnDDefaultParams(this);
+
+ if (!p) {
+ p = {};
+ }
- if (params) {
- Object.extend(p, params);
- }
-
- if (!p['marker']) {
- if (p[name]) {
- p['marker'] = p[name];
- } else {
- p['marker'] = this.markers[name];
- }
- }
+ if (params) {
+ Object.extend(p, params);
+ }
+
+ if (!p['marker']) {
+ if (p[name]) {
+ p['marker'] = p[name];
+ } else {
+ p['marker'] = this.markers[name];
+ }
+ }
- var parts;
+ var parts;
- if (single) {
- parts = this.indicatorTemplates['single'];
- } else {
- parts = this.indicatorTemplates['multi'];
- }
-
- new Insertion.Top(this, parts.invoke('getContent', p).join(''));
-
- if (DragIndicator.isIE6) {
- this.initIFrame();
- }
- },
+ if (single) {
+ parts = this.indicatorTemplates['single'];
+ } else {
+ parts = this.indicatorTemplates['multi'];
+ }
+
+ new Insertion.Top(this, parts.invoke('getContent', p).join(''));
+
+ if (ExtDragIndicator.isIE6) {
+ this.initIFrame();
+ }
+ },
- show: function() {
- if (!this.floatedToBody) {
- if (!this.realParent) {
- this.realParent = this.parentNode;
- this._nextSibling = this.nextSibling;
- }
- this.realParent.removeChild(this);
- document.body.appendChild(this);
- this.floatedToBody = true;
- }
- Element.show(this);
- this.style.position = 'absolute';
- },
+ show: function() {
+ if (!this.floatedToBody) {
+ if (!this.realParent) {
+ this.realParent = this.parentNode;
+ this._nextSibling = this.nextSibling;
+ }
+ this.realParent.removeChild(this);
+ document.body.appendChild(this);
+ this.floatedToBody = true;
+ }
+ Element.show(this);
+ this.style.position = 'absolute';
+ },
- hide: function() {
- Element.hide(this);
- this.style.position = '';
- this.offsets = undefined;
- this.leave();
- if (this.floatedToBody && this.realParent) {
- document.body.removeChild(this);
- if (this._nextSibling) {
- this.realParent.insertBefore(this, this._nextSibling);
- } else {
- this.realParent.appendChild(this);
- }
- this.floatedToBody = false;
- }
- },
+ hide: function() {
+ Element.hide(this);
+ this.style.position = '';
+ this.offsets = undefined;
+ this.leave();
+ if (this.floatedToBody && this.realParent) {
+ document.body.removeChild(this);
+ if (this._nextSibling) {
+ this.realParent.insertBefore(this, this._nextSibling);
+ } else {
+ this.realParent.appendChild(this);
+ }
+ this.floatedToBody = false;
+ }
+ },
- position: function(x, y) {
- if (!this.offsets) {
- Element.show(this);
- this.style.position = 'absolute';
- }
- Element.setStyle(this, {"left": x + "px", "top": y + "px"});
- },
+ position: function(x, y) {
+ if (!this.offsets) {
+ Element.show(this);
+ this.style.position = 'absolute';
+ }
+ Element.setStyle(this, {"left": x + "px", "top": y + "px"});
+ },
- accept: function() {
- Element.removeClassName(this, 'drgind_default');
- Element.removeClassName(this, 'drgind_reject');
- Element.addClassName(this, 'drgind_accept');
+ accept: function() {
+ Element.removeClassName(this, 'drgind_default');
+ Element.removeClassName(this, 'drgind_reject');
+ Element.addClassName(this, 'drgind_accept');
- var acceptClass = this.getAcceptClass();
- if (acceptClass) {
- Element.addClassName(this, acceptClass);
- }
- },
+ var acceptClass = this.getAcceptClass();
+ if (acceptClass) {
+ Element.addClassName(this, acceptClass);
+ }
+ },
- reject: function() {
- Element.removeClassName(this, 'drgind_default');
- Element.removeClassName(this, 'drgind_accept');
- Element.addClassName(this, 'drgind_reject');
+ reject: function() {
+ Element.removeClassName(this, 'drgind_default');
+ Element.removeClassName(this, 'drgind_accept');
+ Element.addClassName(this, 'drgind_reject');
- var rejectClass = this.getRejectClass();
- if (rejectClass) {
- Element.addClassName(this, rejectClass);
- }
- },
+ var rejectClass = this.getRejectClass();
+ if (rejectClass) {
+ Element.addClassName(this, rejectClass);
+ }
+ },
- leave: function() {
- Element.removeClassName(this, 'drgind_accept');
- //Element.removeClassName(this, 'drgind_reject');
- //Element.addClassName(this, 'drgind_default');
- Element.removeClassName(this, 'drgind_default');
- Element.addClassName(this, 'drgind_reject');
+ leave: function() {
+ Element.removeClassName(this, 'drgind_accept');
+ //Element.removeClassName(this, 'drgind_reject');
+ //Element.addClassName(this, 'drgind_default');
+ Element.removeClassName(this, 'drgind_default');
+ Element.addClassName(this, 'drgind_reject');
- var acceptClass = this.getAcceptClass();
- var rejectClass = this.getRejectClass();
- if (acceptClass) {
- Element.removeClassName(this, acceptClass);
- }
- if (rejectClass) {
- Element.removeClassName(this, rejectClass);
- }
- },
+ var acceptClass = this.getAcceptClass();
+ var rejectClass = this.getRejectClass();
+ if (acceptClass) {
+ Element.removeClassName(this, acceptClass);
+ }
+ if (rejectClass) {
+ Element.removeClassName(this, rejectClass);
+ }
+ },
- getAcceptClass: function() {
- return this.ils_acceptClass;
- },
+ getAcceptClass: function() {
+ return this.ils_acceptClass;
+ },
- getRejectClass: function() {
- return this.ils_rejectClass;
- },
-
- initIFrame: function() {
- var iframe = document.createElement("iframe");
- Element.addClassName(iframe, 'rich-dragindicator-iframe');
- this.insertBefore(iframe, this.firstChild);
- var table = iframe.nextSibling;
- iframe.style.width = table.offsetWidth + "px";
- iframe.style.height = table.offsetHeight + "px";
- }
+ getRejectClass: function() {
+ return this.ils_rejectClass;
+ },
+
+ initIFrame: function() {
+ var iframe = document.createElement("iframe");
+ Element.addClassName(iframe, 'rich-dragindicator-iframe');
+ this.insertBefore(iframe, this.firstChild);
+ var table = iframe.nextSibling;
+ iframe.style.width = table.offsetWidth + "px";
+ iframe.style.height = table.offsetHeight + "px";
+ }
};
-function createDragIndicator(elt, acceptClass, rejectClass) {
- Object.extend(elt, DragIndicator);
+function createExtDragIndicator(elt, acceptClass, rejectClass) {
+ Object.extend(elt, ExtDragIndicator);
elt.init();
-
- elt.ils_acceptClass = acceptClass;
- elt.ils_rejectClass = rejectClass;
+
+ elt.ils_acceptClass = acceptClass;
+ elt.ils_rejectClass = rejectClass;
}
-// <table border="0" cellpadding="3" cellspacing="0" class="drgind_internal" style="height : 100%">
-// <tr>
-// <td class="drgind_marker">
-// {marker}
-// </td>
-// <td class="drgind_text">
-// <div class="drgind_wordcut drgind_text_content">
-// {label}
-// </div>
-// </td>
-// </tr>
-// </table>
-// <div class="drgind_shadow" />
-DefaultDragIndicatorView =
+DefaultExtDragIndicatorView =
[
- new E('table',
- {
- 'style':'height : 100%; z-index: 2;',
- 'className':'drgind_internal',
- 'cellspacing':'0',
- 'cellpadding':'3',
- 'border':'0'
- },
- [
- new E('tbody',{},
- [
- new E('tr',{},
- [
- new E('td',
- {
- 'className':'drgind_marker'
- },
- [
- new ET(function (context) { return Richfaces.eval("marker", context)})
- ]
- ),
- new E('td',
- {
- 'className':'drgind_text'
- },
- [
- new E('div',
- {
- 'className':'drgind_wordcut drgind_text_content'
- },
- [
- new ET(function (context) { return Richfaces.eval("label", context)})
- ]
- )
- ]
- )
- ]
- )
- ]
- )
- ]
- ),
- new E('div',
- {
- 'className':'drgind_shadow'
- }
- )
+ new E('table',
+ {
+ 'style':'height : 100%; z-index: 2;',
+ 'className':'drgind_internal',
+ 'cellspacing':'0',
+ 'cellpadding':'3',
+ 'border':'0'
+ },
+ [
+ new E('tbody',{},
+ [
+ new E('tr',{},
+ [
+ new E('td',
+ {
+ 'className':'drgind_marker'
+ },
+ [
+ new ET(function (context) { return Richfaces.eval("marker", context)})
+ ]
+ ),
+ new E('td',
+ {
+ 'className':'drgind_text'
+ },
+ [
+ new E('div',
+ {
+ 'className':'drgind_wordcut drgind_text_content'
+ },
+ [
+ new ET(function (context) { return Richfaces.eval("label", context)})
+ ]
+ )
+ ]
+ )
+ ]
+ )
+ ]
+ )
+ ]
+ ),
+ new E('div',
+ {
+ 'className':'drgind_shadow'
+ }
+ )
];
Copied: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-draggable.js (from rev 9873, trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-draggable.js)
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-draggable.js (rev 0)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-draggable.js 2008-08-08 10:19:53 UTC (rev 9985)
@@ -0,0 +1,121 @@
+DnD.ExtSimpleDraggable = Class.create();
+
+Object.extend(DnD.ExtSimpleDraggable.prototype, DnD.Draggable.prototype);
+Object.extend(DnD.ExtSimpleDraggable.prototype, {
+ initialize: function(id, options) {
+ this.id = $(id);
+
+ if (!this.id) {
+ alert("drag: Element with [" + id + "] ID was not found in the DOM tree. Probably element has no client ID or client ID hasn't been written. DnD's disabled. Check please!");
+ return ;
+ }
+
+ this.options = options;
+
+ this.dragIndicatorId = this.options.dragIndicator;
+
+ this.eventMouseDown = this.initDrag.bindAsEventListener(this);
+
+ Event.observe(this.id, "mousedown", this.eventMouseDown);
+
+ this.form = this.id;
+ while (this.form && !/^form$/i.test(this.form.tagName)) {
+ this.form = this.form.parentNode;
+ }
+
+ this.enableDraggableCursors(this.options.grab, this.options.grabbing);
+ },
+
+ getDnDDragParams: function() {
+ if (this.options.dndParams) {
+ return this.options.dndParams.parseJSON(EventHandlersWalk);
+ }
+
+ return null;
+ },
+
+ getIndicator: function() {
+ var dragIndicator = $(this.dragIndicatorId);
+ if (!dragIndicator) {
+ dragIndicator = this.getOrCreateDefaultIndicator();
+ }
+
+ return dragIndicator;
+ },
+
+ ondragstart : function(event, drag) {
+ this.showDropTargets();
+ drag.params = this.options.parameters;
+ drag.params[this.id] = this.id;
+
+ this.setIndicator(event);
+
+ this.getIndicator().leave();
+
+ //this.dragEnter(event);
+
+ if (this.form) {
+ drag.params[this.form.id] = this.form.id;
+ }
+ },
+
+ ondragend: function (event, drag) {
+ this.hideDropTargets();
+ },
+
+ getContentType: function() {
+ return this.options.dragType;
+ },
+
+ getDraggableOptions: function() {
+ return this.options;
+ },
+
+ initDrag: function(event) {
+ if (Event.isLeftClick(event)) {
+ var src = Event.element(event);
+ if(src.tagName && /^INPUT|SELECT|OPTION|BUTTON|TEXTAREA$/i.test(src.tagName))
+ return;
+
+ Event.stop(event);
+
+ this.startDrag(event);
+ //Event.observe(document, "mousemove", this.listenDragBound);
+ //Event.observe(document, "mouseup", this.stopListenDragBound);
+ }
+ },
+
+ showDropTargets: function(){
+ var idStr = this.id.id;
+ var ind = idStr.lastIndexOf('_');
+ var prefix = idStr.substring(0,ind).replace("hdrag", "hdrop");
+ var spans = document.getElementsByTagName("span");
+ for(i=0;i<spans.length;i++){
+ var s = spans[i];
+ if (s.id.indexOf(prefix) == 0){
+ //s.style.zIndex = '70';
+ s.style.visibility = "visible";
+ //change dropzone style
+ s.childNodes[0].style.visibility="hidden";//top element
+ s.childNodes[1].style.visibility="hidden";//bottom element
+ }
+ }//for
+ },
+
+ hideDropTargets: function(){
+ var idStr = this.id.id;
+ var ind = idStr.lastIndexOf('_');
+ var prefix = idStr.substring(0,ind).replace("hdrag", "hdrop");
+ var spans = document.getElementsByTagName("span");
+ for (i=0;i<spans.length;i++){
+ var s = spans[i];
+ if (s.id.indexOf(prefix) == 0){
+ //s.style.zIndex = '59';
+ s.style.visibility = "hidden";
+ //change dropzone style
+ s.childNodes[0].style.visibility="hidden";//top element
+ s.childNodes[1].style.visibility="hidden";//bottom element
+ }
+ }//for
+ }
+});
\ No newline at end of file
Property changes on: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-draggable.js
___________________________________________________________________
Name: svn:mergeinfo
+
Copied: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-dropzone.js (from rev 9873, trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-dropzone.js)
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-dropzone.js (rev 0)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-dropzone.js 2008-08-08 10:19:53 UTC (rev 9985)
@@ -0,0 +1,99 @@
+DnD.ExtSimpleDropZone = Class.create();
+Object.extend(DnD.ExtSimpleDropZone.prototype, DnD.Dropzone.prototype);
+Object.extend(DnD.ExtSimpleDropZone.prototype, {
+ initialize: function(id, options) {
+ this.id = id;
+ var element = $(id);
+
+ if (!element) {
+ alert("drop: Element with [" + id + "] ID was not found in the DOM tree. Probably element has no client ID or client ID hasn't been written. DnD's disabled. Check please!");
+ return ;
+ }
+
+ this.element = element;
+ if (options.acceptedTypes) {
+ this.acceptedTypes = options.acceptedTypes;
+ } else {
+ this.acceptedTypes = [];
+ }
+
+ if (options.typeMapping) {
+ this.typeMapping = options.typeMapping;
+ } else {
+ this.typeMapping = {};
+ }
+
+ if (options.cursorTypeMapping) {
+ this.cursorTypeMapping = options.cursorTypeMapping;
+ } else {
+ this.cursorTypeMapping = {};
+ }
+
+ this.mouseoverBound = this.mouseover.bindAsEventListener(this);
+ this.mouseoutBound = this.mouseout.bindAsEventListener(this);
+ this.mouseupBound = this.mouseup.bindAsEventListener(this);
+
+ Event.observe(element, "mouseover", this.mouseoverBound);
+ Event.observe(element, "mouseout", this.mouseoutBound);
+ Event.observe(element, "mouseup", this.mouseupBound);
+
+
+
+ this.options = options || {};
+ this.enableDropzoneCursors(options.acceptCursor,options.rejectCursor);
+
+ },
+
+ getDropzoneOptions: function() {
+ return this.options;
+ },
+
+ getDnDDropParams: function() {
+ if (this.options.dndParams) {
+ return this.options.dndParams.parseJSON(EventHandlersWalk);
+ }
+
+ return null;
+ },
+
+ mouseover: function(event) {
+ if (window.drag){
+ this.dragEnter(event);
+ //change dropzone style
+ this.element.childNodes[0].style.visibility="visible";//top element
+ this.element.childNodes[1].style.visibility="visible";//bottom element
+ }
+ },
+
+ mouseup: function(event) {
+ this.dragUp(event);
+ },
+
+ mouseout: function(event) {
+ if (window.drag){
+ this.dragLeave(event);
+ //change dropzone style
+ this.element.childNodes[0].style.visibility="hidden";//top element
+ this.element.childNodes[1].style.visibility="hidden";//bottom element
+ }
+ },
+ getAcceptedTypes: function() {
+ return this.acceptedTypes;
+ },
+ getTypeMapping: function() {
+ return this.typeMapping;
+ },
+
+ getCursorTypeMapping: function() {
+ return this.cursorTypeMapping;
+ },
+
+ drop: function(event, drag){
+ alert('I drop');
+ },
+ onafterdrag: function(drag) {
+ if (this.options.onafterdrag) {
+ this.options.onafterdrag.call(this, drag);
+ }
+ }
+});
\ No newline at end of file
Property changes on: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-dt-simple-dropzone.js
___________________________________________________________________
Name: svn:mergeinfo
+
Deleted: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-draggable.js
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-draggable.js 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-draggable.js 2008-08-08 10:19:53 UTC (rev 9985)
@@ -1,121 +0,0 @@
-DnD.ExtSimpleDraggable = Class.create();
-
-Object.extend(DnD.ExtSimpleDraggable.prototype, DnD.Draggable.prototype);
-Object.extend(DnD.ExtSimpleDraggable.prototype, {
- initialize: function(id, options) {
- this.id = $(id);
-
- if (!this.id) {
- alert("drag: Element with [" + id + "] ID was not found in the DOM tree. Probably element has no client ID or client ID hasn't been written. DnD's disabled. Check please!");
- return ;
- }
-
- this.options = options;
-
- this.dragIndicatorId = this.options.dragIndicator;
-
- this.eventMouseDown = this.initDrag.bindAsEventListener(this);
-
- Event.observe(this.id, "mousedown", this.eventMouseDown);
-
- this.form = this.id;
- while (this.form && !/^form$/i.test(this.form.tagName)) {
- this.form = this.form.parentNode;
- }
-
- this.enableDraggableCursors(this.options.grab, this.options.grabbing);
- },
-
- getDnDDragParams: function() {
- if (this.options.dndParams) {
- return this.options.dndParams.parseJSON(EventHandlersWalk);
- }
-
- return null;
- },
-
- getIndicator: function() {
- var dragIndicator = $(this.dragIndicatorId);
- if (!dragIndicator) {
- dragIndicator = this.getOrCreateDefaultIndicator();
- }
-
- return dragIndicator;
- },
-
- ondragstart : function(event, drag) {
- this.showDropTargets();
- drag.params = this.options.parameters;
- drag.params[this.id] = this.id;
-
- this.setIndicator(event);
-
- this.getIndicator().leave();
-
- //this.dragEnter(event);
-
- if (this.form) {
- drag.params[this.form.id] = this.form.id;
- }
- },
-
- ondragend: function (event, drag) {
- this.hideDropTargets();
- },
-
- getContentType: function() {
- return this.options.dragType;
- },
-
- getDraggableOptions: function() {
- return this.options;
- },
-
- initDrag: function(event) {
- if (Event.isLeftClick(event)) {
- var src = Event.element(event);
- if(src.tagName && /^INPUT|SELECT|OPTION|BUTTON|TEXTAREA$/i.test(src.tagName))
- return;
-
- Event.stop(event);
-
- this.startDrag(event);
- //Event.observe(document, "mousemove", this.listenDragBound);
- //Event.observe(document, "mouseup", this.stopListenDragBound);
- }
- },
-
- showDropTargets: function(){
- var idStr = this.id.id;
- var ind = idStr.lastIndexOf('_');
- var prefix = idStr.substring(0,ind).replace("hdrag", "hdrop");
- var spans = document.getElementsByTagName("span");
- for(i=0;i<spans.length;i++){
- var s = spans[i];
- if (s.id.indexOf(prefix) == 0){
- //s.style.zIndex = '70';
- s.style.visibility = "visible";
- //change dropzone style
- s.childNodes[0].style.visibility="hidden";//top element
- s.childNodes[1].style.visibility="hidden";//bottom element
- }
- }//for
- },
-
- hideDropTargets: function(){
- var idStr = this.id.id;
- var ind = idStr.lastIndexOf('_');
- var prefix = idStr.substring(0,ind).replace("hdrag", "hdrop");
- var spans = document.getElementsByTagName("span");
- for (i=0;i<spans.length;i++){
- var s = spans[i];
- if (s.id.indexOf(prefix) == 0){
- //s.style.zIndex = '59';
- s.style.visibility = "hidden";
- //change dropzone style
- s.childNodes[0].style.visibility="hidden";//top element
- s.childNodes[1].style.visibility="hidden";//bottom element
- }
- }//for
- }
-});
\ No newline at end of file
Deleted: trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-dropzone.js
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-dropzone.js 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/resources/org/richfaces/renderkit/html/scripts/ext-simple-dropzone.js 2008-08-08 10:19:53 UTC (rev 9985)
@@ -1,99 +0,0 @@
-DnD.ExtSimpleDropZone = Class.create();
-Object.extend(DnD.ExtSimpleDropZone.prototype, DnD.Dropzone.prototype);
-Object.extend(DnD.ExtSimpleDropZone.prototype, {
- initialize: function(id, options) {
- this.id = id;
- var element = $(id);
-
- if (!element) {
- alert("drop: Element with [" + id + "] ID was not found in the DOM tree. Probably element has no client ID or client ID hasn't been written. DnD's disabled. Check please!");
- return ;
- }
-
- this.element = element;
- if (options.acceptedTypes) {
- this.acceptedTypes = options.acceptedTypes;
- } else {
- this.acceptedTypes = [];
- }
-
- if (options.typeMapping) {
- this.typeMapping = options.typeMapping;
- } else {
- this.typeMapping = {};
- }
-
- if (options.cursorTypeMapping) {
- this.cursorTypeMapping = options.cursorTypeMapping;
- } else {
- this.cursorTypeMapping = {};
- }
-
- this.mouseoverBound = this.mouseover.bindAsEventListener(this);
- this.mouseoutBound = this.mouseout.bindAsEventListener(this);
- this.mouseupBound = this.mouseup.bindAsEventListener(this);
-
- Event.observe(element, "mouseover", this.mouseoverBound);
- Event.observe(element, "mouseout", this.mouseoutBound);
- Event.observe(element, "mouseup", this.mouseupBound);
-
-
-
- this.options = options || {};
- this.enableDropzoneCursors(options.acceptCursor,options.rejectCursor);
-
- },
-
- getDropzoneOptions: function() {
- return this.options;
- },
-
- getDnDDropParams: function() {
- if (this.options.dndParams) {
- return this.options.dndParams.parseJSON(EventHandlersWalk);
- }
-
- return null;
- },
-
- mouseover: function(event) {
- if (window.drag){
- this.dragEnter(event);
- //change dropzone style
- this.element.childNodes[0].style.visibility="visible";//top element
- this.element.childNodes[1].style.visibility="visible";//bottom element
- }
- },
-
- mouseup: function(event) {
- this.dragUp(event);
- },
-
- mouseout: function(event) {
- if (window.drag){
- this.dragLeave(event);
- //change dropzone style
- this.element.childNodes[0].style.visibility="hidden";//top element
- this.element.childNodes[1].style.visibility="hidden";//bottom element
- }
- },
- getAcceptedTypes: function() {
- return this.acceptedTypes;
- },
- getTypeMapping: function() {
- return this.typeMapping;
- },
-
- getCursorTypeMapping: function() {
- return this.cursorTypeMapping;
- },
-
- drop: function(event, drag){
- alert('I drop');
- },
- onafterdrag: function(drag) {
- if (this.options.onafterdrag) {
- this.options.onafterdrag.call(this, drag);
- }
- }
-});
\ No newline at end of file
Modified: trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/main/templates/org/richfaces/htmlExtendedDataTable.jspx 2008-08-08 10:19:53 UTC (rev 9985)
@@ -41,8 +41,8 @@
/org/richfaces/renderkit/html/scripts/extended-data-table.js,
/org/richfaces/renderkit/html/scripts/ext-dt-drag-indicator.js,
- /org/richfaces/renderkit/html/scripts/ext-simple-draggable.js,
- /org/richfaces/renderkit/html/scripts/ext-simple-dropzone.js
+ /org/richfaces/renderkit/html/scripts/ext-dt-simple-draggable.js,
+ /org/richfaces/renderkit/html/scripts/ext-dt-simple-dropzone.js
</h:scripts>
<f:clientid var="clientId"/>
Deleted: trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/JSFComponentTest.java
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/JSFComponentTest.java 2008-08-08 07:11:27 UTC (rev 9984)
+++ trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/JSFComponentTest.java 2008-08-08 10:19:53 UTC (rev 9985)
@@ -1,53 +0,0 @@
-/**
- * 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.component;
-
-import junit.framework.Test;
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
-import javax.faces.component.UIComponent;
-
-/**
- * Unit test for simple Component.
- */
-public class JSFComponentTest
- extends TestCase
-{
- /**
- * Create the test case
- *
- * @param testName name of the test case
- */
- public JSFComponentTest( String testName )
- {
- super( testName );
- }
-
-
- /**
- * Rigourous Test :-)
- */
- public void testComponent()
- {
- assertTrue( true );
- }
-}
Added: trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/renderer/ExtendedDataTableRendererTest.java
===================================================================
--- trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/renderer/ExtendedDataTableRendererTest.java (rev 0)
+++ trunk/sandbox/ui/extendedDataTable/src/test/java/org/richfaces/component/renderer/ExtendedDataTableRendererTest.java 2008-08-08 10:19:53 UTC (rev 9985)
@@ -0,0 +1,89 @@
+package org.richfaces.component.renderer;
+
+import java.util.HashSet;
+import java.util.List;
+import java.util.Set;
+
+import javax.el.MethodExpression;
+import javax.faces.component.UIOutput;
+import javax.faces.component.html.HtmlOutputText;
+
+import org.ajax4jsf.tests.AbstractAjax4JsfTestCase;
+import org.richfaces.component.UIColumn;
+import org.richfaces.component.UIExtendedDataTable;
+
+import com.gargoylesoftware.htmlunit.html.HtmlElement;
+import com.gargoylesoftware.htmlunit.html.HtmlPage;
+
+
+/**
+ *
+ * @author pbuda
+ *
+ */
+public class ExtendedDataTableRendererTest extends AbstractAjax4JsfTestCase {
+
+ private UIExtendedDataTable table;
+
+ private Set<String> javascripts = new HashSet<String>();
+
+
+ public ExtendedDataTableRendererTest(String name) {
+ super(name);
+ }
+
+ @Override
+ public void setUp() throws Exception {
+ super.setUp();
+
+ //Create data table
+ table = (UIExtendedDataTable) application.createComponent(UIExtendedDataTable.COMPONENT_TYPE);
+ table.setId("table");
+
+ UIColumn column = (UIColumn) createComponent(
+ UIColumn.COMPONENT_TYPE,
+ "org.richfaces.component.Column",
+ null, null, null
+ );
+
+ column.setFilterValue("field");
+
+ UIOutput output = (UIOutput) createComponent(
+ UIOutput.COMPONENT_TYPE,
+ HtmlOutputText.class.getName(),
+ null, null, null
+ );
+
+ column.getChildren().add(output);
+
+
+ table.getChildren().add(column);
+
+ facesContext.getViewRoot().getChildren().add(table);
+
+ //javascripts initialization
+ javascripts.add("org/richfaces/renderkit/html/scripts/extended-data-table.js");
+ }
+
+ @Override
+ public void tearDown() throws Exception {
+ table = null;
+ super.tearDown();
+ }
+
+ @SuppressWarnings("unchecked")
+ public void testLoadingStyles() throws Exception {
+ HtmlPage page = renderView();
+ assertNotNull(page);
+ List links = page.getDocumentHtmlElement().getHtmlElementsByTagName("link");
+ assertNotNull(links);
+ HtmlElement link = (HtmlElement) links.get(0);
+ assertTrue(link.getAttributeValue("href").contains("css/extendedDataTable.xcss"));
+ }
+
+ public void testLoadingScripts() throws Exception {
+ HtmlPage page = renderView();
+ assertNotNull(page);
+ assertTrue(getCountValidScripts(page, javascripts, false).intValue() == javascripts.size());
+ }
+}
16 years, 5 months