• 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 20:22:05 -0700 (PDT)

Graham Cox wrote:

> I need a way to commit ... pending edits
> as part of my response to the "Apply" button.

I don't know that this is "the correct way," but there is a built-in mechanism that will do what you want:

If you were to makeFirstResponder nil for the window containing the text field, the textDidEndEditing method would be called on the active text field and then its data could be saved normally.

You'd lose the edit state of course, but if you're applying changes I'm guessing that would be OK.

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