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 2012/09/11 11:15:04 UTC
svn commit: r1383306 -
/myfaces/tobago/branches/tobago-1.5.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/ComponentUtils.java
Author: lofwyr
Date: Tue Sep 11 09:15:04 2012
New Revision: 1383306
URL: http://svn.apache.org/viewvc?rev=1383306&view=rev
Log:
comment (merged from trunk)
Modified:
myfaces/tobago/branches/tobago-1.5.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/ComponentUtils.java
Modified: myfaces/tobago/branches/tobago-1.5.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/ComponentUtils.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-1.5.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/ComponentUtils.java?rev=1383306&r1=1383305&r2=1383306&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-1.5.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/ComponentUtils.java (original)
+++ myfaces/tobago/branches/tobago-1.5.x/tobago-core/src/main/java/org/apache/myfaces/tobago/util/ComponentUtils.java Tue Sep 11 09:15:04 2012
@@ -1016,6 +1016,10 @@ public class ComponentUtils {
return ArrayUtils.EMPTY_STRING_ARRAY;
}
+ /**
+ * Adding a data attribute to the component.
+ * The name should not start with "data-", e. g. "tobago-foo" or "bar"
+ */
public static void putDataAttribute(UIComponent component, Object name, Object value) {
Map<Object, Object> map = (Map<Object, Object>) component.getAttributes().get(DATA_ATTRIBUTES_KEY);
if (map == null) {