Re: re Hiding controls and another question
Re: re Hiding controls and another question
- Subject: Re: re Hiding controls and another question
- From: Graeme Hiebert <email@hidden>
- Date: Fri, 1 Mar 2002 21:45:15 -0800
On Friday, March 1, 2002, at 09:14 PM, John Saccente wrote:
Not quite yet! :o)
I think this:
if ( ![gViewDict objectForKey:self] )
should be
if ( ![gViewDict objectForKey:[self description]] )
Thanks. You caught a glimpse of my first failed attempt. I forgot to
fix one instance apparently. :^)
Anyway, one possible problem might be that if the superview is
destroyed, the detached subview will be left floating in limbo, no?
Plus, any messages sent to the hidden subview will go to the proxy and
will be lost (like a setStringValue: or something.) Perhaps you'd want
a special NSView subclass for your proxy object which was aware of its
disembodied doppelganger and would forward messages accordingly?
True, it's not perfect. Messages should still go to the original object
though, I think, unless they were going through the responder chain.
Like you say, using a special View class instead of a global dictionary
would pretty much take care of the biggest issues: memory management.
-g
_______________________________________________
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.