[sound-juicer] Simplify track numbering
- From: Bastien Nocera <hadess src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [sound-juicer] Simplify track numbering
- Date: Tue, 27 Oct 2009 16:03:52 +0000 (UTC)
commit 335ac35dea4ef5337673af449ba382a543f22ede
Author: Bastien Nocera <hadess hadess net>
Date: Tue Oct 27 16:01:17 2009 +0000
Simplify track numbering
libjuicer/sj-metadata-gvfs.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/libjuicer/sj-metadata-gvfs.c b/libjuicer/sj-metadata-gvfs.c
index fc41d51..8ccdd4c 100644
--- a/libjuicer/sj-metadata-gvfs.c
+++ b/libjuicer/sj-metadata-gvfs.c
@@ -76,7 +76,7 @@ gvfs_list_albums (SjMetadata *metadata, char **url, GError **error)
GFile *file = NULL;
GFileInfo *info;
GFileEnumerator *e;
- guint i = 0;
+ guint i = 1;
g_return_val_if_fail (SJ_IS_METADATA_GVFS (metadata), NULL);
@@ -119,11 +119,11 @@ gvfs_list_albums (SjMetadata *metadata, char **url, GError **error)
for (info = g_file_enumerator_next_file (e, NULL, NULL) ;
info != NULL ;
- info = g_file_enumerator_next_file (e, NULL, NULL)) {
+ info = g_file_enumerator_next_file (e, NULL, NULL), i++) {
TrackDetails *track;
track = g_new0 (TrackDetails, 1);
- track->number = i++;
+ track->number = i;
track->title = g_strdup (g_file_info_get_attribute_string (info, "xattr::org.gnome.audio.title"));
if (track->title == NULL)
track->title = g_strdup_printf (_("Track %d"), i);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]