Prevent escape key from exiting full screen mode

This commit is contained in:
Allen Webster 2020-05-03 05:15:18 -07:00
parent 79bc7a7c6e
commit 79fd3ca65c
1 changed files with 11 additions and 4 deletions

View File

@ -911,10 +911,12 @@ mac_toggle_fullscreen(void){
#endif
}
// NOTE(allen): Trying to figure out a way to stop the error bonk sound every time I use a key combo.
// This stopped the sound as the docs suggested, but also stopped the key combo from being processed?
// Maybe put process_keyboard_event in there? But is this only sent for key downs? And why doesn't
// this block normal text input but only key combos??
// NOTE(allen): Trying to figure out a way to stop the error bonk
// sound every time I use a key combo. This stopped the sound as the
// docs suggested, but also stopped the key combo from being processed?
// Maybe put process_keyboard_event in there? But is this only sent
// for key downs? And why doesn't this block normal text input but
// only key combos??
#if 1
- (BOOL)performKeyEquivalent:(NSEvent *)event{
[self process_keyboard_event:event down:true];
@ -922,6 +924,11 @@ mac_toggle_fullscreen(void){
}
#endif
#if 1
- (void)cancelOperation:(id)sender
{}
#endif
- (BOOL)acceptsFirstResponder{
return(YES);
}