Do key equivalents

git-svn-id: svn+ssh://svn.gna.org/svn/gnustep/libs/gui/trunk@4339 72102866-910b-0410-8b05-ffd578937521
This commit is contained in:
Richard Frith-MacDonald 1999-06-02 19:28:33 +00:00
parent 58512c20c4
commit 076f49846e

View file

@ -544,7 +544,22 @@ NSApplication *NSApp = nil;
case NSKeyDown:
{
NSDebugLog(@"send key down event\n");
[[theEvent window] sendEvent: theEvent];
if ([theEvent modifierFlags] & NSCommandKeyMask)
{
NSArray *window_list = [self windows];
unsigned i;
unsigned count = [window_list count];
for (i = 0; i < count; i++)
{
NSWindow *window = [window_list objectAtIndex: i];
if ([window performKeyEquivalent: theEvent] == YES)
break;
}
}
else
[[theEvent window] sendEvent: theEvent];
break;
}