]> git.sesse.net Git - vlc/commitdiff
Remember random/loop/repeat
authorClément Stenac <zorglub@videolan.org>
Sat, 2 Sep 2006 22:33:44 +0000 (22:33 +0000)
committerClément Stenac <zorglub@videolan.org>
Sat, 2 Sep 2006 22:33:44 +0000 (22:33 +0000)
modules/gui/qt4/playlist_model.cpp
src/libvlc.h
test/native/url.c

index 3e295310ce48ec4015cdf13074762cf5536aa244..58d84412aa1367b2f113fe58283c4a456a270d71 100644 (file)
@@ -357,14 +357,17 @@ bool PLModel::hasLoop()
 void PLModel::setLoop( bool on )
 {
     var_SetBool( p_playlist, "loop", on ? VLC_TRUE:VLC_FALSE );
+    config_PutInt( p_playlist, "loop", on ? 1: 0 );
 }
 void PLModel::setRepeat( bool on )
 {
     var_SetBool( p_playlist, "repeat", on ? VLC_TRUE:VLC_FALSE );
+    config_PutInt( p_playlist, "repeat", on ? 1: 0 );
 }
 void PLModel::setRandom( bool on )
 {
     var_SetBool( p_playlist, "random", on ? VLC_TRUE:VLC_FALSE );
+    config_PutInt( p_playlist, "random", on ? 1: 0 );
 }
 
 /************************* Lookups *****************************/
index 26fe6f268c7c0c765f8ca2bbc299cb1ce667a959..80b02ec8c00104d761521ae827d7a258678d33c6 100644 (file)
@@ -1618,10 +1618,13 @@ vlc_module_begin();
     add_category_hint( N_("Playlist"), PLAYLIST_CAT_LONGTEXT , VLC_FALSE );
     add_bool( "random", 0, NULL, RANDOM_TEXT, RANDOM_LONGTEXT, VLC_FALSE );
         change_short('Z');
+        change_autosave();
     add_bool( "loop", 0, NULL, LOOP_TEXT, LOOP_LONGTEXT, VLC_FALSE );
         change_short('L');
+        change_autosave();
     add_bool( "repeat", 0, NULL, REPEAT_TEXT, REPEAT_LONGTEXT, VLC_FALSE );
         change_short('R');
+        change_autosave();
     add_bool( "play-and-exit", 0, NULL, PAE_TEXT, PAE_LONGTEXT, VLC_FALSE );
     add_bool( "play-and-stop", 0, NULL, PAS_TEXT, PAS_LONGTEXT, VLC_FALSE );
     add_bool( "media-library", 1, NULL, ML_TEXT, ML_LONGTEXT, VLC_FALSE );
index 87fc73c1008c691d681c80f9547a37b8a2211d30..6316939c8b91e1b7518aeeeb40d305c74db6fe71 100644 (file)
@@ -32,7 +32,6 @@ PyObject * test (conv_t f, const char *in, const char *out)
     printf ("\"%s\" -> \"%s\" ?\n", in, out);
     res = f(in);
     ASSERT( res != NULL, "NULL result" );
-    printf( "\n\"%s\"\n",res );
     ASSERT( strcmp( res, out ) == NULL, "" );
 
     Py_INCREF( Py_None );