diff options
author | Artur Signell <artur@vaadin.com> | 2011-11-24 10:34:30 +0200 |
---|---|---|
committer | Artur Signell <artur@vaadin.com> | 2011-11-24 10:34:30 +0200 |
commit | fbe730fa4c7b4a842161bf1576ef9e5591c73966 (patch) | |
tree | 9156724c69ec7e97a2b3f36460ab82616bd88867 /src | |
parent | f76503ec651cc0b55f5c1870984493085f1daa1b (diff) | |
parent | cc44f8de6e91c85f455e44ece787fff8cc05222a (diff) | |
download | vaadin-framework-fbe730fa4c7b4a842161bf1576ef9e5591c73966.tar.gz vaadin-framework-fbe730fa4c7b4a842161bf1576ef9e5591c73966.zip |
Merge remote-tracking branch 'origin/6.8'
Diffstat (limited to 'src')
-rw-r--r-- | src/com/vaadin/terminal/gwt/client/ui/VDragAndDropWrapperIE.java | 4 | ||||
-rw-r--r-- | src/com/vaadin/terminal/gwt/client/ui/VTreeTable.java | 17 |
2 files changed, 15 insertions, 6 deletions
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VDragAndDropWrapperIE.java b/src/com/vaadin/terminal/gwt/client/ui/VDragAndDropWrapperIE.java index 89f063eaf9..0032b1a5dc 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/VDragAndDropWrapperIE.java +++ b/src/com/vaadin/terminal/gwt/client/ui/VDragAndDropWrapperIE.java @@ -1,3 +1,7 @@ +/* +@ITMillApache2LicenseForJavaFiles@ + */ + package com.vaadin.terminal.gwt.client.ui; import com.google.gwt.dom.client.AnchorElement; diff --git a/src/com/vaadin/terminal/gwt/client/ui/VTreeTable.java b/src/com/vaadin/terminal/gwt/client/ui/VTreeTable.java index bcd87da751..fc6ec46d64 100644 --- a/src/com/vaadin/terminal/gwt/client/ui/VTreeTable.java +++ b/src/com/vaadin/terminal/gwt/client/ui/VTreeTable.java @@ -81,6 +81,7 @@ public class VTreeTable extends VScrollTable { colIndexOfHierarchy = uidl .hasAttribute(ATTRIBUTE_HIERARCHY_COLUMN_INDEX) ? uidl .getIntAttribute(ATTRIBUTE_HIERARCHY_COLUMN_INDEX) : 0; + int oldTotalRows = getTotalRows(); super.updateFromUIDL(uidl, client); if (collapseRequest) { if (collapsedRowKey != null && scrollBody != null) { @@ -96,15 +97,19 @@ public class VTreeTable extends VScrollTable { widget.setScrollPosition(scrollPosition); } - /* - * Triggers row calculations, removes cached rows etc. Basically - * cleans up state. Be careful if touching this, you will brake - * pageLength=0 if you remove this. - */ + // check which rows are needed from the server and initiate a + // deferred fetch onScroll(null); - + } + // Recalculate table size if collapse request, or if page length is zero + // (not sent by server) and row count changes (#7908). + if (collapseRequest + || (!uidl.hasAttribute("pagelength") && getTotalRows() != oldTotalRows)) { /* * Ensure that possibly removed/added scrollbars are considered. + * Triggers row calculations, removes cached rows etc. Basically + * cleans up state. Be careful if touching this, you will break + * pageLength=0 if you remove this. */ triggerLazyColumnAdjustment(true); |