MPFoldTransition icon indicating copy to clipboard operation
MPFoldTransition copied to clipboard

ViewDidLoad is calld after transition.

Open TheAppleWizz opened this issue 12 years ago • 4 comments

Hi, Thank you so much for your code but i have a little problem. The view loads its data after it shows up as a design point it doesn't look good. For example do you notice when you push or percent a view with apples transitions it waits a few seconds and then loads the view.

Thanks again, TheAppleWizz

TheAppleWizz avatar Feb 14 '13 18:02 TheAppleWizz

Could you be more specific about which methods you're using? When using presentViewController:foldStyle:completion: or presentViewController:flipStyle:completion:, viewDidLoad is called before the transition begins - that's easy to confirm.

mpospese avatar Feb 14 '13 19:02 mpospese

Hi, I also have the same problem. I want to present a modal view controller with a fold transition. The modal view controller is loaded from a storyboard and contains a UITableView. The table view gets populated after the transition finished, and the styles for the navigation bar and buttons using UIAppearance are applied after the transition as well. I put a few NSLog's in the code to see when certain methods like viewDidLoad get called, and you're right, they're all called before the transition ends.

What's the crux of the matter? Thanks in advance.

marcburkhardt avatar Feb 16 '13 19:02 marcburkhardt

Well, I could find a workaround for the problem, but I'm still not very happy with it. I put the following lines just before the -perform method:

[presentingController presentViewController:viewControllerToPresent animated:NO completion:nil];
[presentingController dismissViewControllerAnimated:NO completion:nil];

marcburkhardt avatar Feb 17 '13 21:02 marcburkhardt

When I have the chance I'll try it.

Thanks

TheAppleWizz avatar Feb 17 '13 23:02 TheAppleWizz