Re: How to make a NSPanel show up in Windows menu?
Re: How to make a NSPanel show up in Windows menu?
- Subject: Re: How to make a NSPanel show up in Windows menu?
- From: Dustin Voss <email@hidden>
- Date: Sat, 24 Aug 2002 16:05:52 -0700
On Monday, August 19, 2002, at 09:34 AM, Matt Neuburg wrote:
On Sat, 17 Aug 2002 05:56:41 -0700, Dustin Voss <email@hidden>
said:
Pretty much like the subject says. I've got an NSPanel (a Find
panel), and
I'd like it, and most other modeless panel I'm anticipating, to show
up in
the Windows menu.
NSPanel inherits from NSWindow, of course, and NSWindow has that
isExcludedFromWindowsMenu: method. NSPanel sets this to YES. This
isn't
documented, by the way, I've noticed that the docs don't describe
overrides. But that's a gripe for another day.
So, what do I have to do to put the panel in the Window menu?
Override it again? Haven't tried this but it's the first thing I'd do.
m.
Well, I just tried a custom sub-class of NSPanel that always returns NO
for isExcludedFromWindowsMenu. The method isn't even called. I also
tried updating the menu right after calling makeKeyAndOrderFront on the
panel; same result.
If I were to hazard a guess, I'd say that the Window menu purposely
excludes instances of NSPanel and its subclasses--though not other
subclasses of NSWindow--regardless of the isExcludedFromWindowsMenu
value. Or maybe NSWindow does something to make itself appear in the
Window menu, which NSPanel doesn't.
Is there a way to fix this?
--
Dustin
_______________________________________________
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.