ShamylZakariya / StickyHeaders

Adapter and LayoutManager for Android RecyclerView which enables sticky header positioning.
MIT License
1.4k stars 185 forks source link

Show section header when section is empty #84

Open imobiling opened 6 years ago

imobiling commented 6 years ago

When the section is empty, I'd like to show the section header so that user will be able to add data to the correct section.

Currently when the section is empty, nothing (no section or section header) is shown for the recycler view.

Is there any quick solution for this?

thanks a lot! Helen

imobiling commented 6 years ago

any update on this issue or any clarification needed?

imobiling commented 6 years ago

anyone can help fix this issue?

baiguangyuan commented 6 years ago

Did you override doesSectionHaveHeader function of SectioningAdapter.

/**
 * @param sectionIndex index of the section in question
 * @return true if this section has a header
 */
public boolean doesSectionHaveHeader(int sectionIndex) {
    return false;
}