Skip navigation.
 
mlBinding to a non-compliant property
FROM : Daniel Jalkut
DATE : Wed Apr 20 20:57:34 2005

I'm binding a pop up control's content to an array of NSSound names, 
and binding the selected object by referring to an NSSound's "name" 
property.  This works great, but it has the unwanted side-effect of a 
console message being printed about the incompatibility of NSSound's 
"setName" method because it doesn't return void.

What's the best way to work around this problem?  I've quieted the 
warning by adding support for a "boundName" property in a category of 
NSSound.  Now if I only bind to boundName and make sure I always use 
setBoundName to get at the sound's name, I'll be in business.  I'd 
prefer it if there was some way to get the KVO to work on the sound't 
"name" property even though the setName: method isn't compliant. Any 
ideas?

Daniel

Related mailsAuthorDate
No related mails found.