summaryrefslogtreecommitdiffstats
path: root/core
diff options
context:
space:
mode:
Diffstat (limited to 'core')
-rw-r--r--core/cfg-mplayer.h7
-rw-r--r--core/defaultopts.c1
-rw-r--r--core/mplayer.c4
-rw-r--r--core/options.h2
4 files changed, 7 insertions, 7 deletions
diff --git a/core/cfg-mplayer.h b/core/cfg-mplayer.h
index eb3b805622..9bf6d53d6d 100644
--- a/core/cfg-mplayer.h
+++ b/core/cfg-mplayer.h
@@ -36,9 +36,6 @@
extern char *lirc_configfile;
-/* only used at startup (setting these values from configfile) */
-extern int stop_xscreensaver;
-
extern int mp_msg_color;
extern int mp_msg_module;
@@ -615,8 +612,8 @@ const m_option_t mplayer_opts[]={
{"refreshrate",&vo_refresh_rate,CONF_TYPE_INT,CONF_RANGE, 0,100, NULL},
{"wid", &WinID, CONF_TYPE_INT64, 0, 0, 0, NULL},
#ifdef CONFIG_X11
- {"stop-xscreensaver", &stop_xscreensaver, CONF_TYPE_FLAG, 0, 0, 1, NULL},
- {"fstype", &vo_fstype_list, CONF_TYPE_STRING_LIST, 0, 0, 0, NULL},
+ OPT_MAKE_FLAGS("stop-xscreensaver", vo_stop_screensaver, 0),
+ OPT_STRINGLIST("fstype", vo_fstype_list, 0),
#endif
{"heartbeat-cmd", &heartbeat_cmd, CONF_TYPE_STRING, 0, 0, 0, NULL},
{"mouseinput", &vo_nomouse_input, CONF_TYPE_FLAG, 0, 1, 0, NULL},
diff --git a/core/defaultopts.c b/core/defaultopts.c
index a7da8bb4e3..d0205cb3d3 100644
--- a/core/defaultopts.c
+++ b/core/defaultopts.c
@@ -25,6 +25,7 @@ void set_default_mplayer_options(struct MPOpts *opts)
.vo_gamma_contrast = 1000,
.vo_gamma_saturation = 1000,
.vo_gamma_hue = 1000,
+ .vo_stop_screensaver = 1,
.osd_level = 1,
.osd_duration = 1000,
.loop_times = -1,
diff --git a/core/mplayer.c b/core/mplayer.c
index bdebd3bab2..8aba5517fd 100644
--- a/core/mplayer.c
+++ b/core/mplayer.c
@@ -3284,7 +3284,7 @@ static void run_playloop(struct MPContext *mpctx)
vo_check_events(vo);
#ifdef CONFIG_X11
- if (stop_xscreensaver && vo->x11) {
+ if (vo->x11) {
xscreensaver_heartbeat(vo->x11);
}
#endif
@@ -4299,7 +4299,7 @@ static bool handle_help_options(struct MPContext *mpctx)
opt_exit = 1;
}
#ifdef CONFIG_X11
- if (vo_fstype_list && strcmp(vo_fstype_list[0], "help") == 0) {
+ if (opts->vo_fstype_list && strcmp(opts->vo_fstype_list[0], "help") == 0) {
fstype_help();
mp_msg(MSGT_FIXME, MSGL_FIXME, "\n");
opt_exit = 1;
diff --git a/core/options.h b/core/options.h
index d1c58fdda9..10eb7135fd 100644
--- a/core/options.h
+++ b/core/options.h
@@ -35,6 +35,8 @@ typedef struct MPOpts {
int requested_input_range;
int requested_output_range;
int cursor_autohide_delay;
+ char** vo_fstype_list;
+ int vo_stop_screensaver;
// ranges -100 - 100, 1000 if the vo default should be used
int vo_gamma_gamma;