• 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: Out-of-order Undos and NSTextField
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Out-of-order Undos and NSTextField


  • Subject: Re: Out-of-order Undos and NSTextField
  • From: Ken Victor <email@hidden>
  • Date: Mon, 10 Jul 2006 10:08:34 -0700

james,
just so you know you are not alone, i've encountered the same problem and in a little experimentation, i didn't find a solution either. hopefully, someone will respond.
ken



At 11:14 PM -0700 7/9/06, James Bucanek wrote on Saturday, July 8, 2006:

How do I get these to operate in the correct order? Do I have multiple Undo
managers at work here? How can I coordinate them or use just one?

Just to follow up on my own post, the NSUndoManager returned by the NSTextField and the document are the same, so I don't have two conflicting undo stacks.


I've checked that -[NSUndoMaanager groupsByEvents] returns YES, so every pass through the event loop *should* result in a distinct top-level undo group.

So how/why can a registered undo action that occured *after* the text field was edited get put in the undo stack *before* the text field changes?

I'm really confused.

James

P.S. I also tried creating a sub-class of NSTextField that returned nil for -[NSResponder undoManager], but that just caused all kinds of problems.

P.P.S. I also tried putting my undo actions together in a group, but that didn't make any difference.
_______________________________________________
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


  • Follow-Ups:
    • Re: Out-of-order Undos and NSTextField
      • From: Bill Cheeseman <email@hidden>
  • Prev by Date: Re: NSCell mouse tracking best practices.
  • Next by Date: Re: NSData to NSString encoding error
  • Previous by thread: Re: Out-of-order Undos and NSTextField
  • Next by thread: Re: Out-of-order Undos and NSTextField
  • Index(es):
    • Date
    • Thread