Fragment doesn't respect match parent height when having listview row item has hidden view in it

坚强是说给别人听的谎言 提交于 2019-12-06 08:23:13
Santi Fri

Better upshot were targeted at plus for android developers (Cristophe Beils):

"Your ListView must have its height set to match_parent or a fixed size, not wrap_content.

If you need to add another view fixed at the bottom of the ListView as a footer, you need to put both the ListView and the footer View in a vertical LinearLayout and set layout_height to 0dp and layout_weight to 1 on the ListView so that it takes the remaining vertical space."

Try fillViewPort=true on the list view.. But not sure what why yoi have a scroll view inside a list view.. Could be the issue too.

Try setting match_parent as the height of the listview I suspect this will force the list view to have a defined height and fix your problem.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!