diff options
author | Stefano Pigozzi <stefano.pigozzi@gmail.com> | 2013-09-01 23:49:25 +0200 |
---|---|---|
committer | Stefano Pigozzi <stefano.pigozzi@gmail.com> | 2013-09-01 23:51:36 +0200 |
commit | 04caddb7c84a9a8fd4a454766405830233d6c413 (patch) | |
tree | f2a918618eeee7292204eae1c4a0bb83cebc36b1 /osdep | |
parent | a5183a761c4456cbbd0d14e44f2136d476ab9eed (diff) | |
download | mpv-04caddb7c84a9a8fd4a454766405830233d6c413.tar.bz2 mpv-04caddb7c84a9a8fd4a454766405830233d6c413.tar.xz |
cocoa: enqueue events only if input context is present
Diffstat (limited to 'osdep')
-rw-r--r-- | osdep/macosx_events.m | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/osdep/macosx_events.m b/osdep/macosx_events.m index 2edcba57ac..38d723c204 100644 --- a/osdep/macosx_events.m +++ b/osdep/macosx_events.m @@ -159,7 +159,8 @@ void cocoa_uninit_media_keys(void) { void cocoa_put_key(int keycode) { - mp_input_put_key(mpv_shared_app().inputContext, keycode); + if (mpv_shared_app().inputContext) + mp_input_put_key(mpv_shared_app().inputContext, keycode); } void cocoa_put_key_with_modifiers(int keycode, int modifiers) |