• 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: Open untitled file in Document-based app
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Open untitled file in Document-based app


  • Subject: Re: Open untitled file in Document-based app
  • From: Sean McBride <email@hidden>
  • Date: Fri, 26 Oct 2012 09:59:30 -0400
  • Organization: Rogue Research Inc.

On Wed, 24 Oct 2012 22:26:59 +0200, ecir hana said:

>> That restoring state stuff is new in 10.7, not 10.8.  You can test if it
>> is responsible by turning it off in System Preferences > General.
>>
>>
>Yes, it is! When I turn it off (Close windows when quitting an application)
>it works as before. Is it possible to have the same behavior even when a
>user has the restoring state stuff enabled?

Yes.  It's been discussed on this list in the past, and should be in the archives.  Basically:

		if ([window respondsToSelector:@selector(setRestorationClass:)] &&
			[window respondsToSelector:@selector(setRestorable:)] &&
			[window respondsToSelector:@selector(invalidateRestorableState)])
		{
			[window setRestorationClass:Nil];
			[window setRestorable:NO];
			[window invalidateRestorableState];
		}

Cheers,

--
____________________________________________________________
Sean McBride, B. Eng                 email@hidden
Rogue Research                        www.rogue-research.com
Mac Software Developer              Montréal, Québec, Canada



_______________________________________________

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: 
 >Open untitled file in Document-based app (From: ecir hana <email@hidden>)
 >Re: Open untitled file in Document-based app (From: Graham Cox <email@hidden>)
 >Re: Open untitled file in Document-based app (From: ecir hana <email@hidden>)
 >Re: Open untitled file in Document-based app (From: Sean McBride <email@hidden>)
 >Re: Open untitled file in Document-based app (From: ecir hana <email@hidden>)

  • Prev by Date: Re: Need faster approach to load data in NSTableView from a file
  • Next by Date: Re: App rejection due to app-sandboxing invalid entitlement
  • Previous by thread: Re: Open untitled file in Document-based app
  • Next by thread: Running a-foul of bindings with multiple-value subfields
  • Index(es):
    • Date
    • Thread