summaryrefslogtreecommitdiffstats
path: root/input
diff options
context:
space:
mode:
authoralbeu <albeu@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-02-24 13:03:47 +0000
committeralbeu <albeu@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-02-24 13:03:47 +0000
commitf0d1217cdea5249b71cc9502dcda895a27825ebc (patch)
treed793d308782fc62279c452f2f5c587192269be8d /input
parente016ed4fc47b5fbab4bffd833524a89e788d4317 (diff)
downloadmpv-f0d1217cdea5249b71cc9502dcda895a27825ebc.tar.bz2
mpv-f0d1217cdea5249b71cc9502dcda895a27825ebc.tar.xz
Added an option to select the input config file
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@4837 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'input')
-rw-r--r--input/input.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/input/input.c b/input/input.c
index 9470a6d530..a496edc921 100644
--- a/input/input.c
+++ b/input/input.c
@@ -228,8 +228,10 @@ static mp_cmd_t* ar_cmd = NULL;
static unsigned int ar_delay = 100, ar_rate = 8, last_ar = 0;
static int use_joystick = 1, use_lirc = 1;
+static char* config_file = "input.conf";
static config_t input_conf[] = {
+ { "conf", &config_file, CONF_TYPE_STRING, CONF_GLOBAL, 0, 0, NULL },
{ "ar-delay", &ar_delay, CONF_TYPE_INT, CONF_GLOBAL, 0, 0, NULL },
{ "ar-rate", &ar_rate, CONF_TYPE_INT, CONF_GLOBAL, 0, 0, NULL },
{ NULL, NULL, 0, 0, 0, 0, NULL}
@@ -1081,7 +1083,7 @@ void
mp_input_init(void) {
char* file;
- file = get_path("input.conf");
+ file = config_file[0] != '/' ? get_path(config_file) : config_file;
if(!file)
return;