Observing "parentViewController" to run code blocks is unreliable #318

Closed
robertjpayne opened this Issue Mar 29, 2013 · 2 comments

Comments

Projects
None yet
2 participants
@robertjpayne

Inside the setController:forSlide you add an observer for "parentViewController" to run some final code.

This is unreliable because if IIViewDeckController is assigned to the rootViewController property of a window it will never fire as it is always nil.

@Inferis

This comment has been minimized.

Show comment Hide comment
@Inferis

Inferis Mar 29, 2013

Collaborator

No really a problem since the blocks will be run anyway when viewWillAppear is called. Whichever comes first runs the blocks.

I've modified the code a bit to unobserve the parentViewController in finishTransitionBlocks.

Collaborator

Inferis commented Mar 29, 2013

No really a problem since the blocks will be run anyway when viewWillAppear is called. Whichever comes first runs the blocks.

I've modified the code a bit to unobserve the parentViewController in finishTransitionBlocks.

@Inferis Inferis closed this Mar 29, 2013

@robertjpayne

This comment has been minimized.

Show comment Hide comment
@robertjpayne

robertjpayne Mar 29, 2013

Didn't realize they would fire on viewWillAppear but good to clean up the observers!

Didn't realize they would fire on viewWillAppear but good to clean up the observers!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment