I have an image that is set to rotate in my application. The code works perfectly on all Android versions except for the latest Ice Cream Sandwich. The image still rotates, but it is not rotating from the center axis of the image. Instead, it seems to rotate from the left corner (0,0) of the image. Does anyone have any ideas as to why this does not work in Ice Cream Sandwich? Here is my code:
rotator.xml:
<rotate xmlns:android="http://schemas.android.com/apk/res/android"
android:duration="1200"
android:fromDegrees="0"
android:pivotX="50%"
android:pivotY="50%"
android:repeatCount="infinite"
android:toDegrees="360" />
animation.java:
status.setImageResource(R.drawable.pending);
status.startAnimation(AnimationUtils.loadAnimation(_context, R.anim.rotator));
Thanks!
It seems that the answer to this question Android Toast notification is too small in Ice Cream Sandwich also solved my spinner problem.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With