mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-22 13:10:59 +00:00
* NSApplication.m sendEvent: add test for menu to right mouse display of.
git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@3214 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
7cd0ae9f9c
commit
f56ca9b4bd
2 changed files with 14 additions and 12 deletions
|
@ -10,6 +10,7 @@ Thu Nov 12 1998 Felipe A. Rodriguez <far@ix.netcom.com>
|
|||
* NSWindow.m move various non OS XDPS specific methods to XDPS, move
|
||||
various front end methods out of XRWindow and into NSWindow, fix
|
||||
center method.
|
||||
* NSApplication.m sendEvent: add test for menu to right mouse display of.
|
||||
|
||||
Mon Nov 9 1998 Richard Frith-Macdonald <richard@brainstorm.co.uk>
|
||||
|
||||
|
|
|
@ -286,18 +286,19 @@ NSAutoreleasePool* pool;
|
|||
}
|
||||
|
||||
case NSRightMouseDown: // Right mouse down
|
||||
{
|
||||
static NSMenu *copyOfMainMenu = nil;
|
||||
NSWindow *copyMenuWindow;
|
||||
|
||||
if(!copyOfMainMenu) // display the menu
|
||||
copyOfMainMenu = [main_menu copy]; // under the mouse
|
||||
copyMenuWindow = [copyOfMainMenu menuWindow];
|
||||
[copyOfMainMenu _rightMouseDisplay];
|
||||
[copyMenuWindow captureMouse:self];
|
||||
[[copyOfMainMenu menuCells] mouseDown:theEvent];
|
||||
[copyMenuWindow releaseMouse:self];
|
||||
}
|
||||
if(main_menu)
|
||||
{
|
||||
static NSMenu *copyOfMainMenu = nil;
|
||||
NSWindow *copyMenuWindow;
|
||||
|
||||
if(!copyOfMainMenu) // display the menu
|
||||
copyOfMainMenu = [main_menu copy]; // under the mouse
|
||||
copyMenuWindow = [copyOfMainMenu menuWindow];
|
||||
[copyOfMainMenu _rightMouseDisplay];
|
||||
[copyMenuWindow captureMouse:self];
|
||||
[[copyOfMainMenu menuCells] mouseDown:theEvent];
|
||||
[copyMenuWindow releaseMouse:self];
|
||||
}
|
||||
break;
|
||||
|
||||
default: // pass all other events to
|
||||
|
|
Loading…
Reference in a new issue