• 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: Autosave directory settable?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Autosave directory settable?


  • Subject: Re: Autosave directory settable?
  • From: Kevin Perry <email@hidden>
  • Date: Tue, 16 Apr 2013 13:18:21 -0700

That might work, though I would probably recommend overriding at -saveToURL:ofType:forSaveOperation:completionHandler: instead, and only modify the path if saveOperation == NSAutosaveElsewhereOperation. If you override at that level, setAutosavedContentsFileURL: will be invoked for you when the save is complete.

-KP

On Apr 16, 2013, at 12:54 PM, Steve Mills <email@hidden> wrote:

> Is it possible for the app to set the directory where autosaved documents will be stored instead of the folder the OS creates deep within /private/var/folders? Our app has long done its own autosaving and offered a pref so the user could change the dir if they wanted. I'm now looking into the possibility of switching to Cocoa's autosave instead, and would like all our autosave prefs to remain as they are and still be usable.
>
> Would it be gross to override writeToURL:ofType:forSaveOperation:originalContentsURL:error: and if it's an autosave operation, rejigger the url to use own dir, and finally call setAutosavedContentsFileURL with the url we saved to instead?
>
> --
> Steve Mills
> office: 952-818-3871
> home: 952-401-6255
> cell: 612-803-6157
>
>
>
> _______________________________________________
>
> 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

_______________________________________________

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: Autosave directory settable?
      • From: Steve Mills <email@hidden>
References: 
 >Autosave directory settable? (From: Steve Mills <email@hidden>)

  • Prev by Date: Autosave directory settable?
  • Next by Date: Re: Autosave directory settable?
  • Previous by thread: Autosave directory settable?
  • Next by thread: Re: Autosave directory settable?
  • Index(es):
    • Date
    • Thread