Ramotion/folding-cell-android

Update content view height

ykorshev opened this issue · 4 comments

I want to update content view height after performing some operations (adding some text or images). But height still stays fixed.

But calling foldingCell.contentView.requestLayout() does not do anything.

Where is the trick?

Please, help me.

I am also facing the same problem.. did you find any solution?

@ykorshev did you find any solution?

@ykorshev did you tried using
`addOnLayoutChangeListener()' ?

Hello, guys. To apply changes to height of your list items with folding cells, you should let your list (whether it recyclerview or listview) to know that there are changes in data of your items. It may be notifyDataSetChanged() for RecyclerView for example. Also be sure that you don't use hardcoded height for your list item in layout.xml.