summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAkemi <der.richter@gmx.de>2018-01-20 15:54:27 +0100
committerKevin Mitchell <kevmitch@gmail.com>2018-01-20 14:43:49 -0800
commitdb08e28304693c1b2e8cbfbad0c28c23c1a414d7 (patch)
treea6828a1dee5ff972396101c639fb3befd7167d00
parent45ce4ba877b965291d9d9209b6dda6fbfbf83bb7 (diff)
downloadmpv-db08e28304693c1b2e8cbfbad0c28c23c1a414d7.tar.bz2
mpv-db08e28304693c1b2e8cbfbad0c28c23c1a414d7.tar.xz
osx: code cleanups and cosmetic fixes
-rw-r--r--osdep/macosx_application.m2
-rw-r--r--osdep/macosx_application_objc.h1
-rw-r--r--osdep/macosx_events.h1
-rw-r--r--osdep/macosx_events.m5
-rw-r--r--osdep/macosx_events_objc.h9
-rw-r--r--video/out/cocoa/window.m3
-rw-r--r--video/out/opengl/context_cocoa.c1
7 files changed, 4 insertions, 18 deletions
diff --git a/osdep/macosx_application.m b/osdep/macosx_application.m
index de2514f1ce..d070401621 100644
--- a/osdep/macosx_application.m
+++ b/osdep/macosx_application.m
@@ -61,7 +61,7 @@ static void terminate_cocoa_application(void)
}
@implementation Application
-@synthesize menuBar = _menu_Bar;
+@synthesize menuBar = _menu_bar;
@synthesize openCount = _open_count;
- (void)sendEvent:(NSEvent *)event
diff --git a/osdep/macosx_application_objc.h b/osdep/macosx_application_objc.h
index 512ab0f4ee..c12a8b8c64 100644
--- a/osdep/macosx_application_objc.h
+++ b/osdep/macosx_application_objc.h
@@ -29,6 +29,5 @@ struct mpv_event;
- (void)openFiles:(NSArray *)filenames;
@property(nonatomic, retain) MenuBar *menuBar;
-@property(nonatomic, retain) NSArray *files;
@property(nonatomic, assign) size_t openCount;
@end
diff --git a/osdep/macosx_events.h b/osdep/macosx_events.h
index 216df8238c..17adaf9ae5 100644
--- a/osdep/macosx_events.h
+++ b/osdep/macosx_events.h
@@ -26,7 +26,6 @@ struct mpv_handle;
void cocoa_put_key(int keycode);
void cocoa_put_key_with_modifiers(int keycode, int modifiers);
-void cocoa_put_key_event(void *event);
void cocoa_init_apple_remote(void);
void cocoa_uninit_apple_remote(void);
diff --git a/osdep/macosx_events.m b/osdep/macosx_events.m
index e94718c3d1..a23bd56278 100644
--- a/osdep/macosx_events.m
+++ b/osdep/macosx_events.m
@@ -194,11 +194,6 @@ void cocoa_put_key(int keycode)
[[EventsResponder sharedInstance] putKey:keycode];
}
-void cocoa_put_key_event(void *event)
-{
- [[EventsResponder sharedInstance] handleKey:event];
-}
-
void cocoa_put_key_with_modifiers(int keycode, int modifiers)
{
keycode |= [[EventsResponder sharedInstance] mapKeyModifiers:modifiers];
diff --git a/osdep/macosx_events_objc.h b/osdep/macosx_events_objc.h
index f3210f2580..79ace0a909 100644
--- a/osdep/macosx_events_objc.h
+++ b/osdep/macosx_events_objc.h
@@ -26,24 +26,17 @@ struct input_ctx;
@interface EventsResponder : NSObject <HIDRemoteDelegate>
+ (EventsResponder *)sharedInstance;
-
- (void)setInputContext:(struct input_ctx *)ctx;
-
- (void)setIsApplication:(BOOL)isApplication;
/// Blocks until inputContext is present.
- (void)waitForInputContext;
-
- (void)wakeup;
-
-- (bool)queueCommand:(char *)cmd;
-
- (void)putKey:(int)keycode;
-
- (void)setHighestPriotityMediaKeysTap;
-
- (void)handleFilesArray:(NSArray *)files;
+- (bool)queueCommand:(char *)cmd;
- (bool)processKeyEvent:(NSEvent *)event;
@end
diff --git a/video/out/cocoa/window.m b/video/out/cocoa/window.m
index 2feaab9c16..376298718b 100644
--- a/video/out/cocoa/window.m
+++ b/video/out/cocoa/window.m
@@ -45,7 +45,8 @@
@synthesize targetScreen = _target_screen;
@synthesize previousScreen = _previous_screen;
@synthesize currentScreen = _current_screen;
-@synthesize unfScreen = _unf_Screen;
+@synthesize unfScreen = _unf_screen;
+
- (id)initWithContentRect:(NSRect)content_rect
styleMask:(NSWindowStyleMask)style_mask
backing:(NSBackingStoreType)buffering_type
diff --git a/video/out/opengl/context_cocoa.c b/video/out/opengl/context_cocoa.c
index 2256d31b67..129999932e 100644
--- a/video/out/opengl/context_cocoa.c
+++ b/video/out/opengl/context_cocoa.c
@@ -19,7 +19,6 @@
#include <dlfcn.h>
#include "options/m_config.h"
#include "video/out/cocoa_common.h"
-#include "osdep/macosx_versions.h"
#include "context.h"
struct cocoa_opts {