changeset 33898:67790ce1185e

Provide track information for playlists. The documentation says so.
author ib
date Fri, 12 Aug 2011 16:31:18 +0000
parents e0d211c62cf7
children e3036c93f08f
files gui/interface.c gui/ui/actions.c gui/ui/main.c
diffstat 3 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/gui/interface.c	Fri Aug 12 15:25:30 2011 +0000
+++ b/gui/interface.c	Fri Aug 12 16:31:18 2011 +0000
@@ -790,6 +790,7 @@
             guiInfo.NewPlay    = GUI_FILE_NEW;
             nfree(guiInfo.AudioFilename);
             nfree(guiInfo.SubtitleFilename);
+            guiInfo.Track++;
         } else {
             if (guiInfo.NewPlay == GUI_FILE_NEW)
                 break;
--- a/gui/ui/actions.c	Fri Aug 12 15:25:30 2011 +0000
+++ b/gui/ui/actions.c	Fri Aug 12 16:31:18 2011 +0000
@@ -346,6 +346,7 @@
         if (prev) {
             uiSetFileName(prev->path, prev->name, STREAMTYPE_FILE);
             uiGotoTheNext = 0;
+            guiInfo.Track--;
             break;
         }
 
@@ -401,6 +402,7 @@
         if (next) {
             uiSetFileName(next->path, next->name, STREAMTYPE_FILE);
             uiGotoTheNext = 0;
+            guiInfo.Track++;
             break;
         }
 
--- a/gui/ui/main.c	Fri Aug 12 15:25:30 2011 +0000
+++ b/gui/ui/main.c	Fri Aug 12 16:31:18 2011 +0000
@@ -201,6 +201,8 @@
 	  case STREAMTYPE_STREAM:
 	  case STREAMTYPE_FILE:
 	       guiInfoMediumClear( CLEAR_ALL - CLEAR_FILE );
+	       if ( !guiInfo.Track )
+	         guiInfo.Track=1;
 	       guiInfo.NewPlay=GUI_FILE_NEW;
 	       break;
 #ifdef CONFIG_VCD