diff options
author | Juho Nurminen <juho@vaadin.com> | 2014-05-14 14:14:43 +0300 |
---|---|---|
committer | Vaadin Code Review <review@vaadin.com> | 2014-05-16 07:56:01 +0000 |
commit | f453676e7318e19abae2ba3e23cd18ef8eb53b4e (patch) | |
tree | 8f7efc5b29fcda9b1d291cfa51d0c50c98894341 /client | |
parent | d67022303ae9e4d3448012a07572f1bf3c71f46c (diff) | |
download | vaadin-framework-f453676e7318e19abae2ba3e23cd18ef8eb53b4e.tar.gz vaadin-framework-f453676e7318e19abae2ba3e23cd18ef8eb53b4e.zip |
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
Diffstat (limited to 'client')
-rw-r--r-- | client/src/com/vaadin/client/ui/VScrollTable.java | 9 |
1 files changed, 7 insertions, 2 deletions
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; |