You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lo...@apache.org on 2010/08/10 10:36:05 UTC

svn commit: r983881 - /myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/util/HtmlRendererUtils.java

Author: lofwyr
Date: Tue Aug 10 08:36:05 2010
New Revision: 983881

URL: http://svn.apache.org/viewvc?rev=983881&view=rev
Log:
prevent NPE

Modified:
    myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/util/HtmlRendererUtils.java

Modified: myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/util/HtmlRendererUtils.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/util/HtmlRendererUtils.java?rev=983881&r1=983880&r2=983881&view=diff
==============================================================================
--- myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/util/HtmlRendererUtils.java (original)
+++ myfaces/tobago/trunk/tobago-theme/tobago-theme-standard/src/main/java/org/apache/myfaces/tobago/renderkit/html/util/HtmlRendererUtils.java Tue Aug 10 08:36:05 2010
@@ -390,11 +390,11 @@ public final class HtmlRendererUtils {
         Markup markup = item instanceof SupportsMarkup ? ((SupportsMarkup) item).getMarkup() : Markup.NULL;
         if (RenderUtils.contains(values, itemValue)) {
           writer.writeAttribute(HtmlAttributes.SELECTED, true);
-          markup = markup.add(Markup.SELECTED);
+          markup = Markup.SELECTED.add(markup);
         }
         if (item.isDisabled()) {
           writer.writeAttribute(HtmlAttributes.DISABLED, true);
-          markup = markup.add(Markup.DISABLED);
+          markup = Markup.DISABLED.add(markup);
         }
         writer.writeClassAttribute(Classes.create(component, "option", markup));