From bfe569b76ebc19263efbf717728a6da7c413cbac Mon Sep 17 00:00:00 2001 From: Uoti Urpala Date: Sat, 19 Apr 2008 07:45:16 +0300 Subject: Move vo_ontop to options struct Add a 'struct vo *vo' argument to the x11_common.c functions that access the variable so it's available as vo->opts->vo_ontop. To keep VOs using the old API working create a global vo variable that is set to the currently used old vo. "vo_ontop" will be #defined to "global_vo->opts->vo_ontop", and x11_common.h will add defines like the following when it is included by old VOs: #define vo_x11_ontop() vo_x11_ontop(global_vo) so that they will call the function according to the new declaration. --- cfg-mplayer.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cfg-mplayer.h') diff --git a/cfg-mplayer.h b/cfg-mplayer.h index 49b8ddccd4..9a07979cd1 100644 --- a/cfg-mplayer.h +++ b/cfg-mplayer.h @@ -101,8 +101,8 @@ const m_option_t mplayer_opts[]={ STRINGLIST("ao", audio_driver_list, 0), FLAG_ON("fixed-vo", fixed_vo, CONF_GLOBAL), FLAG_OFF("nofixed-vo", fixed_vo, CONF_GLOBAL), - {"ontop", &vo_ontop, CONF_TYPE_FLAG, 0, 0, 1, NULL}, - {"noontop", &vo_ontop, CONF_TYPE_FLAG, 0, 1, 0, NULL}, + FLAG_ON("ontop", vo_ontop, 0), + FLAG_OFF("noontop", vo_ontop, 0), {"rootwin", &vo_rootwin, CONF_TYPE_FLAG, 0, 0, 1, NULL}, {"border", &vo_border, CONF_TYPE_FLAG, 0, 0, 1, NULL}, {"noborder", &vo_border, CONF_TYPE_FLAG, 0, 1, 0, NULL}, -- cgit v1.2.3