From f453676e7318e19abae2ba3e23cd18ef8eb53b4e Mon Sep 17 00:00:00 2001 From: Juho Nurminen Date: Wed, 14 May 2014 14:14:43 +0300 Subject: Made user-initiated column resizing take precedence over other updates (#13432) VScrollTable ignores server-initiated changes to column size while the user is dragging a table resizer element. Change-Id: I2866246e7975a8ddddbfdc12a9d99fb2c813a870 --- client/src/com/vaadin/client/ui/VScrollTable.java | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'client') diff --git a/client/src/com/vaadin/client/ui/VScrollTable.java b/client/src/com/vaadin/client/ui/VScrollTable.java index 4a7fc1de0a..6717a1a521 100644 --- a/client/src/com/vaadin/client/ui/VScrollTable.java +++ b/client/src/com/vaadin/client/ui/VScrollTable.java @@ -2702,7 +2702,9 @@ public class VScrollTable extends FlowPanel implements HasWidgets, public void setUndefinedWidth() { definedWidth = false; - setWidth(-1, false); + if (!isResizing) { + setWidth(-1, false); + } } /** @@ -3358,7 +3360,7 @@ public class VScrollTable extends FlowPanel implements HasWidgets, c.setAlign(ALIGN_LEFT); } - if (col.hasAttribute("width")) { + if (col.hasAttribute("width") && !c.isResizing) { // Make sure to accomodate for the sort indicator if // necessary. int width = col.getIntAttribute("width"); @@ -6637,6 +6639,9 @@ public class VScrollTable extends FlowPanel implements HasWidgets, int checksum = 0; while (headCells.hasNext()) { hCell = (HeaderCell) headCells.next(); + if (hCell.isResizing) { + continue; + } if (!hCell.isDefinedWidth()) { int w = hCell.getNaturalColumnWidth(colIndex); int newSpace; -- cgit v1.2.3