FROM : Quincey Morris
DATE : Mon Mar 03 20:05:37 2008
On Mar 3, 2008, at 09:12, Daniel Child wrote:
> My bad. I should have checked that, and assumed it simply passed the
> address. If [self window] loads things, is there any way to obtain
> the window's address without loading it? I found it useful to assign
> a (superfluous) instance variable since I was doing so much with the
> window. I didn't want to have to use [self window] each time,
> especially if [self window] actually tries to load each time.
"Loading" a window means creating the NSWindow object by unarchiving
it from the nib file. The window object literally does not exist
before loading (and the window controller's private instance variable
is nil). To modify the window object from what's in the nib file, you
need to unarchive (load) it (which does not cause it to display),
change it, then display it with the changes in place.
DATE : Mon Mar 03 20:05:37 2008
On Mar 3, 2008, at 09:12, Daniel Child wrote:
> My bad. I should have checked that, and assumed it simply passed the
> address. If [self window] loads things, is there any way to obtain
> the window's address without loading it? I found it useful to assign
> a (superfluous) instance variable since I was doing so much with the
> window. I didn't want to have to use [self window] each time,
> especially if [self window] actually tries to load each time.
"Loading" a window means creating the NSWindow object by unarchiving
it from the nib file. The window object literally does not exist
before loading (and the window controller's private instance variable
is nil). To modify the window object from what's in the nib file, you
need to unarchive (load) it (which does not cause it to display),
change it, then display it with the changes in place.
| Related mails | Author | Date |
|---|---|---|
| Daniel Child | Feb 29, 06:04 | |
| Quincey Morris | Feb 29, 09:04 | |
| Ken Thomases | Mar 1, 12:15 | |
| Daniel Child | Mar 3, 18:12 | |
| Ken Thomases | Mar 3, 20:05 | |
| Quincey Morris | Mar 3, 20:05 | |
| Daniel Child | Mar 8, 04:38 | |
| Ken Thomases | Mar 8, 07:11 | |
| Daniel Child | Mar 12, 16:45 | |
| Ken Thomases | Mar 13, 00:54 |






Cocoa mail archive

