devunwired / recyclerview-playground

Examples of RecyclerView use and custom LayoutManager implementations
MIT License
1.25k stars 270 forks source link

dynamically added children #27

Open wassy92x opened 8 years ago

wassy92x commented 8 years ago

Unfortunately the FixedGridLayoutManager doesn't work correctly if I try to inflate dynamical children in onBindViewHolder. I have an RecyclerView where every cell exists of another RecyclerView. The height of the cells is always zero respectively the minimum height.

I already tried to replace the child-RecyclerView with a LinearLayout and add to this the children. But this doesn't help.

unbenannt2

dsiddiqui489 commented 8 years ago

Can you share your code? I don't think RecyclerView was designed to inflate anything in onBindViewHolder()