summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLeif Åstrand <leif@vaadin.com>2014-11-24 23:00:44 +0200
committerLeif Åstrand <leif@vaadin.com>2014-11-24 23:01:43 +0200
commit759ec0e19569ba6b0d0e43f68cdd25e26ecf55d6 (patch)
tree5b9e32a28ff7edc7ccfc50886c0aa286fd5116f3
parentfe1e44e76340ce3aebc6d108a9ffd20ef2e70cbe (diff)
downloadvaadin-framework-759ec0e19569ba6b0d0e43f68cdd25e26ecf55d6.tar.gz
vaadin-framework-759ec0e19569ba6b0d0e43f68cdd25e26ecf55d6.zip
Don't pass null to TableXyzElement.as when changing stylename (#13334)
Change-Id: Icfa7b6e4affe51111c8f5b4495d97bb80b983087
-rw-r--r--client/src/com/vaadin/client/ui/grid/Escalator.java9
1 files changed, 5 insertions, 4 deletions
diff --git a/client/src/com/vaadin/client/ui/grid/Escalator.java b/client/src/com/vaadin/client/ui/grid/Escalator.java
index 5679dfec1f..c91558e2a2 100644
--- a/client/src/com/vaadin/client/ui/grid/Escalator.java
+++ b/client/src/com/vaadin/client/ui/grid/Escalator.java
@@ -1713,16 +1713,17 @@ public class Escalator extends Widget implements RequiresResize, DeferredWorker
this.primaryStyleName = primaryStyleName;
// Update already rendered rows and cells
- TableRowElement row = root.getRows().getItem(0);
+ Element row = root.getRows().getItem(0);
while (row != null) {
UIObject.setStylePrimaryName(row, primaryStyleName + "-row");
- TableCellElement cell = row.getCells().getItem(0);
+ Element cell = TableRowElement.as(row).getCells().getItem(0);
while (cell != null) {
+ assert TableCellElement.is(cell);
UIObject.setStylePrimaryName(cell, primaryStyleName
+ "-cell");
- cell = TableCellElement.as(cell.getNextSiblingElement());
+ cell = cell.getNextSiblingElement();
}
- row = TableRowElement.as(row.getNextSiblingElement());
+ row = row.getNextSiblingElement();
}
}