• 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: Tuning KVO validation.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Tuning KVO validation.


  • Subject: Re: Tuning KVO validation.
  • From: Óscar Morales Vivó <email@hidden>
  • Date: Wed, 25 Feb 2004 12:47:57 +0100

Yeah, I guess in this case it's a very good solution (wonder why I didn't think about it in fact :\)

Only bothers me the fact that I'll be validating twice (in the formatter and in the model). Which makes me think there's probably a better solution. Maybe dealing with NSError, but I haven't been able to find docs on that which can help me enough.

On 25 Feb 2004, at 12:38, Allan Odgaard wrote:

On 25. Feb 2004, at 12:17, Sscar Morales Vivs wrote:

What I want is for a bad validation to make the computer beep and revert the UI to its previous value, but I don't know how to go about it properly (i.e. not in model code itself as that would be bad style).

Sounds like you want to look at NSFormatter instead of bindings:

http://developer.apple.com/documentation/Cocoa/Conceptual/ DataFormatting/index.html

http://developer.apple.com/documentation/Cocoa/Reference/Foundation/ ObjC_classic/Classes/NSFormatter.html
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.


References: 
 >Tuning KVO validation. (From: Óscar Morales Vivó <email@hidden>)
 >Re: Tuning KVO validation. (From: Allan Odgaard <email@hidden>)

  • Prev by Date: Re: Tuning KVO validation.
  • Next by Date: Side-affect free methods?
  • Previous by thread: Re: Tuning KVO validation.
  • Next by thread: Re: Tuning KVO validation.
  • Index(es):
    • Date
    • Thread