I am playing with RecyclerView right now and came across the following problem. When the RecyclerView LinearLayoutManager decides whether the screen is off (so it can be a processor), it does not take into account the type of translationY .
So essentially, when I scroll up and I have views with positive translationY , LinearLayoutManager thinks the view is turned off, but in fact it is still visible (because it is downward).
I noticed that the LinearLayoutManager method makes this decision - it views getDecoratedBottom(View) , so I tried to override getDecoratedBottom(View) to enable translation. Unfortunately, he completely confused the layout - this method is also used when composing new elements, so new elements receive an additional translation (over the existing one).
Is there an easy way to tell LinearLayoutManager look at the translation attribute when it decides to view the recirculation without re-implementing the LayoutManager from scratch?
source share