-
-
Notifications
You must be signed in to change notification settings - Fork 76
Fixed accidental rendering of swipe refresh indicator. #173
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed accidental rendering of swipe refresh indicator. #173
Conversation
|
This effectively disables upward scrolling:
Scrolling up is only possible if you scroll down and up in the same touch sequence. |
Thanks, @naveensingh! Marking this PR as Draft for further investigation. The <com.qtalk.recyclerviewfastscroller.RecyclerViewFastScroller
android:id="@+id/items_fastscroller"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:supportSwipeToRefresh="true">
…
</com.qtalk.recyclerviewfastscroller.RecyclerViewFastScroller>The fast scroller dependency is archived (RecyclerView‑Fast‑Scroller). Should we remove the |
I did not see that coming. We can't remove the scrollbar, so how about overriding override fun canChildScrollUp(): Boolean {
val directChild = getChildAt(0)
return when (directChild) {
is RecyclerViewFastScroller -> {
val innerRecyclerView = // iterate on children and find it
innerRecyclerView?.canScrollVertically(-1) == true
}
else -> super.canChildScrollUp()
}
}I have only briefly tested it, and it worked fine. |
Applied the suggested changes - it works perfectly now. Thanks! Marked this PR as ready. @naveensingh |
app/src/main/kotlin/org/fossify/filemanager/views/MySwipeRefreshLayout.kt
Outdated
Show resolved
Hide resolved
|
I will test and merge this soon. Thank you! |
…shLayout.kt Fix grammar after copy paste. Co-authored-by: Naveen Singh <[email protected]>
Hope this legacy 7-year-old issue is now eliminated :)
Type of change(s)
What changed and why
SwipeRefreshLayout, inspired by Firefox's VerticalSwipeRefreshLayout.Optionally, we can move this file to the Commons repository.
Fixes the following issue(s)
Checklist
CHANGELOG.md(if applicable).