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

Partially swiping then pressing on page control causes unintended behavior #201

Closed
babramovitch opened this issue Mar 6, 2017 · 2 comments
Labels

Comments

@babramovitch
Copy link

You can get unintended behavior in the following two scenarios

  1. Begin swiping a page left/right and without removing your swipe finger click on the bottom left/right of the page control. It will action the click and when you remove your swipe finger it stutters around.

  2. Press on the left/right of the bottom page control but don't remove your finger. Begin swiping and then remove your finger. It stutters around as well.

Not the biggest of issues, but we were worried about people unintentionally triggering the problem.

We solved it by removing/adding the selector when page scrolling begins. We tried disabling user interactions, but in scenario 2 you could still trigger the bug when you lifted your finger.

- (void)intro:(EAIntroView *)introView pageStartScrolling:(EAIntroPage *)page withIndex:(NSUInteger)pageIndex {
    [_intro.pageControl removeTarget:nil action:NULL forControlEvents:UIControlEventValueChanged];
}

- (void)intro:(EAIntroView *)introView pageEndScrolling:(EAIntroPage *)page withIndex:(NSUInteger)pageIndex {
    [_intro.pageControl addTarget:_intro action:@selector(showPanelAtPageControl) forControlEvents:UIControlEventValueChanged];
}
@ealeksandrov
Copy link
Owner

ealeksandrov commented Nov 11, 2017

Thanks, confirmed bug and your solution works well!
Adding it to the library.

@ealeksandrov
Copy link
Owner

ealeksandrov commented Nov 11, 2017

Actually I found way to prevent it without additional actions in UIScrollView delegate (which will fire on every scroll) - check out 3e62341.
Still thanks for your suggestion and bringing it to my attention :)

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

No branches or pull requests

2 participants