gnustep-dev
[Top][All Lists]
Advanced

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

Re: [Gnustep-cvs] r31859 - in /libs/gui/trunk: ChangeLog Source/NSApplic


From: Germán Arias
Subject: Re: [Gnustep-cvs] r31859 - in /libs/gui/trunk: ChangeLog Source/NSApplication.m Source/NSWindow.m
Date: Sun, 09 Jan 2011 20:12:07 -0600

On dom, 2011-01-09 at 23:38 +0100, Fred Kiefer wrote:
> Does this change make your other changes to NSMenuView obsolete? 

As I know, no.

> If so,
> could you please undo these changes. If not, could you please explain
> why they are still needed?

The changes at NSApplication only are necessary when the user unhide the
app (with a double click above the AppIcon). Because when the NSApp hide
the application, resign the main window. But not set a main window when
unhide the app. If the window where is the menu isn't the main window,
the horizontal menu can't respond correctly (the menu don't respond to
the mouse tracking). Of course here I assume that key window can become
the main window. In other case the menu will not respond correctly.
(this is not needed when the window is deminiaturized, because in this
case the method -makeKeyAndOrderFront: call the method
-becomeMainWindow:)

In reference at changes at NSWindow, we need close the menu
(-resignMainWindow: is called when the user want hide the app). This
because the menu is closed after the selected option has been done. For
example, when you select "Open" the open panel is displayed, but the
menu is still displayed in back. After you select a file and open it,
the menu is closed. This is a problem when the user want hide the app.
Imagine that the user open the menu and click the "Hide" option. This
resign the main window. After done all the operations to hide the app,
the menu should to close itself, but this don't happen.  Why? I'm not
sure, maybe because the app is hidden, or because its window is no more
the main window (but this is not a problem when the window is
miniaturized). For any of these reasons the menu can't respond and
remains opened. That was the previous behavior, and these changes fix
this. Maybe I need add a FIXME note in this change, since I'm not sure
why this is needed.

As I can see, these changes are not related with my previous changes in
NSMenuView. They just care about, first: that the menu is closed if the
mouse is positioned outside the menu (in other way the app don't respond
to events non related with the menu). And second: that the horizontal
menu retrieve the mouse tracking when the mouse moves from a submenu to
this.

> 
> Thank you
> Fred
> 
> Am 09.01.2011 07:10, schrieb �:
> > Author: espectador
> > Date: Sun Jan  9 07:10:02 2011
> > New Revision: 31859
> > 
> > URL: http://svn.gna.org/viewcvs/gnustep?rev=31859&view=rev
> > Log:
> > Fixed the behaviour of menu in window when hide the app
> > 
> > Modified:
> >     libs/gui/trunk/ChangeLog
> >     libs/gui/trunk/Source/NSApplication.m
> >     libs/gui/trunk/Source/NSWindow.m




reply via email to

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