• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
-viewDidUnload not always called?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

-viewDidUnload not always called?


  • Subject: -viewDidUnload not always called?
  • From: Rick Mann <email@hidden>
  • Date: Wed, 12 Oct 2011 15:39:35 -0700

I've got a fairly simple iOS 4 app, built from the Utility Application stationery. I've noticed that the FlipsideVeiwController's -viewDidUnload method is not called when that view controller is dismissed/dealloced (even though -dealloc is).

I can't tell from the docs for -viewDidUnload if it is not guaranteed to be called when cleaning up. It does say that it's called for low-memory situations, but also says it's called as a counterpart to -viewDidLoad, which is always called when a view controller is created.

The question I have, then: if viewDidUnload is not called when a VC is being released, is it guaranteed that it will never be called when a VC is being released? I may need to do cleanup in -viewDidUnload that can't be done twice (for example, removing a KVO).

I'm observing this behavior in the simulator, iOS 4.3.

--
Rick

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: -viewDidUnload not always called?
      • From: Fritz Anderson <email@hidden>
  • Prev by Date: Re: Locking an object's location to the scroll view (not the document)
  • Next by Date: Re: Locking an object's location to the scroll view (not the document)
  • Previous by thread: Re: Select model objects with NSTableView using cocoa bindings
  • Next by thread: Re: -viewDidUnload not always called?
  • Index(es):
    • Date
    • Thread