mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-05-30 12:50:40 +00:00
* Source/NSMenuView.m: Return from the trackWithEvent: method
if the indexOfActionToExecute is -1. git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@27690 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
parent
0d5c221a7d
commit
d9f18ec9b4
2 changed files with 10 additions and 5 deletions
|
@ -1281,11 +1281,6 @@ static NSMapTable *viewInfo = 0;
|
|||
- (BOOL) _executeItemAtIndex: (int)indexOfActionToExecute
|
||||
removeSubmenu: (BOOL)subMenusNeedRemoving
|
||||
{
|
||||
if (indexOfActionToExecute == -1)
|
||||
{
|
||||
return YES;
|
||||
}
|
||||
|
||||
if (indexOfActionToExecute >= 0
|
||||
&& [_attachedMenu attachedMenu] != nil && [_attachedMenu attachedMenu] ==
|
||||
[[_items_link objectAtIndex: indexOfActionToExecute] submenu])
|
||||
|
@ -1610,6 +1605,11 @@ static NSMapTable *viewInfo = 0;
|
|||
}
|
||||
}
|
||||
|
||||
if (indexOfActionToExecute == -1)
|
||||
{
|
||||
return YES;
|
||||
}
|
||||
|
||||
if([self _executeItemAtIndex: indexOfActionToExecute
|
||||
removeSubmenu: subMenusNeedRemoving] == NO)
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue