Shared IBOutlets ?
Shared IBOutlets ?
- Subject: Shared IBOutlets ?
- From: Bob Miller <email@hidden>
- Date: Thu, 18 Dec 2003 09:00:17 -0500
Hello,
I'm not sure if this is even allowable within the confines of Cocoa.
Can someone tell me if it is possible to somehow save and restore
IBOutlet connections between different nib views that have the same
owner and share a common IBOutlet. That is, I have a window and
controller that swaps in different nibs for its content view. I want to
be able to cache those nib views by saving it's reference in a
dictionary using a key so as to not require reloading every time that
particular view is displayed. Those different nibs have objects that
are connected to a common outlet in the controller / owner. When view
'A' gets loaded one of its objects gets connected to outlet 'X', all
works fine. When view 'B' gets loaded it is swapped in and one of its
objects also gets connected to outlet 'X' , all works fine. If view 'A'
gets loaded again it is loaded from the cached reference and it is not
reconnected so the result is that view 'B' connections are still in
place. All works fine if I do not cached my nib views since they
reconnect each time they are loaded.
I'd like to be able to cache the connection states somehow along with
the nib view references and swap them in too. Is this possible ? I was
not able to find anything on reestablishing previous connections.
Bob
[demime 0.98b removed an attachment of type image/gif which had a name of spongebob.sm..gif]
_______________________________________________
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.