All Projects → StevenDXC → Dxloadingbutton

StevenDXC / Dxloadingbutton

Licence: apache-2.0
Android material button with loading animation

Programming Languages

java
68154 projects - #9 most used programming language
kotlin
9241 projects

Projects that are alternatives of or similar to Dxloadingbutton

Primedatepicker
PrimeDatePicker is a tool that provides picking a single day, multiple days, and a range of days.
Stars: ✭ 292 (-12.57%)
Mutual labels:  material-design
Material Components Vue
Material Design styled components for Vue.js
Stars: ✭ 316 (-5.39%)
Mutual labels:  material-design
Quasar
Quasar Framework - Build high-performance VueJS user interfaces in record time
Stars: ✭ 20,090 (+5914.97%)
Mutual labels:  material-design
Vue2.0lol
🌹 🌹 vue2.0版英雄联盟助手
Stars: ✭ 299 (-10.48%)
Mutual labels:  material-design
Hexo Theme Matery
A beautiful hexo blog theme with material design and responsive design.一个基于材料设计和响应式设计而成的全面、美观的Hexo主题。国内访问:http://blinkfox.com
Stars: ✭ 3,907 (+1069.76%)
Mutual labels:  material-design
Ngx Materialize
Angular wrap around Materialize library
Stars: ✭ 322 (-3.59%)
Mutual labels:  material-design
Popular Movies App
A simple Android app, that helps user to discover movies. Project 1 & 2 of Udacity Android Developer Nanodegree.
Stars: ✭ 293 (-12.28%)
Mutual labels:  material-design
Expenso
📊 A Minimal Expense Tracker App built to demonstrate the use of modern android architecture component with MVVM Architecture
Stars: ✭ 325 (-2.69%)
Mutual labels:  material-design
Qksms
The most beautiful SMS messenger for Android
Stars: ✭ 3,519 (+953.59%)
Mutual labels:  material-design
Material
Material design for AngularJS
Stars: ✭ 16,744 (+4913.17%)
Mutual labels:  material-design
Toolbar Button
FAB to Toolbar Button library for Android Material Collapsing Toolbar
Stars: ✭ 299 (-10.48%)
Mutual labels:  material-design
Appcompat Extension Library
A library that builds on the AppCompat Design Library and provides additional common components such as AccountHeaderView, FloatingActionMenu, CircleImageView, Picker Dialogs, FlexibleToolbarLayout, Delightful Detail Drawables and TypefaceCompat.
Stars: ✭ 307 (-8.08%)
Mutual labels:  material-design
Moviehub
Showcases popular movies, tv shows, and people from The Movie Database
Stars: ✭ 325 (-2.69%)
Mutual labels:  material-design
Breadcrumbsview
Material Design Breadcrumbs Navigation Widget on Android
Stars: ✭ 296 (-11.38%)
Mutual labels:  material-design
React Native Material Menu
Pure JavaScript material menu component for React Native
Stars: ✭ 327 (-2.1%)
Mutual labels:  material-design
Crazydaily
[开源项目] 一款程序员日常放松的App,基于Material Design + MVP-Clean + Weex + Flutter + RxJava2 + Retrofit + Dagger2 + Glide + Okhttp + MTRVA + BRVAH + 炫酷控件 + 炫酷动画
Stars: ✭ 294 (-11.98%)
Mutual labels:  material-design
Android Login
Stars: ✭ 317 (-5.09%)
Mutual labels:  material-design
Uplift
A playground for elevation on Android
Stars: ✭ 332 (-0.6%)
Mutual labels:  material-design
Android Movies App
Stars: ✭ 329 (-1.5%)
Mutual labels:  material-design
Zoonavigator
Web-based ZooKeeper UI / editor / browser
Stars: ✭ 326 (-2.4%)
Mutual labels:  material-design

DxLoadingButton

android button to loading view with animation,and load successful/failed animation

API Codacy Badge

Demo:

image

with activity transition animation demo:

image

Usage:

layout:

<com.dx.dxloadingbutton.lib.LoadingButton
     android:id="@+id/loading_btn"
     android:layout_gravity="center"
     android:layout_width="228dp"
     android:layout_height="wrap_content"
     app:lb_resetAfterFailed="true"
     app:lb_btnRippleColor="#000000"
     app:lb_btnDisabledColor="#cccccc"
     app:lb_disabledTextColor="#999999"
     app:lb_cornerRadius="32"
     app:lb_rippleEnable="true"					  
     app:lb_btnText="@string/button_text"
/>

code:

LoadingButton lb = (LoadingButton)findViewById(R.id.loading_btn);
lb.setOnClickListener(new View.OnClickListener() {
            @Override
            public void onClick(View view) {
                lb.startLoading(); //start loading 
            }
});

show successful animation:

 lb.loadingSuccessful();

show failed animation:

 lb.loadingFailed();

cancel loading:

 lb.cancelLoading();

reset:

 lb.reset();

enable:

 lb.setEnable(true/false); 
  • notice: lb_btnDisabledColor & lb_disabledTextColor only display while LoadingButton is normal button state, LoadingButton is playing animation or other state will display normal color

image

backgroundShader:

lb.setBackgroundShader(new LinearGradient(0f,0f,1000f,100f, 0xAAE53935, 0xAAFF5722, Shader.TileMode.CLAMP));

cornerRadius:

lb.setCornerRadius(32f)

dependency

Add it in your root build.gradle at the end of repositories:

allprojects {
    repositories {
	...
	maven { url 'https://jitpack.io' }
    }
}

add dependency:

dependencies {
    compile 'com.github.StevenDXC:DxLoadingButton:2.4'
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].