[vlc-devel] commit: record: more specific record directories (video/music/other) ( Erwan Tulou )

git version control git at videolan.org
Sat Aug 29 21:00:00 CEST 2009


vlc | branch: master | Erwan Tulou <erwan10 at videolan.org> | Sat Aug 29 20:24:08 2009 +0200| [576927efae2b70f46157bfb2850e10b38f5d178d] | committer: Erwan Tulou 

record: more specific record directories (video/music/other)

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=576927efae2b70f46157bfb2850e10b38f5d178d
---

 src/input/es_out.c |   10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/src/input/es_out.c b/src/input/es_out.c
index ca866a7..500f49d 100644
--- a/src/input/es_out.c
+++ b/src/input/es_out.c
@@ -466,8 +466,14 @@ static int EsOutSetRecord(  es_out_t *out, bool b_record )
     {
         char *psz_path = var_CreateGetNonEmptyString( p_input, "input-record-path" );
         if( !psz_path )
-            /* TODO: autoselect video or music dir ? */
-            psz_path = config_GetUserDir(VLC_DOWNLOAD_DIR);
+        {
+            if( var_CountChoices( p_input, "video-es" ) )
+                psz_path = config_GetUserDir( VLC_VIDEOS_DIR );
+            else if( var_CountChoices( p_input, "audio-es" ) )
+                psz_path = config_GetUserDir( VLC_MUSIC_DIR );
+            else
+                psz_path = config_GetUserDir( VLC_DOWNLOAD_DIR );
+        }
 
         char *psz_sout = NULL;  // TODO conf
 




More information about the vlc-devel mailing list