Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to change color of arrow of expandableListView? [closed]

How to change the color of the drop-down arrow of an expandable ListView?

It would be better to just change color with, so animation isn't lost.

like image 530
Alex.Marynovskyi Avatar asked Aug 27 '15 16:08

Alex.Marynovskyi


1 Answers

Unfortunately everything I've seen says that you need to use a custom drawable, like so

<ExpandableListView 
    android:id="@+id/expandableList"
    android:layout_width="fill_parent" 
    android:layout_height="fill_parent"
    android:groupIndicator="@drawable/custom_expandable" />

Then in custom_expandable.xml

<selector xmlns:android="http://schemas.android.com/apk/res/android">
    <item android:drawable="@drawable/up_arrow" 
        android:state_empty="true" />
    <item android:drawable="@drawable/down_arrow" 
        android:state_expanded="true" />
</selector>
like image 147
Andrew Brooke Avatar answered Sep 21 '22 00:09

Andrew Brooke