Convert a per-doc window to inspector?
Convert a per-doc window to inspector?
- Subject: Convert a per-doc window to inspector?
- From: Rick Mann <email@hidden>
- Date: Fri, 2 Oct 2009 15:20:41 -0700
I have a window and controller that get instantiated per-document, and
there's some confusion when multiple documents are open as to which of
these windows belongs to which document.
I'm considering changing it to behave like an inspector window, where
a single window changes its content to reflect the selected document.
Currently, the window UI elements bind to objects in the document's
Managed Object Context, via the window controller's document property
(actually, I'm not sure how that's getting set on this controller in
the first place, but it seems to work).
I figure I need to disassociate the window controller from any
specific document, and then switch the context it uses when doc
windows become active. But I don't really know the right place/way to
do that. Is there a way for a responder subclass to know it's now
"active" (in the responder chain)? Is there a completely different
approach I should use? Will the UI update properly when I change the
MOC?
TIA,
Rick
_______________________________________________
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