summaryrefslogtreecommitdiffstats
path: root/server
diff options
context:
space:
mode:
authorArtur Signell <artur@vaadin.com>2014-12-01 21:14:18 +0200
committerLeif Åstrand <leif@vaadin.com>2014-12-04 11:36:18 +0000
commitc00921a2ff94915a425569a60c7651e702b3d2c6 (patch)
treea11da6ec5738ece6a981a194769c34f0368cb932 /server
parentd3cfb79c223a772d3baec8476a9d15716bade1ff (diff)
downloadvaadin-framework-c00921a2ff94915a425569a60c7651e702b3d2c6.tar.gz
vaadin-framework-c00921a2ff94915a425569a60c7651e702b3d2c6.zip
Allow setting style name for header/footer rows (#7225)
Change-Id: I798e26b0a734c3c460b4e458d04332c7a3b599fc
Diffstat (limited to 'server')
-rw-r--r--server/src/com/vaadin/ui/Grid.java24
1 files changed, 23 insertions, 1 deletions
diff --git a/server/src/com/vaadin/ui/Grid.java b/server/src/com/vaadin/ui/Grid.java
index c617917555..04b0e65a1e 100644
--- a/server/src/com/vaadin/ui/Grid.java
+++ b/server/src/com/vaadin/ui/Grid.java
@@ -357,6 +357,27 @@ public class Grid extends AbstractComponent implements SelectionChangeNotifier,
}
return null;
}
+
+ /**
+ * Returns the custom style name for this row.
+ *
+ * @return the style name or null if no style name has been set
+ */
+ public String getStyleName() {
+ return getRowState().styleName;
+ }
+
+ /**
+ * Sets a custom style name for this row.
+ *
+ * @param styleName
+ * the style name to set or null to not use any style
+ * name
+ */
+ public void setStyleName(String styleName) {
+ getRowState().styleName = styleName;
+ }
+
}
/**
@@ -485,7 +506,8 @@ public class Grid extends AbstractComponent implements SelectionChangeNotifier,
* Sets a custom style name for this cell.
*
* @param styleName
- * the style name to set
+ * the style name to set or null to not use any style
+ * name
*/
public void setStyleName(String styleName) {
cellState.styleName = styleName;