Skip to content

Commit

Permalink
Merge pull request AvaloniaUI#7191 from ltetak/osx_handle_cmd_key_up
Browse files Browse the repository at this point in the history
OSX handle CMD+key up combinations in Avalonia
  • Loading branch information
maxkatz6 authored and danwalmsley committed May 10, 2022
1 parent 60ebbb7 commit 71b5c83
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions native/Avalonia.Native/src/OSX/app.mm
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,11 @@ - (void)sendEvent:(NSEvent *)event
_isHandlingSendEvent = true;
@try {
[super sendEvent: event];
if ([event type] == NSEventTypeKeyUp && ([event modifierFlags] & NSEventModifierFlagCommand))
{
[[self keyWindow] sendEvent:event];
}

} @finally {
_isHandlingSendEvent = oldHandling;
}
Expand Down

0 comments on commit 71b5c83

Please sign in to comment.