布局中有多个Android展开式列表 [英] Multiple Android expandable lists in a layout

查看:105
本文介绍了布局中有多个Android展开式列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在一个布局中有多个可扩展列表.自定义布局中的可扩展列表似乎必须具有ID"@ id/android:list".因此,如果他们需要具有相同的ID,我怎么可能不止一个?谢谢...

I want to have more than one expandable list within a layout. It appears that an expandable list in a custom layout must have an id of "@id/android:list". So, how could I have more than one if they would need to have the same id? Thanks...

推荐答案

他们不必具有@id/android:list ID-仅当您使用ListActivityExpandableListActivity时,才需要具有该ID.只需使用普通的Activity并为其指定唯一的ID即可.

They don't have to have the @id/android:list ID - they only have to have that ID if you are using a ListActivity or ExpandableListActivity. Just use a normal Activity and give them unique IDs.

这篇关于布局中有多个Android展开式列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆