over 9 years ago
To give imageview / button vibrate animation, need to follow these steps.
- <!--?xml version="1.0" encoding="utf-8"?-->
- <rotate xmlns:android="http://schemas.android.com/apk/res/android"
- android:duration="100"
- android:fromdegrees="-5"
- android:pivotx="50%"
- android:pivoty="50%"
- android:repeatcount="5"
- android:repeatmode="reverse"
- </rotate>android:toDegrees="5" />
<!--?xml version="1.0" encoding="utf-8"?--> <rotate xmlns:android="http://schemas.android.com/apk/res/android" android:duration="100" android:fromdegrees="-5" android:pivotx="50%" android:pivoty="50%" android:repeatcount="5" android:repeatmode="reverse" </rotate>android:toDegrees="5" />
2.Onclick of Button/Image, give animation to it.
Hope, it will help you.
0 Comment(s)