From b6d5d0cac8a9ae2f99ef7fdc34d8e53353fcf84b Mon Sep 17 00:00:00 2001 From: Teemu Suo-Anttila Date: Fri, 4 May 2018 14:53:21 +0300 Subject: Fix Grid initial data when changing TabSheet Tab (#10872) --- server/src/main/java/com/vaadin/data/provider/DataCommunicator.java | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'server') diff --git a/server/src/main/java/com/vaadin/data/provider/DataCommunicator.java b/server/src/main/java/com/vaadin/data/provider/DataCommunicator.java index 99201965f1..574ed99045 100644 --- a/server/src/main/java/com/vaadin/data/provider/DataCommunicator.java +++ b/server/src/main/java/com/vaadin/data/provider/DataCommunicator.java @@ -220,6 +220,11 @@ public class DataCommunicator extends AbstractExtension { public void attach() { super.attach(); attachDataProviderListener(); + + if (getPushRows().isEmpty()) { + // Make sure rows are pushed when component is attached. + setPushRows(Range.withLength(0, getMinPushSize())); + } } @Override -- cgit v1.2.3