SwipeActionAdapter icon indicating copy to clipboard operation
SwipeActionAdapter copied to clipboard

Lag Animations

Open FayaX-PT opened this issue 10 years ago • 9 comments

Hello. When i use a normal layout, with just a background color my animation is very smooth, but when i add one imageview to the layout i have a animation with lag.

FayaX-PT avatar Nov 21 '15 03:11 FayaX-PT

Are you sure you are using the latest version of the library?

If after doing a build clean, you are still experiencing this, can you show a gif or video of what's wrong? Also which version of android are you using and are you experiencing this on an actual device or in the emulator?

wdullaer avatar Nov 22 '15 10:11 wdullaer

I am using last version and Android 6.0 in a real de vice. I already tested in other real device and the result was the same. Later I will post a gif :)

FayaX-PT avatar Nov 22 '15 12:11 FayaX-PT

Can you also try the last version before 2.0.0? I changed how the library invalidates views when animating.

wdullaer avatar Nov 22 '15 12:11 wdullaer

Already tested the last version before 2.0.0 :D

FayaX-PT avatar Nov 22 '15 12:11 FayaX-PT

The animation lag just occurs when is to dismiss

mygif 1

FayaX-PT avatar Nov 22 '15 15:11 FayaX-PT

I see what you mean, but I don't think there's much I can do here. The animation is done via an android ValueAnimator. Maybe it'll be more smooth if I use a ViewProperty animator with scale rather than the height attribute. I'll give it a shot.

I never really noticed this lag, and to be honest I thought the glitch was much worse when I read your post.

wdullaer avatar Nov 22 '15 17:11 wdullaer

I will appreciate that :)

FayaX-PT avatar Nov 22 '15 19:11 FayaX-PT

Can you please tell me how to implement animation with delete image and swipe I am able to get the swipe action it works great but need to add a delete image just like gmail without movement.

avarunroyal avatar Mar 23 '16 10:03 avarunroyal

@avarunroyal Can you create a new ticket rather than hijack this one? I'm also not entirely sure I understand your request. You can use setFixedBackgrounds(true) to keep the swipebackgrounds static. As always: try out the sample app, read the docs and mess around a bit.

wdullaer avatar Mar 23 '16 18:03 wdullaer