Re: Swapping IB-created views and keeping IBOutlets hooked up
Re: Swapping IB-created views and keeping IBOutlets hooked up
- Subject: Re: Swapping IB-created views and keeping IBOutlets hooked up
- From: Keary Suska <email@hidden>
- Date: Tue, 16 Sep 2008 16:45:17 -0600
- Thread-topic: Swapping IB-created views and keeping IBOutlets hooked up
9/16/08 4:33 PM, also sprach email@hidden:
> I have two views that are different layouts of the same UI loaded by a
> NSViewController. Now lets say that I have an IBOutlet to an NSButton*
> button1 that is present in both views. I want to swap one view out for
> the other and when I do so have the IBOutlet for button1 swap to the
> button1 defined in the second view in another NIB.
>
> So for example, the viewcontroller inits with View A. button1 is
> assigned to the NSButton in View A. I then swap that view to View B
> which also have a button1. View B is in a different NIB. So I want
> button1 to now point to View B. Is this something that can be done
> automatically?
No. The easiest alternative is to have accessors for the outlets, and set
them on swap.
HTH,
Keary Suska
Esoteritech, Inc.
"Demystifying technology for your home or business"
_______________________________________________
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