diff options
author | der richter <der.richter@gmx.de> | 2020-02-15 16:13:37 +0100 |
---|---|---|
committer | der richter <der.richter@gmx.de> | 2020-02-22 13:56:31 +0100 |
commit | b8f2811f8d180d4c2a39aabc046440c900652bb4 (patch) | |
tree | 6be8c67b9a0a1c5a172f561ceab389e55eb19791 /osdep/macosx_events_objc.h | |
parent | c1d744328e737fe80ecfdc0cbb6260d7699f4328 (diff) | |
download | mpv-b8f2811f8d180d4c2a39aabc046440c900652bb4.tar.bz2 mpv-b8f2811f8d180d4c2a39aabc046440c900652bb4.tar.xz |
mac: fix media key support for libmpv users
this basically moves the remote command center to our mac events instead
of keeping it our Application, which is only available when started from
mpv itself. also make it independent of the NSApplication.
this also prevents a runtime crash
Diffstat (limited to 'osdep/macosx_events_objc.h')
-rw-r--r-- | osdep/macosx_events_objc.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/osdep/macosx_events_objc.h b/osdep/macosx_events_objc.h index efc4e8f7ec..9394fe7160 100644 --- a/osdep/macosx_events_objc.h +++ b/osdep/macosx_events_objc.h @@ -20,6 +20,7 @@ #import <Cocoa/Cocoa.h> #include "osdep/macosx_events.h" +@class RemoteCommandCenter; struct input_ctx; @interface EventsResponder : NSObject @@ -39,4 +40,6 @@ struct input_ctx; - (BOOL)handleMPKey:(int)key withMask:(int)mask; +@property(nonatomic, retain) RemoteCommandCenter *remoteCommandCenter; + @end |