Re: Collection of Cocoa & objc questions from a "newbie"
Re: Collection of Cocoa & objc questions from a "newbie"
- Subject: Re: Collection of Cocoa & objc questions from a "newbie"
- From: Art Isbell <email@hidden>
- Date: Wed, 18 Jul 2001 12:28:33 -1000
On Tuesday, July 17, 2001, at 11:53 PM, John C. Randolph wrote:
On Wednesday, July 18, 2001, at 02:43 AM, Art Isbell wrote:
It's easy to check for yourself. Just load a Cocoa app
into gdb, set breakpoints at NSWindowTemplate's initWithCoder:
and NSWindow's initWithCoder: and
initWithContentRect:styleMask:backing:defer:, and run it.
When the main window is loaded, execution should break first
at NSWindowTemplate's initWithCoder:, then at NSWindow's
initWithContentRect:styleMask:backing:defer:, but never at
NSWindow's initWithCoder:.
Let's see then... Doesn't that make [NSWindow initWithCoder:] a
noOp? If it's not called when taking a window out of a nib,
then when would it ever get used?
I guess somebody might do something pathological like pass a
window bycopy over a DO connection, but I've never seen it
done..
In the example I checked, NSWindow's initWithCoder: was
actually invoked. That confused me until I checked the
backtrace and noticed that this window was a small off-screen
window in which an image was drawn.
Art Isbell
Apple iServices Technical Support
http://www.apple.com/iservices/webobjectssupport/
+1-808-591-0836