Re: delegate method called before awakeFromNib?
Re: delegate method called before awakeFromNib?
- Subject: Re: delegate method called before awakeFromNib?
- From: Matt Neuburg <email@hidden>
- Date: Mon, 21 Aug 2006 23:09:33 -0700
- Thread-topic: delegate method called before awakeFromNib?
On Mon, 21 Aug 2006 17:21:12 -0400, Ivan Kourtev <email@hidden> said:
>Hi,
>
>I have some old code (developed under 10.3) that used to work in
>2004. Now in 10.4 I am experiencing a problem which I tracked down
>to a window receiving a delegate method (windowDidResize) before its
>awakeFromNib call. Because my window delegate is hardwired to the
>controller in IB, the delegate method gets handled right away. But
>because awakeFromNib has not been called yet, the internal program
>state is not set and so the program crashes.
I would just raise a flag in some delegate method whose position in the
startup sequence is secure, such as applicationDidFinishLaunching; until
that flag is up, your other delegate methods should just return, behaving as
no-ops. m.
--
matt neuburg, phd = email@hidden, <http://www.tidbits.com/matt/>
A fool + a tool + an autorelease pool = cool!
AppleScript: the Definitive Guide - Second Edition!
<http://www.amazon.com/gp/product/0596102119>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden