[MPlayer-cvslog] r35582 - in trunk/gui: interface.c ui/gtk/playlist.c

ib subversion at mplayerhq.hu
Mon Dec 3 15:44:32 CET 2012


Author: ib
Date: Mon Dec  3 15:44:32 2012
New Revision: 35582

Log:
Provide a number of tracks information for files in playlists.

Modified:
   trunk/gui/interface.c
   trunk/gui/ui/gtk/playlist.c

Modified: trunk/gui/interface.c
==============================================================================
--- trunk/gui/interface.c	Mon Dec  3 15:43:42 2012	(r35581)
+++ trunk/gui/interface.c	Mon Dec  3 15:44:32 2012	(r35582)
@@ -241,6 +241,7 @@ void guiInit(void)
 
     if (playlist && !filename) {
         uiSetFile(playlist->path, playlist->name, STREAMTYPE_FILE);
+        guiInfo.Tracks = (int)listMgr(PLAYLIST_ITEM_GET_POS, 0);
         guiInfo.Track = 1;
         filename      = NULL; // don't start playing
     }
@@ -608,6 +609,7 @@ int gui(int what, void *data)
         switch (guiInfo.StreamType) {
         case STREAMTYPE_FILE:
         case STREAMTYPE_STREAM:
+            guiInfo.Tracks = (int)listMgr(PLAYLIST_ITEM_GET_POS, 0);
             break;
 
         case STREAMTYPE_CDDA:

Modified: trunk/gui/ui/gtk/playlist.c
==============================================================================
--- trunk/gui/ui/gtk/playlist.c	Mon Dec  3 15:43:42 2012	(r35581)
+++ trunk/gui/ui/gtk/playlist.c	Mon Dec  3 15:44:32 2012	(r35582)
@@ -236,6 +236,7 @@ static void plButtonReleased( GtkButton 
 	    guiInfo.PlaylistNext = (curr.name ? 0 : 1);
 	    guiInfo.Track = 1;
 	   }
+	  guiInfo.Tracks = (int) listMgr( PLAYLIST_ITEM_GET_POS,NULL );
 	 }
 	else if (isPlaylistStreamtype && !guiInfo.Playing) uiUnsetFile();
 	free(curr.path);


More information about the MPlayer-cvslog mailing list