自定义滚动视图类中的Expandablelistview

时间:2019-05-21 08:05:14

标签: android expandablelistview android-gridview android-scrollview android-4.2-jelly-bean

我有customized-scrollview类,该类允许我使用转子(类似于鼠标点击轮)向上/向下滚动,它扩展了scrollview,并且在其中有一个ExpandableListView,我需要滚动整个视图。

我经历了提供的一些解决方案,例如禁用滚动功能,使用过,尝试固定小部件(ELV)的高度,但是我的转子硬件无法滚动

<com.my.android.widget.CustomScrollView
    android:layout_width="wrap_content"
    android:layout_height="match_parent"
    android:id="@+id/encoder_exp_scroll">

    <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
              android:layout_width="match_parent"
              android:layout_height="match_parent"
              android:orientation="horizontal">

        <ExpandableListView
        android:id="@+id/list_of_controls"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:clipToPadding="false"
        android:groupIndicator="@null"
        android:footerDividersEnabled="false"
        android:headerDividersEnabled="false"
        android:divider="#00000000"
        android:childDivider="#00000000"
        android:descendantFocusability="afterDescendants"
        android:focusableInTouchMode="false"
        android:scrollbars="none"
        android:focusable="false"/>
    </LinearLayout>
</com.my.android.widget.CustomScrollView>

整个视图也应与触摸和旋转事件一起滚动。

0 个答案:

没有答案