myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lu4...@apache.org
Subject svn commit: r991433 - in /myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext: HtmlMessageRenderer.java HtmlMessagesRenderer.java
Date Wed, 01 Sep 2010 04:22:57 GMT
Author: lu4242
Date: Wed Sep  1 04:22:56 2010
New Revision: 991433

URL: http://svn.apache.org/viewvc?rev=991433&view=rev
Log:
MYFACES-2895 Messages component cannot be updated by ajax without wrapping it

Modified:
    myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessageRenderer.java
    myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessagesRenderer.java

Modified: myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessageRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessageRenderer.java?rev=991433&r1=991432&r2=991433&view=diff
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessageRenderer.java
(original)
+++ myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessageRenderer.java
Wed Sep  1 04:22:56 2010
@@ -86,8 +86,16 @@ public class HtmlMessageRenderer
             }
         }
 
-        renderMessage(facesContext, component);
+        boolean forceSpan = false;
+        if (component instanceof HtmlMessage
+                && ((HtmlMessage) component).getForceSpan())
+        {
+            forceSpan = true;
+        }
 
+        renderMessage(facesContext, component, forceSpan, true);
+
+        /*
         if (component instanceof HtmlMessage
                 && ((HtmlMessage)component).getForceSpan())
         {
@@ -109,7 +117,7 @@ public class HtmlMessageRenderer
                 writer.writeAttribute(HTML.STYLE_ATTR,htmlMessage.getStyle(),null);
                 writer.endElement(HTML.SPAN_ELEM);
             }
-        }
+        }*/
     }
 
     protected String getSummary(FacesContext facesContext,

Modified: myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessagesRenderer.java
URL: http://svn.apache.org/viewvc/myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessagesRenderer.java?rev=991433&r1=991432&r2=991433&view=diff
==============================================================================
--- myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessagesRenderer.java
(original)
+++ myfaces/tomahawk/trunk/core20/src/main/java/org/apache/myfaces/renderkit/html/ext/HtmlMessagesRenderer.java
Wed Sep  1 04:22:56 2010
@@ -72,9 +72,17 @@ public class HtmlMessagesRenderer
                 ResourceUtils.renderDefaultJsfJsInlineIfNecessary(facesContext, facesContext.getResponseWriter());
             }
         }
+
+        boolean forceSpan = false;
+        if (component instanceof HtmlMessages
+                && ((HtmlMessages) component).getForceSpan())
+        {
+            forceSpan = true;
+        }
         
-        renderMessages(facesContext, component);
+        renderMessages(facesContext, component, forceSpan, true);
 
+        /*
         if (component instanceof HtmlMessages
                 && ((HtmlMessages) component).getForceSpan())
         {
@@ -89,7 +97,7 @@ public class HtmlMessagesRenderer
             if(htmlMessages.getStyle()!=null)
             writer.writeAttribute(HTML.STYLE_ATTR,htmlMessages.getStyle(),null);
             writer.endElement(HTML.SPAN_ELEM);
-        }
+        }*/
     }
 
     protected String getSummary(FacesContext facesContext,



Mime
View raw message