[PATCH 5/6] local-metadata: adapt to the new GrlKeyID type
- From: Guillaume Emont <guijemont igalia com>
- To: grilo-list gnome org
- Cc: Guillaume Emont <guijemont igalia com>
- Subject: [PATCH 5/6] local-metadata: adapt to the new GrlKeyID type
- Date: Wed, 4 May 2011 19:20:44 +0200
---
src/metadata/local-metadata/grl-local-metadata.c | 19 ++++++++++---------
1 files changed, 10 insertions(+), 9 deletions(-)
diff --git a/src/metadata/local-metadata/grl-local-metadata.c b/src/metadata/local-metadata/grl-local-metadata.c
index b356f25..d374bc8 100644
--- a/src/metadata/local-metadata/grl-local-metadata.c
+++ b/src/metadata/local-metadata/grl-local-metadata.c
@@ -614,24 +614,25 @@ has_compatible_media_url (GrlMedia *media)
static resolution_flags_t
get_resolution_flags (GList *keys)
{
- GList *key = keys;
+ GList *iter = keys;
resolution_flags_t flags = 0;
- while (key != NULL) {
- if (key->data == GRL_METADATA_KEY_TITLE)
+ while (iter != NULL) {
+ GrlKeyID key = GRLPOINTER_TO_KEYID (iter->data);
+ if (key == GRL_METADATA_KEY_TITLE)
flags |= FLAG_VIDEO_TITLE;
- else if (key->data == GRL_METADATA_KEY_SHOW)
+ else if (key == GRL_METADATA_KEY_SHOW)
flags |= FLAG_VIDEO_SHOWNAME;
- else if (key->data == GRL_METADATA_KEY_DATE)
+ else if (key == GRL_METADATA_KEY_DATE)
flags |= FLAG_VIDEO_DATE;
- else if (key->data == GRL_METADATA_KEY_SEASON)
+ else if (key == GRL_METADATA_KEY_SEASON)
flags |= FLAG_VIDEO_SEASON;
- else if (key->data == GRL_METADATA_KEY_EPISODE)
+ else if (key == GRL_METADATA_KEY_EPISODE)
flags |= FLAG_VIDEO_EPISODE;
- else if (key->data == GRL_METADATA_KEY_THUMBNAIL)
+ else if (key == GRL_METADATA_KEY_THUMBNAIL)
flags |= FLAG_THUMBNAIL;
- key = key->next;
+ iter = iter->next;
}
return flags;
--
1.7.1
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]