Giter VIP home page Giter VIP logo

nestedrecyclerview's People

Contributors

jasongaoh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

nestedrecyclerview's Issues

📌 Follow the Step-by-Step Guide to Claim Your $700 Now!

Introduction:

Welcome to the exciting world of crypto airdrops! Here's a curated list of active airdrops that you wouldn't want to miss. Dive in and explore the opportunities:

📌 Follow the Step-by-Step Guide to Claim Your Tokens!

  1. Share on Social Media:

    🚀 Claim Your Share: Pyth Network Airdrop 🚀 Unlock the potential of $PYTH tokens in this step-by-step guide. Claim yours now! Share on Twitter

    — Pyth Network (@pythnetwork) November 28, 2023
  2. Verify Eligibility:
    After sharing and connecting your walle

Active Airdrops:

  1. Layer Zero Airdrop

    Layer Zero Banner
  2. Pyth Network Airdrop

    Pyth Network Banner
  3. Mantle Network Airdrop

    Mantle Network Banner

childrecyclerview 重置的时机

不知道大佬对childrecyclerview 这个holder重复刷新与复用时,什么时机重置childrecyclerview的状态合适以及如何重置childrecyclerview,否则经常会因为ParentRecyclerview的canScrollVertically方法被拦住不能滑动。

处理嵌套滚动

看到有说处理嵌套滚动问题,当我们滑动不松手时会出现无法滑动的问题,咱们解决的方案有吗?

【解决办法】从子列表向上滑动时,会出现子列表未滑动到顶部的情况

感谢作者的代码!
提个修改建议: ParentRecyclerView中
public boolean canScrollVertically() { ChildRecyclerView childRecyclerView = findNestedScrollingChildRecyclerView(); return (canScrollVertically.get() || childRecyclerView == null || childRecyclerView.isScrollTop()); }
这里上滑时,没有判断子列表未滑动到顶部的情况,改成下面这种方式就OK了
public boolean canScrollVertically() { ChildRecyclerView childRecyclerView = findNestedScrollingChildRecyclerView(); if (childRecyclerView != null && !childRecyclerView.isScrollTop()) { return false; } else { return canScrollVertically.get(); } }

问题反馈:多tab切换导致子recyclerview无法滑动问题

当tab1下面子recyclerview滑动到第N项,切换到tab2,在tab2页面下滑,把tab滑动至屏幕**,切回tab1,此时tab1的子recyclerview无法将之前滑上去的项滑出。

如果tab栏上方的项(也就是父recyclerview除了tab栏和子recyclerview之外的项)比较少时,会出现某些tab栏下的recyclerview表现的像是无法滑动。

修改建议:

ParentRecyclerView原方法

override fun canScrollVertically(): Boolean {
                val childRecyclerView = findNestedScrollingChildRecyclerView()

                if(canScrollVertically.get() || childRecyclerView == null || childRecyclerView.isScrollTop()) {
                    return true
                }
                return false

            }

改为

 override fun canScrollVertically(): Boolean {
                val childRecyclerView = findNestedScrollingChildRecyclerView()
                if (childRecyclerView == null) {
                    return canScrollVertically.get();
                }
                if (!childRecyclerView.isScrollTop()) {//先让子recyclerview滑动到顶部
                    return false
                }
                return (canScrollVertically.get() || childRecyclerView.isScrollTop())
            }

如果有类似问题可以参考此建议,但如果需求就是要那样的效果就不必改了。

有两个问题

rt
1.向上滑动列表时初次滑动会有卡顿问题
2.当下方Recyclerview全部显示的时候,在快速fling的过程中,底部Recyclerview在未全部显示(滑动到顶部时)就已经将手势交给外层列表开始滑动头部Recyclerview

ChildRecyclerView置顶滑动卡顿

Tab置顶之后
切换到其他tab
一下子向上滑动 childRecyclerView
可以发现childRecyclerView 会突然一下子卡主不滑动了
当childRecyclerView 每次加载好数据之后 就不会出现这样的问题

tab从吸顶到非吸顶时,建议将所有tab页面的滑动位置重置。

问题重现步骤: A tab 所在页面向上滑动到吸顶后一定位置(假如是4 position 位置),切换到B tab ,然后在B tab 所在页面再向下滑动到非吸顶,再切换到A tab,此时A tab所在页面由于没有重置滑动位置,还是停留在position为4的位置,此时无论向上还是向下滑动都无法看到position为4之前的内容,需要继续滑动到吸顶一定距离再向下滑动才能正常。

滑动的时候出现页面抖动

1:ParentRecyclerView适配器里面有多个ViewItemType, 每个页面item的高度是不一样的
2:childRecyclerView 的tab置顶之后,缓慢向下滑动,滑动tab 处于页面中间的时候会出现抖动,突然向下滑动了一段距离,导致了页面的闪烁

设置ParentRecyclerView的layoutManager为StaggeredGridLayoutManager会有问题

1、在调用Parent.initLayoutManager()方法前,为ParentRecyclerView再设置一个StaggeredGridLayoutManager,会导致滑动冲突,这是为啥?
2、如果给ParentRecyclerView设置了StaggeredGridLayoutManager,initLayoutManager方法里面的LinearLayoutManager也必须设置为StaggeredGridLayoutManager,这个问题也不清楚是为啥?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.