• 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: Temporarily disabling autosave
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Temporarily disabling autosave


  • Subject: Re: Temporarily disabling autosave
  • From: Jerry Krinock <email@hidden>
  • Date: Tue, 23 Apr 2013 07:19:47 -0700

On 2013 Apr 22, at 21:42, Steve Mills <email@hidden> wrote:

> [-setAutosavingDelay:0.0] didn't work.

OK, then.  I retract my surprise.

> The pause mechanism is something in our own code - a bool that says it's paused (it's actually an integer so it can be incremented/decremented in a nested fashion).

That's fine, but your code is not running the show in Lion autosave.  The holy grail we're discussing here is a method to tell Cocoa "Stop sending me  autosave requests (-[NSDocument autosaveWithImplicitCancellability:completionHandler:]) until I tell you to start again".  I believe, as I have from the beginning, that there is no such method.  If your NSDocument subclass returns YES to +autosavesInPlace, you *will* get (-[NSDocument autosaveWithImplicitCancellability:completionHandler:]) at arbitrary times.

> I check this value in writeToURL and hasUnautosavedChanges.

I've never tried -hasUnautosavedChanges, because it's another "Tiger" autosave method, available since Mac OS X 10.4.  Do you ever get that message?  If so, then returning NO might pause -[NSDocument autosaveWithImplicitCancellability:completionHandler:], which is the holy grail here.  If that works, I shall drop my jaw again.

On 2013 Apr 23, at 01:47, Mike Abdullah <email@hidden> wrote:

> Receiving a [implicitCancellability equal to] NO *is* going to happen.

I agree with Mike.  I don't think you're done, Steve.

* * *

Maybe the confusion is that we are not distinguishing between

• Lion Autosave
• Tiger Autosave
• Some home-made Autosave which Steve's forebears have bequeathed to him

Choose and implement one, and only one of these.


_______________________________________________

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


  • Follow-Ups:
    • Re: Temporarily disabling autosave
      • From: Mike Abdullah <email@hidden>
    • Re: Temporarily disabling autosave
      • From: Steve Mills <email@hidden>
References: 
 >Temporarily disabling autosave (From: Steve Mills <email@hidden>)
 >Re: Temporarily disabling autosave (From: Mike Abdullah <email@hidden>)
 >Re: Temporarily disabling autosave (From: Steve Mills <email@hidden>)
 >Re: Temporarily disabling autosave (From: Mike Abdullah <email@hidden>)
 >Re: Temporarily disabling autosave (From: Jerry Krinock <email@hidden>)
 >Re: Temporarily disabling autosave (From: Mike Abdullah <email@hidden>)
 >Re: Temporarily disabling autosave (From: Steve Mills <email@hidden>)
 >Re: Temporarily disabling autosave (From: Jerry Krinock <email@hidden>)
 >Re: Temporarily disabling autosave (From: Steve Mills <email@hidden>)

  • Prev by Date: Re: Temporarily disabling autosave
  • Next by Date: Re: Temporarily disabling autosave
  • Previous by thread: Re: Temporarily disabling autosave
  • Next by thread: Re: Temporarily disabling autosave
  • Index(es):
    • Date
    • Thread