Re: windowDidLoad NOT being called?
Re: windowDidLoad NOT being called?
- Subject: Re: windowDidLoad NOT being called?
- From: Mark Dawson <email@hidden>
- Date: Mon, 25 Apr 2005 17:00:44 -0700
It also looks like the showWindow call loads it automatically. I was
just breaking too early (and need to postpone my update until later)…
mark
You need to use loadNibNamed: in NSBundle to load the nib, not just
create a controller class.
Bob
On Apr 26, 2005, at 12:19 AM, Mark Dawson wrote:
I'm creating my first preference window, and am missing some step.
My preference window's "windowDidLoad" isn't being called, and its
"window" variable is nil. I've connected my "fileOwner" to the
"window" outlet of the "window" icon. My nib file is called
"Preferences.nib". PreferencesWindowController's -init method IS
being called, just not its -windowDidLoad. I've titled the window
"Preferences".
- (IBAction)openPreferencesWindowAction:(id)sender
{
if (!mPrefWindowController) {
// Create a new preferences window controller if it does not
already exist.
mPrefWindowController = [[PreferencesWindowController alloc]
initWithWindowNibName:@"Preferences"];
}
<5> [mPrefWindowController updatePreferences];
[mPrefWindowController showWindow:sender];
}
Breaking at line <5> shows that the controller has been created, but
NOT its window (and all of the outlets in that window are still nil).
What am I missing? _______________________________________________
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
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
email@hidden
This email sent to email@hidden
_______________________________________________
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