diff options
author | Pierre Ossman <ossman@cendio.se> | 2021-12-14 17:06:36 +0100 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2022-12-13 14:52:13 +0100 |
commit | 4f6d4895c3420e5ac301a916bced4a0065a19183 (patch) | |
tree | f838f2f17e2902c57bf5f5b15be8e12338aa0436 /vncviewer/cocoa.h | |
parent | 946fb2b03b7663abd9d71014de5dfdf25a7e040d (diff) | |
download | tigervnc-4f6d4895c3420e5ac301a916bced4a0065a19183.tar.gz tigervnc-4f6d4895c3420e5ac301a916bced4a0065a19183.zip |
Handle macOS keyboard stealing
The system steals keyboard events for certain system keyboard shortcuts,
e.g. Cmd+Tab. Unfortunately this isn't considered a focus loss, so we
don't realise we've lost a few keyboard events and can end up in a
confused state.
Fortunately it is possible to detect when this happens and reset the
keyboard state, just like we do when focus is lost.
Diffstat (limited to 'vncviewer/cocoa.h')
-rw-r--r-- | vncviewer/cocoa.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/vncviewer/cocoa.h b/vncviewer/cocoa.h index ca17ddf9..63b2a535 100644 --- a/vncviewer/cocoa.h +++ b/vncviewer/cocoa.h @@ -34,6 +34,7 @@ CGColorSpaceRef cocoa_win_color_space(Fl_Window *win); bool cocoa_win_is_zoomed(Fl_Window *win); void cocoa_win_zoom(Fl_Window *win); +int cocoa_is_keyboard_sync(const void *event); int cocoa_is_keyboard_event(const void *event); int cocoa_is_key_press(const void *event); |