The header is not being added correctly after a configuration change (or any change that causes a layout pass for the StickyLayoutManager).
This can be fixed by disabling the logic in the StickyHeaderPositioner#reset method, but getting rid of that logic creates other issues, like the header still being sticky after that specific item has been removed from the dataset. It also can lead to an NPE in the layoutChildren method of the RecyclerView parent that is hosting the header (Header is removed after parent ViewGroup has counted it as a child). The StickyHeaderPositioner#safeDetachHeader method fixes that issue, but something else is causing the header to not show.
The header is not being added correctly after a configuration change (or any change that causes a layout pass for the StickyLayoutManager).
This can be fixed by disabling the logic in the
StickyHeaderPositioner#reset
method, but getting rid of that logic creates other issues, like the header still being sticky after that specific item has been removed from the dataset. It also can lead to an NPE in thelayoutChildren
method of the RecyclerView parent that is hosting the header (Header is removed after parent ViewGroup has counted it as a child). TheStickyHeaderPositioner#safeDetachHeader
method fixes that issue, but something else is causing the header to not show.