If you wanted to try this, you should also override -updateChangeCountWithToken:forSaveOperation:, which is used to decrement change counts after saving.
I expect this would get you 99% of the way, but as Seth said, don't expect it to be bulletproof. On Oct 18, 2013, at 11:49 AM, Seth Willits <sli...@araelium.com> wrote: > On Oct 18, 2013, at 11:41 AM, jonat...@mugginsoft.com wrote: > >> Twice recently I have found myself tinkering with NSDocument et al to >> support observing of certain values. >> For example, NSDocument -isDocumentEdited is not seemingly KVO compliant. >> -isDocumentEdited status is driven by -updateChangeCount: so >> >> ... >> >> Is this the best way to go about addressing these sorts of issues with >> regard to missing KVO compliance? > > Well, the best thing to do is file a radar and wait a couple years for them > to get around to adding it. :( > > That said, it would probably mostly work, but it's not always guaranteed to > be bulletproof because those keys could also be influenced by private > methods. > > > -- > Seth Willits > > > > > _______________________________________________ > > Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) > > 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: > https://lists.apple.com/mailman/options/cocoa-dev/kperry%40apple.com > > This email sent to kpe...@apple.com _______________________________________________ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to arch...@mail-archive.com