summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authorTeemu Suo-Anttila <tsuoanttila@users.noreply.github.com>2017-03-15 14:00:50 +0200
committerTeemu Suo-Anttila <tsuoanttila@users.noreply.github.com>2017-03-16 16:21:24 +0200
commitf6888557f39f697a1911b2f8cf53dee3bfa55a65 (patch)
tree227d5bd67caa7fee2cc82bb499d2e24e29cde947 /client
parent188884d4c2309873e7e7144face9fb0053b18a6f (diff)
downloadvaadin-framework-f6888557f39f697a1911b2f8cf53dee3bfa55a65.tar.gz
vaadin-framework-f6888557f39f697a1911b2f8cf53dee3bfa55a65.zip
Allow changing renderers after column creation (#8841)
Closes #8250
Diffstat (limited to 'client')
-rw-r--r--client/src/main/java/com/vaadin/client/connectors/grid/ColumnConnector.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/client/src/main/java/com/vaadin/client/connectors/grid/ColumnConnector.java b/client/src/main/java/com/vaadin/client/connectors/grid/ColumnConnector.java
index d619b50b5d..149ef4c1f9 100644
--- a/client/src/main/java/com/vaadin/client/connectors/grid/ColumnConnector.java
+++ b/client/src/main/java/com/vaadin/client/connectors/grid/ColumnConnector.java
@@ -73,7 +73,6 @@ public class ColumnConnector extends AbstractExtensionConnector {
return null;
}
};
- column.setRenderer(getRendererConnector().getRenderer());
getParent().addColumn(column, getState().internalId);
}
@@ -92,6 +91,11 @@ public class ColumnConnector extends AbstractExtensionConnector {
column.setSortable(getState().sortable);
}
+ @OnStateChange("renderer")
+ void updateRenderer() {
+ column.setRenderer(getRendererConnector().getRenderer());
+ }
+
@OnStateChange("hidingToggleCaption")
void updateHidingToggleCaption() {
column.setHidingToggleCaption(getState().hidingToggleCaption);