Android动画效果的加载按钮:ProgressRoundButton

jopen 9年前

一个带有下载进度动画展示效果的按纽。

demo

Usage

step1

gradle

 dependencies {       compile fileTree(dir: 'libs', include: ['*.jar'])       compile 'com.android.support:appcompat-v7:23.0.1' compile 'com.xiaochendev.progressroundbtn:library:1.0.0' }

step2

you can define the button in xml like this:

<com.xiaochen.progressroundbutton.AnimDownloadProgressButton          android:id="@+id/anim_btn"          android:layout_width="match_parent"          android:layout_height="40dp"          app:progressbtn_backgroud_color="@android:color/holo_orange_light"          app:progressbtn_backgroud_second_color="@android:color/holo_green_light"/>

the Customized properties are in the follow table: git

Property Format Default
progressbtn_radius float half of the button height
progressbtn_backgroud_color color #6699ff
progressbtn_backgroud_second_color color Color.LTGRAY
progressbtn_text_color color progressbtn_backgroud_color
progressbtn_text_covercolor color Color.WHITE

The follow picture make a clear explanation:

show

项目主页:http://www.open-open.com/lib/view/home/1446797944248