summaryrefslogtreecommitdiffstats
path: root/osdep/main-fn-cocoa.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:36:56 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:36:56 +0000
commit51de1d8436100f725f3576aefa24a2bd2057bc28 (patch)
treec6d1d5264b6d40a8d7ca34129f36b7d61e188af3 /osdep/main-fn-cocoa.c
parentInitial commit. (diff)
downloadmpv-51de1d8436100f725f3576aefa24a2bd2057bc28.tar.xz
mpv-51de1d8436100f725f3576aefa24a2bd2057bc28.zip
Adding upstream version 0.37.0.upstream/0.37.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'osdep/main-fn-cocoa.c')
-rw-r--r--osdep/main-fn-cocoa.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/osdep/main-fn-cocoa.c b/osdep/main-fn-cocoa.c
new file mode 100644
index 0000000..eeed127
--- /dev/null
+++ b/osdep/main-fn-cocoa.c
@@ -0,0 +1,10 @@
+#include "osdep/macosx_application.h"
+
+// This is needed because Cocoa absolutely requires creating the NSApplication
+// singleton and running it in the "main" thread. It is apparently not
+// possible to do this on a separate thread at all. It is not known how
+// Apple managed this colossal fuckup.
+int main(int argc, char *argv[])
+{
+ return cocoa_main(argc, argv);
+}