summaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
Diffstat (limited to 'client')
-rw-r--r--client/src/main/java/com/vaadin/client/connectors/grid/ColumnConnector.java1
-rwxr-xr-xclient/src/main/java/com/vaadin/client/widgets/Grid.java6
2 files changed, 7 insertions, 0 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 be1734a269..1737f90210 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
@@ -108,6 +108,7 @@ public class ColumnConnector extends AbstractExtensionConnector {
// Initially set a renderer
updateRenderer();
+ updateHidden();
getParent().addColumn(column, getState().internalId);
diff --git a/client/src/main/java/com/vaadin/client/widgets/Grid.java b/client/src/main/java/com/vaadin/client/widgets/Grid.java
index 38cdfa4c3d..d8f0e12b76 100755
--- a/client/src/main/java/com/vaadin/client/widgets/Grid.java
+++ b/client/src/main/java/com/vaadin/client/widgets/Grid.java
@@ -5131,6 +5131,12 @@ public class Grid<T> extends ResizeComposite implements HasSelectionHandlers<T>,
private void setHidden(boolean hidden, boolean userOriginated) {
if (this.hidden != hidden) {
+ if (grid == null) {
+ // Not yet attached so just update the flag so that a column
+ // can initially be hidden
+ this.hidden = hidden;
+ return;
+ }
if (hidden) {
grid.escalator.getColumnConfiguration().removeColumns(
grid.getVisibleColumns().indexOf(this), 1);