discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question about NSMenuView


From: Germán André Arias Santiago
Subject: Re: Question about NSMenuView
Date: Wed, 14 Jan 2009 13:04:11 -0600

El lun, 12-01-2009 a las 08:09 +0100, Wolfgang Lux escribió:

> You've got ownership wrong. A menu owns (and retains) its menu view
> and not vice versa. Therefore, you must retain the menu somewhere
> else in your code (probably in an attribute of the window's owner).
> In addition, you should make the menu view the menu's representation
> by replacing the statement [self setMenu: menu]; by
>    [menu setMenuRepresentation: self];
> Note that this code will not work on Mac OS X, though.
> 
> Wolfgang

OK, now I have a retained menu, but with [menu setMenuRepresentation:
self] I don't see the menu. If I add [menu display] ; I see the
horizontal menu and work, but not in my MenuView. The horizontal menu
appears outside the window, at the middle of the screen. Really, I don't
understand this. 





reply via email to

[Prev in Thread] Current Thread [Next in Thread]