【问题标题】:ExpandableListView. Expand and go to specific group可扩展列表视图。展开并转到特定组
【发布时间】:2014-02-14 17:31:09
【问题描述】:

如何展开特定的 ExpandableListView 组并转到该组?

我试过了:

ExpandableListView mListView;
mListView.expandGroup(13);

它扩展了第 13 组。但它不在屏幕上。我想直接转到该组,以便它出现在屏幕顶部。问候

【问题讨论】:

    标签: android listview expandablelistview


    【解决方案1】:

    在可展开列表视图的 xml 中,

    android:transcriptMode="alwaysScroll"
    android:transcriptMode="disabled"
    

    然后使用

    setSelectedPositionFromTop(int, int)
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-03-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多