Skip to content

Conversation

chagaiB
Copy link

@chagaiB chagaiB commented Sep 17, 2025

This PR fixes an issue where pull-to-refresh could trigger while the files list
was not at the top, causing an unexpected refresh and interrupting scrolling.

Implementation:

  • Set a ChildScrollUpCallback on SwipeRefreshLayout to return true when the
    RecyclerView can still scroll up (canScrollVertically(-1) == true). This
    prevents SwipeRefreshLayout from intercepting gestures mid-list.

Fixes #15619.

  1. Open the files list screen.
  2. Scroll down so the list is not at the very top.
  3. Drag using the scrollbar / or perform a slight pull gesture.
    Expected: no refresh is triggered; scrolling remains smooth.
  4. Go back to the very top and pull down.
    Expected: pull-to-refresh triggers normally.

Copy link

github-actions bot commented Oct 1, 2025

Hello there,
Thank you so much for taking the time and effort to create a pull request to our Nextcloud project.

We hope that the review process is going smooth and is helpful for you. We want to ensure your pull request is reviewed to your satisfaction. If you have a moment, our community management team would very much appreciate your feedback on your experience with this PR review process.

Your feedback is valuable to us as we continuously strive to improve our community developer experience. Please take a moment to complete our short survey by clicking on the following link: https://cloud.nextcloud.com/apps/forms/s/i9Ago4EQRZ7TWxjfmeEpPkf6

Thank you for contributing to Nextcloud and we hope to hear from you soon!

(If you believe you should not receive this message, you can add yourself to the blocklist.)

…oll up

This PR fixes an issue where pull-to-refresh could trigger while the files list
was not at the top, causing an unexpected refresh and interrupting scrolling.

Implementation:
- Set a ChildScrollUpCallback on SwipeRefreshLayout to return true when the
  RecyclerView can still scroll up (canScrollVertically(-1) == true). This
  prevents SwipeRefreshLayout from intercepting gestures mid-list.


Signed-off-by: chagaiB <chagai522@gmail.com>
Copy link
Collaborator

@alperozturk96 alperozturk96 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, thank you for the PR. I can't test it. It is not building. swipeRefreshLayout not exists in the OCFileListFragment. You can use binding to access it.

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Scrolling with scroll bar unexpected behavior

3 participants