incubator-adffaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mat...@apache.org
Subject svn commit: r440698 - /incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/renderkit/core/xhtml/ColumnGroupRenderer.java
Date Wed, 06 Sep 2006 12:14:06 GMT
Author: matzew
Date: Wed Sep  6 05:14:06 2006
New Revision: 440698

URL: http://svn.apache.org/viewvc?view=rev&rev=440698
Log:
Moving from ascending sort to descending sort on a tr:column is now working on PDA (ADFFACES-157).Thx
for the patch, Josef

Modified:
    incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/renderkit/core/xhtml/ColumnGroupRenderer.java

Modified: incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/renderkit/core/xhtml/ColumnGroupRenderer.java
URL: http://svn.apache.org/viewvc/incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/renderkit/core/xhtml/ColumnGroupRenderer.java?view=diff&rev=440698&r1=440697&r2=440698
==============================================================================
--- incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/renderkit/core/xhtml/ColumnGroupRenderer.java
(original)
+++ incubator/adffaces/trunk/trinidad/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/renderkit/core/xhtml/ColumnGroupRenderer.java
Wed Sep  6 05:14:06 2006
@@ -361,6 +361,28 @@
     int sortability = getSortability(tContext, column);
     boolean sortable = (sortability != SORT_NO) &&
                        supportsNavigation(arc);
+                       
+    if(sortable)
+    {
+      // the sortable script has a "state" parameter, so add this
+      // to the form data if the agent does not support dynamic
+      // generation of elements (on those that do, form data elements
+      // can be created on the fly as necessary); see the JS
+      // referenced in this.getSortingOnclick
+      Object domLevel = 
+        arc.getAgent().getCapability(TrinidadAgent.CAP_DOM);
+      if(
+        domLevel == null || 
+        domLevel == TrinidadAgent.DOM_CAP_NONE || 
+        domLevel == TrinidadAgent.DOM_CAP_FORM)
+      {
+        FormData formData = arc.getFormData();
+        if(formData != null)
+        {
+          formData.addNeededValue(XhtmlConstants.STATE_PARAM);
+        }      
+      }
+    }
 
     // we do not want to wrap if wrapping has explicitly been disabled. if we
     // are inside a columnGroup then we need to check the header format on the



Mime
View raw message