[tracker] tracker-extract: vorbis: Group the INSERTs for MusicAlbumDisc together
- From: Philip Van Hoof <pvanhoof src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker] tracker-extract: vorbis: Group the INSERTs for MusicAlbumDisc together
- Date: Thu, 9 Dec 2010 14:04:20 +0000 (UTC)
commit 4b40886feda5855651e7fe2a618520cac3d21a88
Author: Philip Van Hoof <philip codeminded be>
Date: Thu Dec 9 15:01:37 2010 +0100
tracker-extract: vorbis: Group the INSERTs for MusicAlbumDisc together
src/tracker-extract/tracker-extract-vorbis.c | 18 +++++-------------
1 files changed, 5 insertions(+), 13 deletions(-)
---
diff --git a/src/tracker-extract/tracker-extract-vorbis.c b/src/tracker-extract/tracker-extract-vorbis.c
index d2d5bfd..4e68b2d 100644
--- a/src/tracker-extract/tracker-extract-vorbis.c
+++ b/src/tracker-extract/tracker-extract-vorbis.c
@@ -80,7 +80,7 @@ static TrackerExtractData extract_data[] = {
static gchar *
ogg_get_comment (vorbis_comment *vc,
- gchar *label)
+ const gchar *label)
{
gchar *tag;
gchar *utf_tag;
@@ -270,12 +270,6 @@ extract_vorbis (const char *uri,
vd.album,
vd.disc_number ? atoi(vd.disc_number) : 1);
- tracker_sparql_builder_insert_open (preupdate, NULL);
- tracker_sparql_builder_subject_iri (preupdate, album_disc_uri);
- tracker_sparql_builder_predicate (preupdate, "a");
- tracker_sparql_builder_object (preupdate, "nmm:MusicAlbumDisc");
- tracker_sparql_builder_insert_close (preupdate);
-
tracker_sparql_builder_delete_open (preupdate, NULL);
tracker_sparql_builder_subject_iri (preupdate, album_disc_uri);
tracker_sparql_builder_predicate (preupdate, "nmm:setNumber");
@@ -287,12 +281,6 @@ extract_vorbis (const char *uri,
tracker_sparql_builder_object_variable (preupdate, "unknown");
tracker_sparql_builder_where_close (preupdate);
- tracker_sparql_builder_insert_open (preupdate, NULL);
- tracker_sparql_builder_subject_iri (preupdate, album_disc_uri);
- tracker_sparql_builder_predicate (preupdate, "nmm:setNumber");
- tracker_sparql_builder_object_int64 (preupdate, vd.disc_number ? atoi (vd.disc_number) : 1);
- tracker_sparql_builder_insert_close (preupdate);
-
tracker_sparql_builder_delete_open (preupdate, NULL);
tracker_sparql_builder_subject_iri (preupdate, album_disc_uri);
tracker_sparql_builder_predicate (preupdate, "nmm:albumDiscAlbum");
@@ -306,6 +294,10 @@ extract_vorbis (const char *uri,
tracker_sparql_builder_insert_open (preupdate, NULL);
tracker_sparql_builder_subject_iri (preupdate, album_disc_uri);
+ tracker_sparql_builder_predicate (preupdate, "a");
+ tracker_sparql_builder_object (preupdate, "nmm:MusicAlbumDisc");
+ tracker_sparql_builder_predicate (preupdate, "nmm:setNumber");
+ tracker_sparql_builder_object_int64 (preupdate, vd.disc_number ? atoi (vd.disc_number) : 1);
tracker_sparql_builder_predicate (preupdate, "nmm:albumDiscAlbum");
tracker_sparql_builder_object_iri (preupdate, uri);
tracker_sparql_builder_insert_close (preupdate);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]