I d like to know whether or not both viewDidUnload
and dealloc
are always called in succession in the UIViewController tear-down process. Is it possible that dealloc
could be called on my view controller without viewDidUnload
having been called first?
In either case, if I am safely releasing the properties and retained references in both methods it wouldn t be a problem if both methods were called -- but I was wondering if anyone knew for sure or could shed some light on the tear-down process.
2012 Update: It s handy to note that as if iOS 6 viewDidUnload
has been deprecated and should be replaced with manual view teardown if required in didReceiveMemoryWarning
.
A good article on the new UIView/UIViewContoller and the new behaviour and it s effects on the joe conway blog