• 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: New Document Behavior
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: New Document Behavior


  • Subject: Re: New Document Behavior
  • From: "Erik M. Buck" <email@hidden>
  • Date: Mon, 11 Oct 2004 22:28:26 -0400

There are many ways to execute code just after a document is opened or loaded.

NSWinowController provides -windowDidLoad as a candidate to override in a subclass.
NSWindow's elegate methods, – windowDidBecomeKey: and – windowDidBecomeMain:, can be handy.

However, I suspect you want a variant of an answer provided just yesterday:

http://www.cocoabuilder.com/archive/message/2004/10/11/119213

Implement -windowControllerDidLoadNib: or -awakeFromNib to call [self performSelector:@selector(showUtilityPanel:) withObject:nil afterDelay:0.0f];

On the next event loop pass after the document window is loaded, the showUtilityPanel: method will be called, and you can implement that to load and/or orderFront: you utility panel.

_______________________________________________
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
  • Follow-Ups:
    • Re: New Document Behavior
      • From: James Spencer <email@hidden>
  • Prev by Date: Re: New Document Behavior
  • Next by Date: Re: [NEWBIE] How to localize toolbar button?
  • Previous by thread: Re: New Document Behavior
  • Next by thread: Re: New Document Behavior
  • Index(es):
    • Date
    • Thread