[vlc-devel] commit: Rename directx-wallpaper to video-wallpaper ( Rémi Denis-Courmont )
git version control
git at videolan.org
Sat Dec 26 21:08:14 CET 2009
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Dec 26 21:58:31 2009 +0200| [1d288a105d764cf9575c884d540f3135273f9fb5] | committer: Rémi Denis-Courmont
Rename directx-wallpaper to video-wallpaper
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=1d288a105d764cf9575c884d540f3135273f9fb5
---
modules/control/hotkeys.c | 4 +--
modules/gui/qt4/components/simple_preferences.cpp | 2 +-
modules/gui/qt4/menus.cpp | 4 +-
modules/video_output/msw/directx.c | 23 ++++++--------------
src/libvlc-module.c | 13 ++++++++++-
5 files changed, 22 insertions(+), 24 deletions(-)
diff --git a/modules/control/hotkeys.c b/modules/control/hotkeys.c
index bdd6b7f..8b12520 100644
--- a/modules/control/hotkeys.c
+++ b/modules/control/hotkeys.c
@@ -259,15 +259,13 @@ static int PutAction( intf_thread_t *p_intf, int i_action )
}
break;
-#ifdef WIN32
case ACTIONID_WALLPAPER:
{ /* FIXME: this is invalid if not using DirectX output!!! */
vlc_object_t *obj = p_vout ? VLC_OBJECT(p_vout)
: VLC_OBJECT(p_playlist);
- var_ToggleBool( obj, "directx-wallpaper" );
+ var_ToggleBool( obj, "video-wallpaper" );
break;
}
-#endif
/* Playlist actions */
case ACTIONID_LOOP:
diff --git a/modules/gui/qt4/components/simple_preferences.cpp b/modules/gui/qt4/components/simple_preferences.cpp
index 435529b..929dba5 100644
--- a/modules/gui/qt4/components/simple_preferences.cpp
+++ b/modules/gui/qt4/components/simple_preferences.cpp
@@ -199,8 +199,8 @@ SPrefsPanel::SPrefsPanel( intf_thread_t *_p_intf, QWidget *_parent,
CONFIG_GENERIC( "skip-frames" , Bool, NULL, skipFrames );
CONFIG_GENERIC( "vout", Module, ui.voutLabel, outputModule );
+ CONFIG_GENERIC( "video-wallpaper" , Bool , NULL, wallpaperMode );
#ifdef WIN32
- CONFIG_GENERIC( "directx-wallpaper" , Bool , NULL, wallpaperMode );
CONFIG_GENERIC( "directx-device", StringList, ui.dxDeviceLabel,
dXdisplayDevice );
CONFIG_GENERIC( "directx-hw-yuv", Bool, NULL, hwYUVBox );
diff --git a/modules/gui/qt4/menus.cpp b/modules/gui/qt4/menus.cpp
index cc43536..776835e 100644
--- a/modules/gui/qt4/menus.cpp
+++ b/modules/gui/qt4/menus.cpp
@@ -220,8 +220,8 @@ static int VideoAutoMenuBuilder( vout_thread_t *p_object,
PUSH_INPUTVAR( "spu-es" );
PUSH_VAR( "fullscreen" );
PUSH_VAR( "video-on-top" );
+ PUSH_VAR( "video-wallpaper" );
#ifdef WIN32
- PUSH_VAR( "directx-wallpaper" );
PUSH_VAR( "direct3d-desktop" );
#endif
PUSH_VAR( "video-snapshot" );
@@ -561,8 +561,8 @@ QMenu *QVLCMenu::VideoMenu( intf_thread_t *p_intf, QMenu *current )
ACT_ADDCHECK( current, "fullscreen", qtr( "&Fullscreen" ) );
ACT_ADDCHECK( current, "video-on-top", qtr( "Always &On Top" ) );
+ ACT_ADDCHECK( current, "video-wallpaper", qtr( "DirectX Wallpaper" ) );
#ifdef WIN32
- ACT_ADDCHECK( current, "directx-wallpaper", qtr( "DirectX Wallpaper" ) );
ACT_ADDCHECK( current, "direct3d-desktop", qtr( "Direct3D Desktop mode" ) );
#endif
ACT_ADD( current, "video-snapshot", qtr( "Sna&pshot" ) );
diff --git a/modules/video_output/msw/directx.c b/modules/video_output/msw/directx.c
index c2c7fc1..82bbd4f 100644
--- a/modules/video_output/msw/directx.c
+++ b/modules/video_output/msw/directx.c
@@ -155,12 +155,6 @@ BOOL WINAPI DirectXEnumCallback2( GUID* p_guid, LPTSTR psz_desc,
"window to open on. For example, \"\\\\.\\DISPLAY1\" or " \
"\"\\\\.\\DISPLAY2\"." )
-#define WALLPAPER_TEXT N_("Enable wallpaper mode ")
-#define WALLPAPER_LONGTEXT N_( \
- "The wallpaper mode allows you to display the video as the desktop " \
- "background. Note that this feature only works in overlay mode and " \
- "the desktop must not already have a wallpaper." )
-
static const char *const ppsz_dev[] = { "" };
static const char *const ppsz_dev_text[] = { N_("Default") };
@@ -180,9 +174,6 @@ vlc_module_begin ()
change_string_list( ppsz_dev, ppsz_dev_text, FindDevicesCallback )
change_action_add( FindDevicesCallback, N_("Refresh list") )
- add_bool( "directx-wallpaper", false, NULL, WALLPAPER_TEXT, WALLPAPER_LONGTEXT,
- true )
-
set_description( N_("DirectX (DirectDraw) video output") )
set_capability( "video output", 100 )
add_shortcut( "directx" )
@@ -270,11 +261,11 @@ static int OpenVideo( vlc_object_t *p_this )
/* Variable to indicate if the window should be on top of others */
/* Trigger a callback right now */
- var_Create( p_vout, "directx-wallpaper", VLC_VAR_BOOL|VLC_VAR_DOINHERIT );
+ var_Create( p_vout, "video-wallpaper", VLC_VAR_BOOL|VLC_VAR_DOINHERIT );
val.psz_string = _("Wallpaper");
- var_Change( p_vout, "directx-wallpaper", VLC_VAR_SETTEXT, &val, NULL );
- var_AddCallback( p_vout, "directx-wallpaper", WallpaperCallback, NULL );
- var_TriggerCallback( p_vout, "directx-wallpaper" );
+ var_Change( p_vout, "video-wallpaper", VLC_VAR_SETTEXT, &val, NULL );
+ var_AddCallback( p_vout, "video-wallpaper", WallpaperCallback, NULL );
+ var_TriggerCallback( p_vout, "video-wallpaper" );
return VLC_SUCCESS;
@@ -425,7 +416,7 @@ static void CloseVideo( vlc_object_t *p_this )
vout_thread_t * p_vout = (vout_thread_t *)p_this;
/* Make sure the wallpaper is restored */
- var_DelCallback( p_vout, "directx-wallpaper", WallpaperCallback, NULL );
+ var_DelCallback( p_vout, "video-wallpaper", WallpaperCallback, NULL );
SwitchWallpaperMode( p_vout, false );
CommonClean( p_vout );
@@ -1899,8 +1890,8 @@ static int WallpaperCallback( vlc_object_t *p_this, char const *psz_cmd,
{
/* Modify playlist as well because the vout might have to be
* restarted */
- var_Create( p_playlist, "directx-wallpaper", VLC_VAR_BOOL );
- var_Set( p_playlist, "directx-wallpaper", newval );
+ var_Create( p_playlist, "video-wallpaper", VLC_VAR_BOOL );
+ var_Set( p_playlist, "video-wallpaper", newval );
pl_Release( p_vout );
}
diff --git a/src/libvlc-module.c b/src/libvlc-module.c
index c8b95f2..396cfea 100644
--- a/src/libvlc-module.c
+++ b/src/libvlc-module.c
@@ -439,6 +439,11 @@ static const char *const ppsz_align_descriptions[] =
#define VIDEO_ON_TOP_LONGTEXT N_( \
"Always place the video window on top of other windows." )
+#define WALLPAPER_TEXT N_("Enable wallpaper mode ")
+#define WALLPAPER_LONGTEXT N_( \
+ "The wallpaper mode allows you to display the video as the desktop " \
+ "background." )
+
#define VIDEO_TITLE_SHOW_TEXT N_("Show media title on video")
#define VIDEO_TITLE_SHOW_LONGTEXT N_( \
"Display the title of the video on top of the movie.")
@@ -1485,8 +1490,7 @@ static const char *const ppsz_albumart_descriptions[] =
#define WALLPAPER_KEY_TEXT N_("Toggle wallpaper mode in video output")
#define WALLPAPER_KEY_LONGTEXT N_( \
- "Toggle wallpaper mode in video output. Only works with the directx " \
- "video output for the time being." )
+ "Toggle wallpaper mode in video output." )
#define MENU_ON_KEY_TEXT N_("Display OSD menu on top of video output")
#define MENU_ON_KEY_LONGTEXT N_("Display OSD menu on top of video output")
@@ -1657,6 +1661,11 @@ vlc_module_begin ()
#endif
add_bool( "video-on-top", 0, NULL, VIDEO_ON_TOP_TEXT,
VIDEO_ON_TOP_LONGTEXT, false )
+ add_bool( "video-wallpaper", false, NULL, WALLPAPER_TEXT,
+ WALLPAPER_LONGTEXT, false )
+#ifdef WIN32
+ add_deprecated_alias( "directx-wallpaper" )
+#endif
add_bool( "disable-screensaver", true, NULL, SS_TEXT, SS_LONGTEXT,
true )
More information about the vlc-devel
mailing list