• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag
 

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Window load delegate function?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Window load delegate function?


  • Subject: Re: Window load delegate function?
  • From: Vince DeMarco <email@hidden>
  • Date: Sat, 17 Nov 2001 12:47:44 -0800

On Saturday, November 17, 2001, at 07:40 am, Brian Luft wrote:

Those don't do what I want. I can't figure out what windowDidExpose does,
it never seems to get called. The other two seem to get called *every time* the window gets focus. That's not what I want. I need one that's called *only* the very first time the window is loaded and displayed on the screen. awakeFromNib is too early.


I don't think windowDidExpose: is connected, if you are using a NSWindwController, just over-ride the showWindow: method (be sure to call [super showWindow:blahbah]
and do what you want.

you could also over-ride the


- (void)windowDidLoad;
- (void)windowWillLoad;

and set some variable so you know that you can make sure that you do what you want only once.

vince

Thanks. Brian

On Friday, November 16, 2001, at 10:33 PM, Enigmarelle Development wrote:

They're hidden away in the NSWindow documentation -

- (void)windowDidBecomeMain:(NSNotification *)aNotification
- (void)windowDidBecomeKey:(NSNotification *)aNotification
- (void)windowDidExpose:(NSNotification *)aNotification

Also look at awakeFromNib in NSNibLoading.h

-john

On Friday, November 16, 2001, at 07:27 PM, Brian Luft wrote:

I'm looking for the event or delegate function or whatever that gets called when a window is first displayed on the screen. What is it? I'
ve looked through the docs and Googled for it, but I can't find anything.

Thanks. Brian
---
Brian Luft
email@hidden
http://youma.cjb.net
_______________________________________________
cocoa-dev mailing list
email@hidden
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
_______________________________________________
cocoa-dev mailing list
email@hidden
http://www.lists.apple.com/mailman/listinfo/cocoa-dev


References: 
 >Re: Window load delegate function? (From: Brian Luft <email@hidden>)

  • Prev by Date: Re: IB Palette with a Window
  • Next by Date: Re: Standard OS X Compression format
  • Previous by thread: Re: Window load delegate function?
  • Next by thread: [ANN] MarshmallowLibrarian Public Beta 4
  • Index(es):
    • Date
    • Thread