Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No way to stop animations #57

Open
veerenmandalia opened this issue Jan 4, 2017 · 1 comment
Open

No way to stop animations #57

veerenmandalia opened this issue Jan 4, 2017 · 1 comment

Comments

@veerenmandalia
Copy link

There is no way to stop swipe animations from running. Looks like SwipeActionTouchListener controls animations and only starts them, never stopping them.

Example use case:

  1. User starts swiping, animation starts
  2. User minimizes screen (onPause occurs), animation continues
  3. Animation finishes while screen is minimized

When onPause is called, clients should be able to stop all animations (standard practice). 2 issues arise:

  1. Animations continues when user is not on the screen (unnecessary performance hit)
  2. The listener fires when the app does not care about the result

I have removed the listener in onPause so that callbacks won't be executed (solves 2), however, it would be great to be able to stop the animations from running.

@wdullaer
Copy link
Owner

I understand where you're coming from, but the animations are really short. You have to try really hard to hit any of these cases and even the the user only loses the opportunity to cancel his action.

You can also hit the alternative case: user swipes, and hits home (or whatever other action that causes onPause to run). His action will never execute, even though he saw the animation trigger.
I'm not sure which one of these is preferable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants