动态调整 LinearLayout 内的可扩展列表视图的大小
我在 LinearLayout 内部有一个可扩展列表视图,周围有其他小部件和内容。
我试图弄清楚是否有一种方法可以更改layoutHeight,以便能够匹配expandableListView的大小,其可见内容的变化以及父级的扩展和收缩。
wrap_content 似乎在布局文件中不起作用。有没有办法在运行时做到这一点?
I have a expandableListView inside of linearLayout with other widgets and content surrounding it.
I'm trying to figure out if there is a way to change the layoutHeight to be able to match the size of the expandableListView its visible content changes and parents are expanded and contracted.
wrap_content doesn't seem to work in the layout file. Is there a way to do it at runtime?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
相对布局可能反应更好。
A relative layout may respond better.