Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}dependencies {
implementation 'com.github.SudoAjay:LoadingAnimation-Android:v3.6'
} <com.sudoajay.lodinganimation.LoadingAnimation
android:id="@+id/loadingAnimation"
android:layout_width="0dp"
android:layout_height="0dp"/>If you want to modify or want some changes in loadingAnimation . So follow below properties to do it.
app:la_set_alpha="700"
app:la_set_color="@android:color/black"
app:la_set_reduce_alpha="18"
app:la_set_angle_point="0"
app:la_set_main_radius="80"
app:la_set_other_radius="20"
app:la_set_reduce_other_radius="1" final LoadingAnimation loadingAnimation = findViewById(R.id.loadingAnimation);
loadingAnimation.setColor(Color.BLACK); // default Black
loadingAnimation.setAlpha(700); // default 700
loadingAnimation.setReduceAlpha(18); // default 18
loadingAnimation.setAnglePoint(0); // default 0
loadingAnimation.setMainRadius(80); // default 80
loadingAnimation.setOtherRadius(20); // default 20
loadingAnimation.setReduceOtherRadius(1); // default 1
loadingAnimation.setTiming(1000);
// or
loadingAnimation.start();
loadingAnimation.stop();LoadingAnimation by Sudo Ajay v3.5
