• 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: Keeping an NSDocument Open [SOLVED]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Keeping an NSDocument Open [SOLVED]


  • Subject: Re: Keeping an NSDocument Open [SOLVED]
  • From: Craig Altenburg <email@hidden>
  • Date: Thu, 27 Jul 2006 17:47:25 -0400

On 26 jul 2006, at 22.07, Craig Altenburg wrote:

I need to keep my NSDocument open even after the last window closes.

The documentation that I can find seems to indicate that this should be possible but I have yet to find an easy way to do it.

------------8<---------------

OK, for the next poor soul who searches the archive for this...

I overrode the "close" method of my document class to do nothing:

	- (void) close {}

 Then added a "reallyClose" method:

	- (void) reallyClose { [ super close ]; }

I feel this is somewhat less then perfect as it not only prevents the last NSWindowController from closing the document (good) but also prevents anything else that uses [myDoc close] from closing it too (bad).

If anyone know of a better way I'd be happy to hear of it.

--
Craig A.
_______________________________________________
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


References: 
 >ODBC (From: Brian Weitzner <email@hidden>)
 >Re: ODBC (From: "Scotty's Lists" <email@hidden>)
 >Re: ODBC (From: Brian Weitzner <email@hidden>)
 >Re: ODBC (From: "Scotty's Lists" <email@hidden>)
 >Re: ODBC (From: Brian Weitzner <email@hidden>)
 >Keeping an NSDocument Open (From: Craig Altenburg <email@hidden>)
 >Re: Keeping an NSDocument Open (From: j o a r <email@hidden>)
 >Re: Keeping an NSDocument Open (From: Craig Altenburg <email@hidden>)

  • Prev by Date: Re: NSDatePicker delegate
  • Next by Date: 'inserted' and 'removed' arrays in observeValueForKeyPath's change dictionary always nil
  • Previous by thread: Re: Keeping an NSDocument Open
  • Next by thread: Binding and NSPopupButton
  • Index(es):
    • Date
    • Thread