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

didHide delegate reports wrong indexes #187

Closed
Mattijah opened this issue Oct 28, 2018 · 2 comments
Closed

didHide delegate reports wrong indexes #187

Mattijah opened this issue Oct 28, 2018 · 2 comments
Labels

Comments

@Mattijah
Copy link

Mattijah commented Oct 28, 2018

Description:
coachMarksController:didHide reports indexes from 1 not 0 as it correctly should. (willHide for instance does report indexes correctly).

Additional details:
Regarding the incorrect indexes I have also noticed that when starting flow from UIViewController:viewWillTransition(to) (which is triggered when orientation changes) coachMarkViewsAt delegate will either report -1 index (usually when changing from Landscape to Portrait) or double 0 indexes.

Workaround which helped is to run coachMarksController.start(on: self) inside DispatchQueue.main.async. Even though I did not inspect this bug into the detail I'm pretty sure it should run correctly even without this little "workaround".

Tested on:

  • 1.2.0
@ephread
Copy link
Owner

ephread commented Nov 8, 2018

Hey @Mattijah , thanks for reporting the issue! It's been known for some time, but I haven't had the chance to fix it yet.

@ephread ephread added the bug label Nov 8, 2018
@olmedocr
Copy link

olmedocr commented Dec 29, 2018

The Dispatch.async solution provided by @Mattijah also solves another problem that I don't know if its considered a related bug:

The function coachMarksController:willHide is executed after coachMarksController:coachMarkAt if coachMarksController.start(on: self) is executed outside the DispatchQueue.main.async. Is this intentional? If the answer is no, I'll be happy to open a separated issue.

Tonbouy pushed a commit to Tonbouy/Instructions that referenced this issue Nov 29, 2019
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

3 participants