Le 8 juil. 2010 à 19:34, Kyle Sluder a écrit :

>> Because I retain it in the init method , I don't need a reference to it
>> where the alloc is called
> 
> Retaining self in -init is wrong. It doesn't matter if it works.

You can retain your controller in -windowDidLoad and (auto)release it in 
-windowWillClose. That's what I usually do for non-modal windows. For modal 
window, the problem is even more simple.

Vincent_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to