summaryrefslogtreecommitdiffstats
path: root/core/input
diff options
context:
space:
mode:
authorwm4 <wm4@nowhere>2013-03-08 02:08:02 +0100
committerwm4 <wm4@nowhere>2013-03-08 02:12:53 +0100
commitbc20f2cb00234ce436be2f939cb62dbbde5e8dd2 (patch)
treec4c55ae65b8f468578de5eb7253c9c2cd6c44c5c /core/input
parent14427ae2ee1923eeeb5189f6a0a3c9ebf391eff6 (diff)
downloadmpv-bc20f2cb00234ce436be2f939cb62dbbde5e8dd2.tar.bz2
mpv-bc20f2cb00234ce436be2f939cb62dbbde5e8dd2.tar.xz
core: remove a number of global variables
Move them into per-instance structs. This should get rid of all global variables in mplayer.c (not counting those referenced by cfg-mplayer.h). In core/input/ar.c, just remove checking the slave_mode variable. I'm not sure what this code was supposed to achieve, but slave mode is broken, slave mode is actually infeasible on OSX (ar.c is completely OSX specific), and the correct way of doing this would be to disable this input device per command line switch.
Diffstat (limited to 'core/input')
-rw-r--r--core/input/ar.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/core/input/ar.c b/core/input/ar.c
index 4dc1c27f5a..844ad680b3 100644
--- a/core/input/ar.c
+++ b/core/input/ar.c
@@ -33,8 +33,6 @@
#include "ar.h"
#include "keycodes.h"
-extern int slave_mode;
-
extern const double NSAppKitVersionNumber;
typedef struct cookie_keycode_map {
@@ -313,9 +311,6 @@ static int is_mplayer_front(void)
&& SameProcess(&frProc, &myProc, &sameProc) == noErr) {
if (sameProc)
return 1;
- // If MPlayer is running in slave mode, also check parent process.
- if (slave_mode && GetProcessPID(&frProc, &parentPID) == noErr)
- return parentPID==getppid();
}
return 0;
}