[grilo-plugins/0.2.x] local-metadata: Fix getting thumbnails for videos



commit 54b71b424df15cf8d729ebbb877d26161d1b422a
Author: Bastien Nocera <hadess hadess net>
Date:   Mon Jun 27 14:11:52 2016 +0200

    local-metadata: Fix getting thumbnails for videos
    
    a45fd44 removed the title parsing code, but accidentally removed the
    ability to get the thumbnail path for videos at the same time.
    
    Conflicts:
        src/local-metadata/grl-local-metadata.c
    
    https://bugzilla.gnome.org/show_bug.cgi?id=768093

 src/local-metadata/grl-local-metadata.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/local-metadata/grl-local-metadata.c b/src/local-metadata/grl-local-metadata.c
index 8c4a09c..21e2b11 100644
--- a/src/local-metadata/grl-local-metadata.c
+++ b/src/local-metadata/grl-local-metadata.c
@@ -597,7 +597,7 @@ grl_local_metadata_source_may_resolve (GrlSource *source,
                                        GrlKeyID key_id,
                                        GList **missing_keys)
 {
-  if (!media || GRL_IS_MEDIA_VIDEO (media))
+  if (!media)
     return FALSE;
 
   if (GRL_IS_MEDIA_AUDIO (media)) {
@@ -628,7 +628,7 @@ grl_local_metadata_source_may_resolve (GrlSource *source,
     return FALSE;
   }
 
-  if (GRL_IS_MEDIA_IMAGE (media)) {
+  if (GRL_IS_MEDIA_IMAGE (media) || GRL_IS_MEDIA_VIDEO (media)) {
     if (key_id != GRL_METADATA_KEY_THUMBNAIL)
       return FALSE;
     if (!grl_data_has_key (GRL_DATA (media), GRL_METADATA_KEY_URL))
@@ -687,7 +687,7 @@ grl_local_metadata_source_resolve (GrlSource *source,
 
   GRL_DEBUG ("\ttrying to resolve for: %s", grl_media_get_url (rs->media));
 
-  if (GRL_IS_MEDIA_IMAGE (rs->media)) {
+  if (GRL_IS_MEDIA_IMAGE (rs->media) || GRL_IS_MEDIA_VIDEO (rs->media)) {
     resolve_image (data, flags);
   } else if (GRL_IS_MEDIA_AUDIO (rs->media)) {
     /* Try for a per-track thumbnail first; we'll fall back to album art


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]