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

moveToViewController does not change the page if created + not visible + animated = false until it become visible #746

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

bivant
Copy link

@bivant bivant commented Aug 13, 2019

Skip visibility check (view.window != nil) if non animated viewController change was requested.

User case: a ButtonBarPagerTabStripViewController is not navigationController.topViewController (but was visible so viewDidLoad had been called),
moveToViewController(at: 1, animated: false) was called prior to the screen show (popViewController)
Expected behavior: a controller is shown with selected tab on screen/controller show
Current behavior: a controller change animation starts after the navigation animation is completed.

…if the moveTo/moveToViewController was requested prior to the viewDidLoad() -> viewDidLayoutSubviews()
…ow (was always first one) if the moveTo/moveToViewController was requested prior to the viewDidLoad() -> viewDidLayoutSubviews()
Copy link

@sprite2005 sprite2005 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These changes will allow you to select the starting page.

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

Successfully merging this pull request may close these issues.

3 participants