aboutsummaryrefslogtreecommitdiffstats
path: root/server/src
diff options
context:
space:
mode:
authorArtur Signell <artur@vaadin.com>2014-11-26 23:02:23 +0200
committerArtur Signell <artur@vaadin.com>2014-12-01 13:11:00 +0000
commit67c3d0534594585a9631ac3f00258c133a54d975 (patch)
treef3f87691c04612d049e02920572cce56ae43e036 /server/src
parent1edeb7c4a8f3a31915e895e2314d26d0f7534189 (diff)
downloadvaadin-framework-67c3d0534594585a9631ac3f00258c133a54d975.tar.gz
vaadin-framework-67c3d0534594585a9631ac3f00258c133a54d975.zip
Allow setting style names for header and footer cells (#7225)
Change-Id: Ieb8f5b36466a2d579e9c82f16613f6bc8952c831
Diffstat (limited to 'server/src')
-rw-r--r--server/src/com/vaadin/ui/Grid.java21
1 files changed, 21 insertions, 0 deletions
diff --git a/server/src/com/vaadin/ui/Grid.java b/server/src/com/vaadin/ui/Grid.java
index 715190e293..5afb0038e0 100644
--- a/server/src/com/vaadin/ui/Grid.java
+++ b/server/src/com/vaadin/ui/Grid.java
@@ -470,6 +470,27 @@ public class Grid extends AbstractComponent implements SelectionChangeNotifier,
cellState.type = GridStaticCellType.WIDGET;
row.section.markAsDirty();
}
+
+ /**
+ * Returns the custom style name for this cell.
+ *
+ * @return the style name or null if no style name has been set
+ */
+ public String getStyleName() {
+ return cellState.styleName;
+ }
+
+ /**
+ * Sets a custom style name for this cell.
+ *
+ * @param styleName
+ * the style name to set
+ */
+ public void setStyleName(String styleName) {
+ cellState.styleName = styleName;
+ row.section.markAsDirty();
+ }
+
}
protected Grid grid;