[vlc-commits] Win32: Merge direct3d-desktop and video-wallpaper to fix usability issue
Jean-Baptiste Kempf
git at videolan.org
Mon Jan 9 18:37:57 CET 2012
vlc/vlc-1.2 | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Mon Jan 9 14:42:16 2012 +0100| [8b1e0416fd5ee3528c25f944ba2c67bcdc353391] | committer: Jean-Baptiste Kempf
Win32: Merge direct3d-desktop and video-wallpaper to fix usability issue
(cherry picked from commit 520e60b66c2747105a91222cf101bfc806cd55f9)
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.2.git/?a=commit;h=8b1e0416fd5ee3528c25f944ba2c67bcdc353391
---
modules/gui/qt4/menus.cpp | 7 -------
modules/video_output/msw/direct3d.c | 13 ++++++-------
src/video_output/vout_wrapper.c | 3 ---
3 files changed, 6 insertions(+), 17 deletions(-)
diff --git a/modules/gui/qt4/menus.cpp b/modules/gui/qt4/menus.cpp
index af2654d..4569a40 100644
--- a/modules/gui/qt4/menus.cpp
+++ b/modules/gui/qt4/menus.cpp
@@ -233,9 +233,6 @@ static int VideoAutoMenuBuilder( vout_thread_t *p_object,
PUSH_VAR( "fullscreen" );
PUSH_VAR( "video-on-top" );
PUSH_VAR( "video-wallpaper" );
-#ifdef WIN32
- PUSH_VAR( "direct3d-desktop" );
-#endif
PUSH_VAR( "video-snapshot" );
PUSH_VAR( "zoom" );
PUSH_VAR( "autoscale" );
@@ -648,10 +645,6 @@ QMenu *VLCMenuBar::VideoMenu( intf_thread_t *p_intf, QMenu *current, bool b_subt
addActionWithCheckbox( current, "fullscreen", qtr( "&Fullscreen" ) );
addActionWithCheckbox( current, "autoscale", qtr( "Always Fit &Window" ) );
addActionWithCheckbox( current, "video-on-top", qtr( "Always &on Top" ) );
-#ifdef WIN32
- addActionWithCheckbox( current, "direct3d-desktop", qtr( "Display on &Desktop" ) );
-#endif
-
addActionWithCheckbox( current, "video-wallpaper", qtr( "Set as Wall&paper" ) );
current->addSeparator();
diff --git a/modules/video_output/msw/direct3d.c b/modules/video_output/msw/direct3d.c
index a16ab22..0cf652e 100644
--- a/modules/video_output/msw/direct3d.c
+++ b/modules/video_output/msw/direct3d.c
@@ -70,7 +70,6 @@ vlc_module_begin ()
set_category(CAT_VIDEO)
set_subcategory(SUBCAT_VIDEO_VOUT)
- add_bool("direct3d-desktop", false, DESKTOP_TEXT, DESKTOP_LONGTEXT, true)
add_bool("direct3d-hw-blending", true, HW_BLENDING_TEXT, HW_BLENDING_LONGTEXT, true)
set_capability("vout display", 240)
@@ -156,7 +155,7 @@ static int Open(vlc_object_t *object)
return VLC_EGENERIC;
}
- sys->use_desktop = var_CreateGetBool(vd, "direct3d-desktop");
+ sys->use_desktop = var_CreateGetBool(vd, "video-wallpaper");
sys->reset_device = false;
sys->reset_device = false;
sys->allow_hw_yuv = var_CreateGetBool(vd, "directx-hw-yuv");
@@ -202,8 +201,8 @@ static int Open(vlc_object_t *object)
vlc_value_t val;
val.psz_string = _("Desktop");
- var_Change(vd, "direct3d-desktop", VLC_VAR_SETTEXT, &val, NULL);
- var_AddCallback(vd, "direct3d-desktop", DesktopCallback, NULL);
+ var_Change(vd, "video-wallpaper", VLC_VAR_SETTEXT, &val, NULL);
+ var_AddCallback(vd, "video-wallpaper", DesktopCallback, NULL);
/* Setup vout_display now that everything is fine */
vd->fmt = fmt;
@@ -235,7 +234,7 @@ static void Close(vlc_object_t *object)
{
vout_display_t * vd = (vout_display_t *)object;
- var_DelCallback(vd, "direct3d-desktop", DesktopCallback, NULL);
+ var_DelCallback(vd, "video-wallpaper", DesktopCallback, NULL);
vlc_mutex_destroy(&vd->sys->lock);
Direct3DClose(vd);
@@ -1439,8 +1438,8 @@ static int DesktopCallback(vlc_object_t *object, char const *psz_cmd,
playlist_t *p_playlist = pl_Get(vd);
/* Modify playlist as well because the vout might have to be
* restarted */
- var_Create(p_playlist, "direct3d-desktop", VLC_VAR_BOOL);
- var_SetBool(p_playlist, "direct3d-desktop", newval.b_bool);
+ var_Create(p_playlist, "video-wallpaper", VLC_VAR_BOOL);
+ var_SetBool(p_playlist, "video-wallpaper", newval.b_bool);
}
return VLC_SUCCESS;
}
diff --git a/src/video_output/vout_wrapper.c b/src/video_output/vout_wrapper.c
index fc6072f..d3a2855 100644
--- a/src/video_output/vout_wrapper.c
+++ b/src/video_output/vout_wrapper.c
@@ -74,8 +74,6 @@ int vout_OpenWrapper(vout_thread_t *vout,
/* */
#ifdef WIN32
- var_Create(vout, "direct3d-desktop", VLC_VAR_BOOL|VLC_VAR_DOINHERIT);
- var_AddCallback(vout, "direct3d-desktop", Forward, NULL);
var_Create(vout, "video-wallpaper", VLC_VAR_BOOL|VLC_VAR_DOINHERIT);
var_AddCallback(vout, "video-wallpaper", Forward, NULL);
#endif
@@ -94,7 +92,6 @@ void vout_CloseWrapper(vout_thread_t *vout, vout_display_state_t *state)
vout_thread_sys_t *sys = vout->p;
#ifdef WIN32
- var_DelCallback(vout, "direct3d-desktop", Forward, NULL);
var_DelCallback(vout, "video-wallpaper", Forward, NULL);
#endif
sys->decoder_pool = NULL; /* FIXME remove */
More information about the vlc-commits
mailing list