rasoulmiri / Skeleton

Skeleton for Android
Apache License 2.0
325 stars 61 forks source link

Re-enabling skeleton loading #4

Open ghost opened 6 years ago

ghost commented 6 years ago

Is there a way to start the loading again after the initial animation? I would like to implement a swipe refresh layout. The isAnimationPlay field is not set to default after the animation finishes.

cuongnv219 commented 4 years ago

you can do like this gradientXmlAdapter.measureHeightRecyclerViewAndItem(recyclerView, R.layout.item_gradient_xml); gradientXmlAdapter.reloadSkeleton();

public void reloadSkeleton() { this.items.clear(); skeletonConfig.setSkeletonIsOn(true); notifyDataSetChanged(); }