aboutsummaryrefslogtreecommitdiffhomepage
path: root/options
diff options
context:
space:
mode:
authorGravatar wm4 <wm4@nowhere>2013-12-21 19:33:45 +0100
committerGravatar wm4 <wm4@nowhere>2013-12-21 20:50:13 +0100
commited71606e65e697ea6bc9fc78caf2dd4089dc0aeb (patch)
treed3b80546a8e40c821ee7575c236d813021b8b7c8 /options
parentdadf3a9a46d31a101aeaa1256b0d6f914eb32f1e (diff)
input: rework how input sources are added
Until now, there were two functions to add input sources (stuff like stdin input, slave mode, lirc, joystick). Unify them to a single function (mp_input_add_fd()), and make sure the associated callbacks always have a context parameter. Change the lirc and joystick code such that they take store their state in a context struct (probably worthless), and use the new mp_msg replacements (the point of this refactoring). Additionally, get rid of the ugly USE_FD0_CMD_SELECT etc. ifdeffery in the terminal handling code.
Diffstat (limited to 'options')
-rw-r--r--options/options.c4
-rw-r--r--options/options.h1
2 files changed, 1 insertions, 4 deletions
diff --git a/options/options.c b/options/options.c
index fdb54ff115..a4c3292c01 100644
--- a/options/options.c
+++ b/options/options.c
@@ -574,10 +574,6 @@ const m_option_t mp_opts[] = {
OPT_STRING("stream-capture", stream_capture, 0),
OPT_STRING("stream-dump", stream_dump, 0),
-#if HAVE_LIRC
- {"lircconf", &lirc_configfile, CONF_TYPE_STRING, CONF_GLOBAL, 0, 0, NULL},
-#endif
-
OPT_CHOICE_OR_INT("loop", loop_times, M_OPT_GLOBAL, 2, 10000,
({"no", -1}, {"1", -1},
{"inf", 0})),
diff --git a/options/options.h b/options/options.h
index b99c5d2746..ae648a87c0 100644
--- a/options/options.h
+++ b/options/options.h
@@ -254,6 +254,7 @@ typedef struct MPOpts {
char *in_file;
int use_joystick;
int use_lirc;
+ char *lirc_configfile;
int use_lircc;
int use_alt_gr;
int use_ar;