diff options
Diffstat (limited to '')
-rw-r--r-- | osdep/mac/app_bridge_objc.h (renamed from osdep/macOS_swift_bridge.h) | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/osdep/macOS_swift_bridge.h b/osdep/mac/app_bridge_objc.h index 9407b6f..6020198 100644 --- a/osdep/macOS_swift_bridge.h +++ b/osdep/mac/app_bridge_objc.h @@ -15,9 +15,7 @@ * License along with mpv. If not, see <http://www.gnu.org/licenses/>. */ -// including frameworks here again doesn't make sense, but otherwise the swift -// compiler doesn't include the needed headers in our generated header file -#import <IOKit/pwr_mgt/IOPMLib.h> +#import <Cocoa/Cocoa.h> #import <QuartzCore/QuartzCore.h> #include "player/client.h" @@ -27,13 +25,14 @@ #include "options/m_config.h" #include "player/core.h" #include "input/input.h" +#include "input/event.h" +#include "input/keycodes.h" #include "video/out/win_state.h" -#include "osdep/macosx_application_objc.h" -#include "osdep/macosx_events_objc.h" +#include "osdep/main-fn.h" +#include "osdep/mac/app_bridge.h" - -// complex macros won't get imported to Swift so we have to reassign them +// complex macros won't get imported to swift so we have to reassign them static int SWIFT_MBTN_LEFT = MP_MBTN_LEFT; static int SWIFT_MBTN_MID = MP_MBTN_MID; static int SWIFT_MBTN_RIGHT = MP_MBTN_RIGHT; @@ -48,10 +47,10 @@ static int SWIFT_MBTN9 = MP_MBTN9; static int SWIFT_KEY_MOUSE_LEAVE = MP_KEY_MOUSE_LEAVE; static int SWIFT_KEY_MOUSE_ENTER = MP_KEY_MOUSE_ENTER; -// only used from Swift files and therefore seen as unused by the c compiler -static void SWIFT_TARRAY_STRING_APPEND(void *t, char ***a, int *i, char *s) __attribute__ ((unused)); +static const char *swift_mpv_version = mpv_version; +static const char *swift_mpv_copyright = mpv_copyright; -static void SWIFT_TARRAY_STRING_APPEND(void *t, char ***a, int *i, char *s) -{ - MP_TARRAY_APPEND(t, *a, *i, s); -} +NSData *app_bridge_icon(void); +void app_bridge_tarray_append(void *t, char ***a, int *i, char *s); +const struct m_sub_options *app_bridge_mac_conf(void); +const struct m_sub_options *app_bridge_vo_conf(void); |