Procházet zdrojové kódy

Fix the end limit of the allowed scrollTo rows. (#11771)

- Row index counts up from zero, data provider size counts up from one,
as one would expect. If the two match we are already past the available
range.
tags/8.10.0.alpha1
Anna Koskinen před 4 roky
rodič
revize
be5c6b9755
Žádný účet není propojen s e-mailovou adresou tvůrce revize
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1
    1
      server/src/main/java/com/vaadin/ui/Grid.java

+ 1
- 1
server/src/main/java/com/vaadin/ui/Grid.java Zobrazit soubor

@@ -4390,7 +4390,7 @@ public class Grid<T> extends AbstractListing<T> implements HasComponents,
Objects.requireNonNull(destination,
"ScrollDestination can not be null");

if (row > getDataCommunicator().getDataProviderSize()) {
if (row >= getDataCommunicator().getDataProviderSize()) {
throw new IllegalArgumentException("Row outside dataProvider size");
}


Načítá se…
Zrušit
Uložit