ybq / android-spinkit Goto Github PK
View Code? Open in Web Editor NEWAndroid loading animations
Home Page: https://ybq.github.io/Android-SpinKit
License: MIT License
Android loading animations
Home Page: https://ybq.github.io/Android-SpinKit
License: MIT License
Goodday.
Using the Wave sprite on Android N and the animation is paused sometimes when the screen goes dark.
It can be fixed by repeating the process i.e. turning off the screen and turning it on again.
I tried minSdkVersion 14/21/25 in module:app build.gradle, but I got same error
/Users/xxx/.gradle/caches/transforms-1/files-1.1/Android-SpinKit-1.1.0.aar/22ef2a52320a448431a0e9bdde5e50fc/res/values/values.xml
Error:(5, 5) error: style attribute 'attr/textSize (aka com.bytedance.ee.bear.list.test:attr/textSize)' not found.
Hello, Thank you for these awesome Spin Kits.
I was using Wave. But this is not animating as the wave.
Please take a look at this screenshot. https://ibb.co/jR6Mpo
My XML:
<com.github.ybq.android.spinkit.SpinKitView android:id="@+id/progressBar" style="@style/SpinKitView.Wave" xmlns:app="http://schemas.android.com/apk/res-auto" app:SpinKit_Color="@color/red" app:SpinKit_Style="Wave" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_below="@+id/inputsearchenglishhome" android:layout_marginTop="65dp" android:visibility="visible" />
My Java:
private ProgressBar progressBar; progressBar = (ProgressBar) rootView.findViewById(R.id.progressBar); Wave wave = new Wave(); progressBar.setIndeterminateDrawable(wave);
设置view 在dialog中,其中RotatingPlane,Pulse,RotatingCircle,Pulse_Ring这几种style不能显示,其它的style都可以显示。
`
View view = LayoutInflater.from(context).inflate(R.layout.loading_dialog, null);
TextView loadingText = (TextView) view.findViewById(R.id.loading_dialog_text);
SpinKitView spinKitView = (SpinKitView) view.findViewById(R.id.spin_kit);
Style style = Style.values()[position];
Sprite drawable = SpriteFactory.create(style);
loadingText.setText(msg);
final Dialog mLoadingDialog = new Dialog(context, R.style.loading_dialog_style);
mLoadingDialog.setCancelable(false);
mLoadingDialog.setContentView(view, new LinearLayout.LayoutParams(LinearLayout.LayoutParams.MATCH_PARENT,
LinearLayout.LayoutParams.MATCH_PARENT));
`
Please release new build to include commit 1af45a2
Regards,
Pedro Cardoso
Set color via XML "app:SpinKit_Color="@color/colorAccent"" does not work on the following drawables:
For the above drawables, color defaults to white and setting color does not work.
Set color via XML works for the following drawables:
References Issue #24
Hello,
Is there a way i can get the progress drawable w/ animation and use it along with the default ProgressDialog?
Would be great help !
Thanks!
type with rotatingcircle output like rotatingplane
this is not working on Android 7, API 25
在list页面复用(应该是重复setIndeterminateDrawable)SpinKitView时出现显示空白的现象。
如果是在xml里面指定好了Sprite(没有在代码里面重复setIndeterminateDrawable)则不会出现这样的问题
You need to use a Theme.AppCompat theme (or descendant) with this activity. wh?,thank you!
gradle cannot find this lib
@Override public void onPageSelected(int position) { getWindow().getDecorView().setBackgroundColor(colors[position % colors.length]); }
in DetialActivity of the sample can be omitted, because you've got the ArgbEvaluator working fine:). If not doing so, this line will take effect immediately after tapping up, which causes an unfriendly flash...You know.
Hi! First, excelent work
But I've a problem, the image don't fill the view correctly
The code:
<com.github.ybq.android.spinkit.SpinKitView
android:id="@+id/spin_kit"
style="@style/SpinKitView.Large.FoldingCube"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center"
app:SpinKit_Color="@android:color/white" />
Hugs
'Could not get resource 'https://repo.maven.apache.org/maven2/com/github/ybq/Android-SpinKit/1.1.0/Android-SpinKit-1.1.0.pom'
使用Gradle引用库的时候 maven 调不通
I have to set SpinKit_Color only by xml file, but it doesn't work for all progressdrawable.
In particular, i have seen the problem in "setIndeterminateDrawable" method, where
if(this.mSprite.getColor() == 0) {
this.mSprite.setColor(this.mColor);
}
and so, for some drawable, the color doesn't change
Can you add the loading circle (that is located at bottom right corner of this page
I got compilation error in my project because I have defined supportRtl
in my AndroidManifest.xml, which is also defined in SpinKit's AndroidManifest.xml. I have to use tools:replace="android:supportsRtl"
as a workaround but I think it is even better if SpinKit library can remove these unnecessary fields or files.
Hey Friends,
I can not use your kit,
Is that gradle dependence right? I really can not find it,
Thanks~
Animations don't start on Galaxy Tab A with Android 5.1.1.
I tried Wave and the animation doesn't start.
Tried Circle and nothing is shown.
I found that https://jitpack.io/com/github/ybq/Android-SpinKit/1.1.0/build.log show build failed
I know the latest version of Android-SpinKit is V1.2.0 But react-native-spinkit used Android-SpinKit 1.1.0 I have an old react native project which used react-native-spinkit and now it returns an error when compiling it:
Could not find com.github.ybq:Android-SpinKit:1.1.0.
Searched in the following locations:
https://jitpack.io/com/github/ybq/Android-SpinKit/1.1.0/Android-SpinKit-1.1.0.pom
Could you rebuild Android-SpinKit 1.1.0 and upload to https://jitpack.io/com/github/ybq/Android-SpinKit/1.1.0
Thank you very much!
The README's Preview section display a Button with a waved SpinKit within.
Hi, without any attribution or licence Can I use directly this library in my Android App?
How do I use this progress bar/spinkit in webview
not working while using swipe refresh layout .actually it's not showing the progress
Android stops any kind of animations in battery saver mode in Android 7+
When my phone is in battery saver mode, i dont see anything in the view. It should atleast show a static 3 balls for ThreeBounce animation. Similarly for other animations too.
when I use the dependence like this:
ext {
buildToolsVersion = "28.0.3"
minSdkVersion = 16
compileSdkVersion = 28
targetSdkVersion = 27
supportLibVersion = "28.0.0"
}
the project can`t build success.
here is the error from logcat
:app:processDebugResources FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:processDebugResources'.
> Error: more than one library with package name 'android.support.graphics.drawable'
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 1.954 secs
I tried to use spinkit version 1.2.0 on my android studio 3.1. I used
implementation 'com.github.ybq:AndroidSpinKit:1.2.0'
It gives me a failed to resolve error. Error message in the gradle build as follows
Failed to resolve: com.github.ybq:AndroidSpinKit:1.2.0
Crashing while building with the following error message: "More than one file was found with OS independent path 'lib/armeabi-v7a/libvpnprocessing.so'
"
Compile SDK Version: API 27 - Andoid Oreo 8.1
Gradle version: 4.10.1
Android Plugin Version: 3.3.0
Android Studio 3.3
Thank you
Hi when the loader is displayed , the whole screen is in white color, how do i remove that color and my app screen should be visible in background.
Please help thanks in advance.
build.gradle :
allprojects {
repositories {
mavenLocal()
google()
jcenter()
maven {
// All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
url "$rootDir/../node_modules/react-native/android"
}
maven { url "https://jitpack.io" }
}
}
I tried everything and same issues but I had to open the issue.
Great library.
Trying to change color dynamically, but it view just disappears. For example, initially creating a Circle ProgressBar and setting its color to white. Then using button (e.g. btnRed and btnBlue) want to change the color. How should this properly be done??
Thanks
I am using the wave for my progress dialog but having trouble changing the color of it. I'm pretty sure this is just a personal shortcoming but I was hoping I could get some help! Thank you
jitpack上的value值还是错误的,我看到源代码已经修复了。
Hi
please add a feature to some of the progress so we can add brand logo or any drawables!
ty!
Hey @ybq ,
I have some minor bug fixes and I would like to contribute to this repository.
Please add me as a contributor so I can commit the code.
P.S: Thanks for this awesome repository.
Hi there,
Dont show animation on the Android 4.3 API 18 (Samsung Galaxy S3)
styles.xml
`
<style name="MyTheme" parent="Theme.AppCompat.Light.NoActionBar">
<item name="colorPrimary">#ffffff</item>
<item name="colorPrimaryDark">#FF581C0D</item>
<item name="colorAccent">#ffffff</item>
<item name="homeAsUpIndicator">@drawable/ic_home_white_24dp</item>
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
</style>
<style name="AppBarOverlay" parent="ThemeOverlay.AppCompat.Dark.ActionBar" />
<style name="PopupOverlay" parent="ThemeOverlay.AppCompat.Light" />
`
in layout.xml
<com.github.ybq.android.spinkit.SpinKitView xmlns:app="http://schemas.android.com/apk/res-auto" android:id="@+id/spin_kit2" style="@style/SpinKitView.Large.ThreeBounce" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center" app:SpinKit_Color="#ffffff" android:layout_alignParentBottom="true" android:layout_marginBottom="30dp" android:layout_centerInParent="true" />
failed to resolve compile 'com.github.ybq:Android-SpinKit:1.0.4'
Using this in my XML it leaves the margin at the bottom of the screen even though I have not set any margin.
What might be the problem?
`<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@drawable/app_bg"
tools:context="com..mobile.abc.SplashActivity">
<ImageView
android:id="@+id/sample_text"
android:layout_width="250dp"
android:layout_height="70dp"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="150dp"
android:background="@drawable/splash_text"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/imageView2"
android:layout_width="216dp"
android:layout_height="248dp"
android:layout_marginEnd="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="30dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/sample_text"
app:srcCompat="@drawable/app_icon" />
<com.github.ybq.android.spinkit.SpinKitView xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/loader"
style="@style/SpinKitView.Large.Wave"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_gravity="right"
app:SpinKit_Color="@color/colorAccent" />
</android.support.constraint.ConstraintLayout>
`
Crash on my app
"main" tid=1 Runnable
"main" prio=5 tid=1 Runnable
| group="main" sCount=0 dsCount=0 obj=0x7465d9c0 self=0xb7d3b290
| sysTid=18206 nice=-4 cgrp=default sched=0/0 handle=0xb6f65c00
| state=R schedstat=( 0 0 0 ) utm=341 stm=115 core=1 HZ=100
| stack=0xbe5b5000-0xbe5b7000 stackSize=8MB
| held mutexes= "mutator lock"(shared held)
at com.github.ybq.android.spinkit.b.f.d (Sprite.java:127)
at com.github.ybq.android.spinkit.b.f.c (Sprite.java:117)
at com.github.ybq.android.spinkit.b.f$2.a (Sprite.java:434)
at com.github.ybq.android.spinkit.b.f$2.a (Sprite.java:431)
at com.github.ybq.android.spinkit.a.b.a (FloatProperty.java:43)
at com.github.ybq.android.spinkit.a.b.set (FloatProperty.java:29)
at android.animation.PropertyValuesHolder$FloatPropertyValuesHolder.setAnimatedValue (PropertyValuesHolder.java:1292)
at android.animation.ObjectAnimator.animateValue (ObjectAnimator.java:988)
at android.animation.ValueAnimator.animationFrame (ValueAnimator.java:1384)
at android.animation.ValueAnimator.doAnimationFrame (ValueAnimator.java:1427)
at android.animation.ValueAnimator$AnimationHandler.doAnimationFrame (ValueAnimator.java:759)
at android.animation.ValueAnimator$AnimationHandler$1.run (ValueAnimator.java:801)
at android.view.Choreographer$CallbackRecord.run (Choreographer.java:858)
at android.view.Choreographer.doCallbacks (Choreographer.java:670)
at android.view.Choreographer.doFrame (Choreographer.java:603)
at android.view.Choreographer$FrameDisplayEventReceiver.run (Choreographer.java:844)
at android.os.Handler.handleCallback (Handler.java:739)
at android.os.Handler.dispatchMessage (Handler.java:95)
at android.os.Looper.loop (Looper.java:148)
at android.app.ActivityThread.main (ActivityThread.java:5452)
at java.lang.reflect.Method.invoke! (Native method)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:762)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:652)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.