Re: Setting focus to text field in drawer
Re: Setting focus to text field in drawer
- Subject: Re: Setting focus to text field in drawer
- From: Bill Cheeseman <email@hidden>
- Date: Mon, 11 Aug 2003 14:46:54 -0400
on 03-08-11 2:15 PM, Scott Anguish at email@hidden wrote:
>
I prefix all my vars with this now
>
>
thisIsMyPrefix_itIsNobodyElsesPrefix_
How does this impact key-value coding for accessor methods and iVars -- for
example, for purposes of AppleScript?
I was under the impression that method names and iVar names should normally
be the same, except for the lowercase/uppercase conversion rules, the
addition of "set" at the beginning of a set accessor method, and the fact
that key-value coding will find an iVar if it has the same name as the
getter accessor AND if it has the same name and an underscore prefix (or
vice versa).
So, your thisIsMyPrefix_itIsNobodyElsesPrefix_ iVar's accessor methods will
not be called by key-value coding in some circumstances. Unless you name
your setter "setThisIsMyPrefix_itIsNobodyElsesPrefix_". Right?
I suppose, since we're only talking about private methods and iVars, that
the funny names don't matter.
(I had overlooked the passage you quoted from the Guidelines, as I mentioned
in a later post.)
--
Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA
http://www.quecheesoftware.com
The AppleScript Sourcebook -
http://www.AppleScriptSourcebook.com
Vermont Recipes -
http://www.stepwise.com/Articles/VermontRecipes
_______________________________________________
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.