Using GWT 2.5.1, SimplePager.java has this method:

  @Override
  protected void onRangeOrRowCountChanged() {
    HasRows display = getDisplay();
    label.setText(createText());

    // Update the prev and first buttons.
    setPrevPageButtonsDisabled(!hasPreviousPage());

    // Update the next and last buttons.
    if (isRangeLimited() || !display.isRowCountExact()) {
      setNextPageButtonsDisabled(!hasNextPage());
      setFastForwardDisabled(!hasNextPages(getFastForwardPages()));
    }
  }

Why are the next/last buttons enabled/disabled only if range is limited or 
if the row count isn't exact? I have a pager set to range limited false, 
and my data provider specifies that the row count is exact when I update 
the row count. With this setup, the next/last paging buttons will NEVER be 
updated!

Am I just using this wrong, or is it a bug?

I worked around the issue by subclassing SimplePager to allow me into that 
block at the bottom of onRangeOrRowCountChanged():

        @Override
        protected void onRangeOrRowCountChanged() {
            boolean rangeLimited = isRangeLimited();
            super.setRangeLimited(true);
            super.onRangeOrRowCountChanged();
            super.setRangeLimited(rangeLimited);
        }


-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to