Android Custom ProgressBar not Rotating
On older devices it is a problem when android:fromDegrees
is bigger than android:toDegress
in <rotate>
. Try swapping the values:
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
android:drawable="@drawable/spinner_76_inner_holo"
android:fromDegrees="0"
android:pivotX="50%"
android:pivotY="50%"
android:toDegrees="720" />
Alternatively, you can try setting it as infinite:
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
android:drawable="@drawable/spinner_76_inner_holo"
android:pivotX="50%"
android:pivotY="50%"
android:repeatCount="infinite" />
The animation might be laggy on older devices. To fix this add android:animationResolution
to the style:
<style name="ProgressTheme" parent="@android:style/Widget.ProgressBar.Large">
<item name="android:indeterminateDrawable">@drawable/spinner_holo_light</item>
<item name="android:animationResolution">33</item>
</style>