You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by ha...@apache.org on 2008/07/11 14:24:44 UTC
svn commit: r675933 -
/myfaces/shared/trunk/core/src/main/java/org/apache/myfaces/shared/renderkit/html/HtmlImageRendererBase.java
Author: hazems
Date: Fri Jul 11 05:24:44 2008
New Revision: 675933
URL: http://svn.apache.org/viewvc?rev=675933&view=rev
Log:
Solution for http://issues.apache.org/jira/browse/TOMAHAWK-1291.
Now when the alt attribute is missing for the <t:graphicImage .../>
a soft warning message will be displayed to the user.
Modified:
myfaces/shared/trunk/core/src/main/java/org/apache/myfaces/shared/renderkit/html/HtmlImageRendererBase.java
Modified: myfaces/shared/trunk/core/src/main/java/org/apache/myfaces/shared/renderkit/html/HtmlImageRendererBase.java
URL: http://svn.apache.org/viewvc/myfaces/shared/trunk/core/src/main/java/org/apache/myfaces/shared/renderkit/html/HtmlImageRendererBase.java?rev=675933&r1=675932&r2=675933&view=diff
==============================================================================
--- myfaces/shared/trunk/core/src/main/java/org/apache/myfaces/shared/renderkit/html/HtmlImageRendererBase.java (original)
+++ myfaces/shared/trunk/core/src/main/java/org/apache/myfaces/shared/renderkit/html/HtmlImageRendererBase.java Fri Jul 11 05:24:44 2008
@@ -75,16 +75,11 @@
HtmlRendererUtils.renderHTMLAttributes(writer, uiComponent, HTML.IMG_PASSTHROUGH_ATTRIBUTES);
/*
- * ALT would not rendered by the renderHTMLAttributes() utility so here
- * We should set this attribute here if it is empty.
- * For being XHTML complaint.
- */
- //System.out.println("The passed alt is : " + uiComponent.getAttributes().get(HTML.ALT_ATTR));
+ * Warn the user if the ALT attribute is missing.
+ */
if (uiComponent.getAttributes().get(HTML.ALT_ATTR) == null)
{
- writer.writeAttribute(HTML.ALT_ATTR,
- "",
- null);
+ log.warn("ALT attribute is missing for : " + uiComponent.getId());
}
writer.endElement(org.apache.myfaces.shared.renderkit.html.HTML.IMG_ELEM);