diff options
author | Sauli Tähkäpää <sauli@vaadin.com> | 2014-05-26 10:56:50 +0300 |
---|---|---|
committer | Sauli Tähkäpää <sauli@vaadin.com> | 2014-05-26 11:12:05 +0300 |
commit | 0b3af0fe74b790a5ac4159a97ccb4e5aeb8ad85c (patch) | |
tree | 141932264486297e1c0cf160b7fe4b5150eaa1fe /server/src/com/vaadin/ui/Table.java | |
parent | af9dadbf3517b76e86e0e60452661dc07b178e57 (diff) | |
download | vaadin-framework-0b3af0fe74b790a5ac4159a97ccb4e5aeb8ad85c.tar.gz vaadin-framework-0b3af0fe74b790a5ac4159a97ccb4e5aeb8ad85c.zip |
Revert "Fix Push inserts producing duplicate rows in Table (#13562)"
This reverts commit ce1764fb1bad1b82462d73fbfe293b676c2a9c00.
Change-Id: I897e0f3a0876eaea4b68f0e3b75671ccb1398242
Diffstat (limited to 'server/src/com/vaadin/ui/Table.java')
-rw-r--r-- | server/src/com/vaadin/ui/Table.java | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/server/src/com/vaadin/ui/Table.java b/server/src/com/vaadin/ui/Table.java index 29dc52a9a6..b4d79f304c 100644 --- a/server/src/com/vaadin/ui/Table.java +++ b/server/src/com/vaadin/ui/Table.java @@ -2954,23 +2954,15 @@ public class Table extends AbstractSelect implements Action.Container, // (row caches emptied by other event) if (!containerChangeToBeRendered) { Integer value = (Integer) variables.get("reqfirstrow"); - int tableSize = size(); if (value != null) { reqFirstRowToPaint = value.intValue(); - // Sanity check - if (reqFirstRowToPaint < 0) { - reqFirstRowToPaint = -1; - } - if (reqFirstRowToPaint >= tableSize) { - reqFirstRowToPaint = tableSize - 1; - } } value = (Integer) variables.get("reqrows"); if (value != null) { reqRowsToPaint = value.intValue(); // sanity check - if (reqFirstRowToPaint + reqRowsToPaint > tableSize) { - reqRowsToPaint = tableSize - reqFirstRowToPaint; + if (reqFirstRowToPaint + reqRowsToPaint > size()) { + reqRowsToPaint = size() - reqFirstRowToPaint; } } } |