I've noticed that under some, as yet to be determined, conditions, 
[NSUndoManager endUndoGrouping]; does not decrement the groupingLevel. Could 
someone with access to the sources tell me how this could be?

Before I call -endUndoGrouping, the level is 1. Afterwards, the level is still 
1. I've turned off -setGroupsByEvent and am handling all the grouping manually.

Normally the level does get decremented from 1 to 0 as expected, but sometimes 
it does not. This appears to be in some way related to whether it is being 
called from an exception handler (catch block) or not, though I'm unsure. 

When this happens, I end up with the NSUndoManager in the dreaded 'invalid 
state' whereby it just stops working. Since all parts of my app use Undo, this 
fragility is extremely detrimental to my app's functionality.

I just need to know what is the condition that causes -endUndoGrouping not to 
have any effect, so I can avoid that condition.

--Graham


_______________________________________________

Cocoa-dev mailing list ([email protected])

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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to