The example of this article describes the implementation of the animation mode of the Android programming ProgressBar custom style. Share to everyone for your reference, specific as follows:
Forget where to see the man wrote, is through the animation effect to achieve, now by the way also write out, I hope that the man don't take offense.
Effect:
As before, in the layout file:
<progressbar
android:id= "@+id/progressbar3"
android:layout_width= "wrap_content"
android:layout_ height= "Wrap_content"
android:indeterminate= "false"
Then build a Anim folder under values and put the progressbar_bar_loading file in:
<?xml version= "1.0" encoding= "UTF-8"?> <animation-list "xmlns:android=" /schemas.android.com/apk/res/android "android:oneshot=" false "> <item android:duration="-"-" Android: drawable= "@drawable/progress_bar_loading_01"/> <item android:duration= "android:drawable=" @drawabl E/progress_bar_loading_02 "/> <item android:duration=" "android:drawable=" @drawable/progress_bar_loa
Ding_03 "/> <item android:duration=" android:drawable= "@drawable/progress_bar_loading_04"/> <item android:duration= "android:drawable=" "@drawable/progress_bar_loading_05"/> <item Andr
oid:duration= "android:drawable=" "@drawable/progress_bar_loading_06"/> <item android:duration= "250" android:drawable= "@drawable/progress_bar_loading_07"/> </animation-list>
Those are all a picture, just like replacing a picture.
I hope this article will help you with the Android program.