Re: get the list of controls in a NSView
Re: get the list of controls in a NSView
- Subject: Re: get the list of controls in a NSView
- From: Graham Cox <email@hidden>
- Date: Sat, 13 Feb 2010 08:56:49 +1100
On 12/02/2010, at 11:48 PM, Roland King wrote:
> That's why I suggested viewWithTag: method, if you give the text view tag number 1 and the two buttons tags 2 and 3, you can easily find them by calling viewWithTag: with each tag from 1 to 3.
I can't really see the benefit of this - you're assigning a number to each view so you can find it. Each view already has a number - its pointer. So just make an outlet for each view of interest and then you can refer to it directly by name (ivar identifier) that you assign. Much easier.
--Graham
_______________________________________________
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