Re: NSarraycontroller numberable IBOutlet pointers
Re: NSarraycontroller numberable IBOutlet pointers
- Subject: Re: NSarraycontroller numberable IBOutlet pointers
- From: mmalc crawford <email@hidden>
- Date: Mon, 21 May 2007 09:26:18 -0700
On May 21, 2007, at 9:03 AM, MH wrote:
My understanding is that an IBOutlet is essentially pointer to an
instantiated object in IB.
'IBOutlet' is simply a keyword you use to let IB know that a typed
instance variable should be treated as an outlet. Other than that it
has no semantic or syntactic value (it's #defined to nothing).
Is it ok have numerous IBOutlets all pointing to the same object in
IB, i.e. an nsarraycontroller?
What happened when you tried it?
I'm just suspicious of this for some reason, but logically because an
IBOutlet is just a pointer, a change occuring anywhere, whether in
this controller or that will be reflected across all other pointers to
that object.
It's not clear what you mean.
If multiple objects are pointing to a given array controller, then
they're pointing to that array controller. If the array controller's
properties change, then if they interrogate the array controller
they'll see the differences. If one object starts pointing to a
different array controller, that doesn't affect the fact that the
others are still pointing to the original one.
I just want my nsarraycontrollers to be accessible from a number of
different files is all.
You cannot make outlet connections directly across nib files.
(See <http://developer.apple.com/documentation/Cocoa/Conceptual/LoadingResources/CocoaNibs/chapter_3_section_2.html
> and <http://developer.apple.com/documentation/Cocoa/Conceptual/LoadingResources/CocoaNibs/chapter_3_section_7.html
>for example).
If you're using array controllers, you probably want to specify key
paths.
mmalc
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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