From 1042af9c7a0a1a3ef8a61bb10797f38768cd86d3 Mon Sep 17 00:00:00 2001 From: Jonatan Kronqvist Date: Fri, 7 Oct 2011 07:02:15 +0000 Subject: Fixes #7731 svn changeset:21627/svn branch:6.7 --- .../vaadin/terminal/gwt/client/ui/VScrollTable.java | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java b/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java index fc10ad97c7..53aa4c407e 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java +++ b/src/com/vaadin/terminal/gwt/client/ui/VScrollTable.java @@ -1020,7 +1020,6 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler, } updateHeader(uidl.getStringArrayAttribute("vcolorder")); - updateFooter(uidl.getStringArrayAttribute("vcolorder")); } @@ -2876,8 +2875,16 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler, } if (width != c.getWidth() && scrollBody != null) { // Do a more thorough update if a column is resized from - // the server - setColWidth(getColIndexByKey(c.cid), width, true); + // the server *after* the header has been properly + // initialized + final int colIx = getColIndexByKey(c.cid); + final int newWidth = width; + Scheduler.get().scheduleDeferred( + new ScheduledCommand() { + public void execute() { + setColWidth(colIx, newWidth, true); + } + }); refreshContentWidths = true; } else { c.setWidth(width, true); @@ -2900,7 +2907,11 @@ public class VScrollTable extends FlowPanel implements Table, ScrollHandler, if (refreshContentWidths) { // Recalculate the column sizings if any column has changed - triggerLazyColumnAdjustment(true); + Scheduler.get().scheduleDeferred(new ScheduledCommand() { + public void execute() { + triggerLazyColumnAdjustment(true); + } + }); } // check for orphaned header cells -- cgit v1.2.3