本文介绍了在组上方扩展Android的ExpandableListView子级的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

ExpandableListView实现的默认行为是在单击时将组的子级扩展到该组之下.

The default behavior of the ExpandableListView implementation is to expand a group's children below the group when clicked.

我想知道是否有可能通过修改ExpandableListView XML属性或以编程方式以某种方式更改此行为以便在组上方(单击时)生成子级.

I'm wondering if it is possible to alter this behavior in order to generate the children above the group (when clicked) by modifying an ExpandableListView XML attribute or programmatically somehow.

推荐答案

我最终完成了此功能集,方法是制作一个普通的ListView并添加一些onClickListeners以显示/隐藏RelativeLayout中包含的LinearLayout.

I ended up accomplishing this feature set by making a normal ListView and adding a some onClickListeners to show/hide a LinearLayout contained within a RelativeLayout.

这篇关于在组上方扩展Android的ExpandableListView子级的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

06-03 17:07