• 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: Using NSDocument w/o always displaying the document window
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Using NSDocument w/o always displaying the document window


  • Subject: Re: Using NSDocument w/o always displaying the document window
  • From: PGM <email@hidden>
  • Date: Sat, 22 Sep 2007 00:03:13 -0400

I'm trying to build a document based Cocoa app, but I don't always want
to show my document window. My documents are more like command files.
They're created elsewhere and my app opens them and then depending on
the content either allows updates (shows the window) or just processes
the commands (no document window, just dialogs, or maybe I need
alternate document windows).


I haven't figured out how to not show the main document window. Is this
even possible in an NSDocument based app, or do I need to take another
approach? I'd prefer to stay document based if possible. Creating
different document types (.xyz vs. .abc) isn't an option.

You can override makeWindowControllers and there simply do nothing for documents for which you don't need a window. The following link may help you though it is about something slightly different (one window for all documents): http://www.cocoadev.com/index.pl? DocumentBasedAppWithOneWindowForAllDocuments


Cheers, Patrick
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Using NSDocument w/o always displaying the document window (From: "William E. Jens" <email@hidden>)

  • Prev by Date: Re: Scroll Views
  • Next by Date: Re: Scroll Views
  • Previous by thread: Using NSDocument w/o always displaying the document window
  • Next by thread: creating classes on the fly ??
  • Index(es):
    • Date
    • Thread