[PATCH] last-fm: add extra large thumbnails
- From: lionel g landwerlin linux intel com
- To: grilo-list gnome org
- Subject: [PATCH] last-fm: add extra large thumbnails
- Date: Mon, 7 Mar 2011 10:05:43 +0000
From: Lionel Landwerlin <lionel g landwerlin linux intel com>
Signed-off-by: Lionel Landwerlin <lionel g landwerlin linux intel com>
---
src/metadata/lastfm-albumart/grl-lastfm-albumart.c | 11 ++++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/src/metadata/lastfm-albumart/grl-lastfm-albumart.c b/src/metadata/lastfm-albumart/grl-lastfm-albumart.c
index d25b35a..ab4913b 100644
--- a/src/metadata/lastfm-albumart/grl-lastfm-albumart.c
+++ b/src/metadata/lastfm-albumart/grl-lastfm-albumart.c
@@ -45,6 +45,7 @@ GRL_LOG_DOMAIN_STATIC(lastfm_albumart_log_domain);
#define LASTFM_XML_COVER_MEDIUM "/album/coverart/medium"
#define LASTFM_XML_COVER_LARGE "/album/coverart/large"
#define LASTFM_XML_COVER_SMALL "/album/coverart/small"
+#define LASTFM_XML_COVER_EXTRA "/album/coverart/extralarge"
/* ------- Pluging Info -------- */
@@ -216,7 +217,7 @@ read_done_cb (GObject *source_object,
return;
}
- image = xml_get_image (content, LASTFM_XML_COVER_MEDIUM);
+ image = xml_get_image (content, LASTFM_XML_COVER_EXTRA);
if (image) {
relkeys = grl_related_keys_new_with_keys (GRL_METADATA_KEY_THUMBNAIL, image,
NULL);
@@ -232,6 +233,14 @@ read_done_cb (GObject *source_object,
g_free (image);
}
+ image = xml_get_image (content, LASTFM_XML_COVER_MEDIUM);
+ if (image) {
+ relkeys = grl_related_keys_new_with_keys (GRL_METADATA_KEY_THUMBNAIL, image,
+ NULL);
+ grl_data_add_related_keys (GRL_DATA (rs->media), relkeys);
+ g_free (image);
+ }
+
image = xml_get_image (content, LASTFM_XML_COVER_SMALL);
if (image) {
relkeys = grl_related_keys_new_with_keys (GRL_METADATA_KEY_THUMBNAIL, image,
--
1.7.4.1
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]