Re: CoreData - NSManagedObjectContext notifications - Save vs DidChange ?
Re: CoreData - NSManagedObjectContext notifications - Save vs DidChange ?
- Subject: Re: CoreData - NSManagedObjectContext notifications - Save vs DidChange ?
- From: Bill Cheeseman <email@hidden>
- Date: Wed, 05 Oct 2005 18:56:45 -0400
- Thread-topic: CoreData - NSManagedObjectContext notifications - Save vs DidChange ?
on 2005-10-05 4:38 PM, Simon Liu at email@hidden wrote:
> Except that if I use the same handler for
> NSManagedObjectContextObjectsDidChangeNotification, I notice that the
> tableview does not update. It seems as though the array controller can't
> "see" the refreshing. Is there any way to make this happen, as I thought it
> would be possible to do this, without having to invoke -save: which is more
> expensive as it writes to the store.
I haven't studied your question closely, so this may not be responsive. I
just want to say that I have noticed that
NSManagedObjectContextObjectsDidChangeNotification doesn't do anything until
the next iteration of the run loop. To update a table, I found that I had to
move my code from the notification method to -awakeFromInsert, which is
called in the same cycle as the insertion. It doesn't sound like your issue
is an insertion issue, so this may not be a solution for you, but it
suggests you might want to look for something that gets invoked during the
same cycle.
--
Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA
http://www.quecheesoftware.com
PreFab Software - http://www.prefab.com/scripting.html
The AppleScript Sourcebook - http://www.AppleScriptSourcebook.com
Vermont Recipes - http://www.stepwise.com/Articles/VermontRecipes
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden