ExpandableListView.SetSelectedChild(Int32, Int32, Boolean) 方法

定义

将所选内容设置为指定的子级。

[Android.Runtime.Register("setSelectedChild", "(IIZ)Z", "GetSetSelectedChild_IIZHandler")]
public virtual bool SetSelectedChild (int groupPosition, int childPosition, bool shouldExpandGroup);
[<Android.Runtime.Register("setSelectedChild", "(IIZ)Z", "GetSetSelectedChild_IIZHandler")>]
abstract member SetSelectedChild : int * int * bool -> bool
override this.SetSelectedChild : int * int * bool -> bool

参数

groupPosition
Int32

包含子项的组的位置。

childPosition
Int32

子级在组中的位置。

shouldExpandGroup
Boolean

如果子组已折叠,是否应展开该子组。

返回

是否在子级上成功设置所选内容。

属性

注解

将所选内容设置为指定的子级。 如果子级位于折叠组中,则仅当 shouldExpandGroup 设置为 true 时,才会展开该组,并且随后选择该组,否则该方法将返回 false。

适用于 . 的 android.widget.ExpandableListView.setSelectedChild(int, int, boolean)Java 文档

本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。

适用于