• 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: Core Data and the Document Dirty indicator
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Core Data and the Document Dirty indicator


  • Subject: Re: Core Data and the Document Dirty indicator
  • From: Jonathan Waddilove <email@hidden>
  • Date: Sat, 12 Apr 2008 12:51:16 +0100

Thank you, I hadn't thought of it as an UndoManger issue!

Jonathan

On 11 Apr 2008, at 19:41, I. Savant wrote:
When a Core Data document is opened initialization adds an entity for the
basic 'All' smart group. This object is assigned to an in memory store
(rather than to the persistent document) - I have checked and the 'All' item
doesn't appear in the saved data.


... but a context has changed. That's a change. It can result in an
undo. Period.


My problem is that adding this item results in the 'dirty' flag being set -
with the result that the user is prompted to save the document even though
they have not made any changes.


This isn't a Core Data problem. It's an Undo Manager problem. See
-[NSUndoManager removeAllActions] ... simply clear the changes when
you're done with your initialization routines.

You can also temporarily disable and enable undo registration. That
and the method above are covered and easily found in the
documentation.

--
I.S.

_______________________________________________

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


  • Prev by Date: dataWithPDFInsideRect doesn't clip
  • Next by Date: Re: Core Data and the Document Dirty indicator
  • Previous by thread: Re: Core Data and the Document Dirty indicator
  • Next by thread: Re: Core Data and the Document Dirty indicator
  • Index(es):
    • Date
    • Thread