• 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: Correct way to commit pending text field edits?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Correct way to commit pending text field edits?


  • Subject: Re: Correct way to commit pending text field edits?
  • From: Joel Norvell <email@hidden>
  • Date: Thu, 24 Jul 2008 21:52:37 -0700 (PDT)

chaitanya pandit wrote:

> You need to call this on the NSTextField's cell:
> setSendsActionOnEndEditing:YES

sendsActionOnEndEditing appears to be ON by default.  And it doesn't affect pending edits anyway.  The problem is how to cause textDidEndEditing to "fire."

Hence my  suggestion to "makeFirstResponder nil" for the window containing the text field.

Although Ken Ferry's suggestion

> send one of the -commitEditing... messages
> to the NSController-derived mediating controllers.
> This is part of the NSEditor information protocol.

seems more elegant than my suggestion to just "slam" the window's firstResponder.

Sincerely,
Joel





_______________________________________________

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: Re: Correct way to commit pending text field edits?
  • Next by Date: (no subject)
  • Previous by thread: Re: Correct way to commit pending text field edits?
  • Next by thread: [MEET] Singapore CocoaHeads TODAY (25 July 08)
  • Index(es):
    • Date
    • Thread