myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bom...@apache.org
Subject svn commit: r813593 - /myfaces/tobago/branches/tobago-1.0.x/theme/scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/PageRenderer.java
Date Thu, 10 Sep 2009 21:19:27 GMT
Author: bommel
Date: Thu Sep 10 21:19:27 2009
New Revision: 813593

URL: http://svn.apache.org/viewvc?rev=813593&view=rev
Log:
(TOBAGO-788) Error using paging (tc:sheet) in IE

Modified:
    myfaces/tobago/branches/tobago-1.0.x/theme/scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/PageRenderer.java

Modified: myfaces/tobago/branches/tobago-1.0.x/theme/scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/PageRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-1.0.x/theme/scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/PageRenderer.java?rev=813593&r1=813592&r2=813593&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-1.0.x/theme/scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/PageRenderer.java
(original)
+++ myfaces/tobago/branches/tobago-1.0.x/theme/scarborough/src/main/java/org/apache/myfaces/tobago/renderkit/html/scarborough/standard/tag/PageRenderer.java
Thu Sep 10 21:19:27 2009
@@ -502,6 +502,15 @@
 
 //    facesContext.getApplication().getViewHandler().writeState(facesContext);
 
+    // avoid submit page in ie if the form contains only one input and you press the enter
key in the input
+    if (ClientProperties.getInstance(facesContext.getViewRoot()).getUserAgent().isMsie())
{
+      writer.startElement(HtmlConstants.INPUT, null);
+      writer.writeAttribute(HtmlAttributes.TYPE, "text", false);
+      writer.writeAttribute(HtmlAttributes.NAME, "tobago.dummy", false);
+      writer.writeAttribute(HtmlAttributes.TABINDEX, "-1", false);
+      writer.writeAttribute(HtmlAttributes.STYLE, "visibility:hidden;display:none;", false);
+      writer.endElement(HtmlConstants.INPUT);
+    }
     writer.endElement(HtmlConstants.FORM);
 
     // debugging...



Mime
View raw message