discomfitor pushed a commit to branch master.

http://git.enlightenment.org/apps/empc.git/commit/?id=2157ed3e66d862ecdfe45e2426155253028c84a6

commit 2157ed3e66d862ecdfe45e2426155253028c84a6
Author: zmike <michael.blumenkra...@gmail.com>
Date:   Tue Sep 8 22:27:35 2015 -0400

    force updates on current song info display when queue list updates
    
    should improve handling when metadata for current song is changed
---
 src/bin/empc.c | 16 +++++++++++++++-
 1 file changed, 15 insertions(+), 1 deletion(-)

diff --git a/src/bin/empc.c b/src/bin/empc.c
index b81f0dc..84792f1 100644
--- a/src/bin/empc.c
+++ b/src/bin/empc.c
@@ -2896,7 +2896,21 @@ queue_list_handler(Eina_Value *value, Eina_Bool cached)
              eina_hash_add(empd_current_queue, &so->songid, it);
           }
         if (so->songid == empd_songid)
-          empd_song_item = it;
+          {
+             Eina_Bool title;
+
+             empd_song_item = it;
+             /* force updates in case song info has changed */
+             if ((so->artist != empd_song_artist) || (so->album != 
empd_song_album))
+               bg_update(bg_next_get(), so->artist, so->album, so->uri);
+             eina_stringshare_refplace(&empd_song_album, so->album);
+             title = eina_stringshare_refplace(&empd_song_title, so->title);
+             if (title || (empd_song_track != so->track))
+               elm_object_signal_emit(layout, "empc,title,change,next", 
"empc");
+             empd_song_track = so->track;
+             if (eina_stringshare_refplace(&empd_song_artist, so->artist) || 
title)
+               title_update();
+          }
         if ((album != so->album) || (artist != so->artist))
           {
              if (itl)

-- 


Reply via email to