Skip to content

Instantly share code, notes, and snippets.

@NotWoods
Created August 19, 2019 16:42
Show Gist options
  • Save NotWoods/a566ac4c9f9bbf6a34058ae4fb9ea3fb to your computer and use it in GitHub Desktop.
Save NotWoods/a566ac4c9f9bbf6a34058ae4fb9ea3fb to your computer and use it in GitHub Desktop.
<animated-selector xmlns:android="http://schemas.android.com/apk/res/android">
<item
android:id="@+id/enabled"
android:drawable="@drawable/ic_protection_enabled"
android:state_enabled="true" />
<item
android:id="@+id/disabled"
android:drawable="@drawable/ic_protection_disabled" />
<transition
android:drawable="@drawable/ic_protection_disabled_to_enabled"
android:fromId="@id/disabled"
android:toId="@id/enabled" />
<transition
android:drawable="@drawable/ic_protection_enabled_to_disabled"
android:fromId="@+id/enabled"
android:toId="@+id/disabled" />
</animated-selector>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment