Author: ayoung
Date: Wed Mar 28 02:24:32 2012
New Revision: 9684

URL: http://svn.slimdevices.com/jive?rev=9684&view=rev
Log:
Fixed bug 17937: Now Playing information can alternate between station and 
current-track titles at track skip 

Send an empty string as  the track title to jive in buffering messages. The 
player will not update the title in this case.

Modified:
    
7.8/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua

Modified: 
7.8/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua
URL: 
http://svn.slimdevices.com/jive/7.8/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua?rev=9684&r1=9683&r2=9684&view=diff
==============================================================================
--- 
7.8/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua
 (original)
+++ 
7.8/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua
 Wed Mar 28 02:24:32 2012
@@ -434,14 +434,16 @@
        local nowPlayingTrackInfoLines = 
jiveMain:getSkinParam("NOWPLAYING_TRACKINFO_LINES")
        local msgs = string.split("\n", text)
        if nowPlayingTrackInfoLines == 2 and self.artistalbumTitle then
-               --artistalbumTitle and trackTitle widgets are used as messaging 
widget
-               -- two line message means use artistAlbumTitle for line 1, 
trackTitle for line 2
                if #msgs > 1 then
+                       -- artistalbumTitle and trackTitle widgets are used as 
messaging widget
+                       -- two line message means use artistAlbumTitle for line 
1, trackTitle for line 2
+                       -- Bug 17937: leave the title alone if a zero-length 
title is provided
                        self.artistalbumTitle:setValue(msgs[1], duration)
-                       self.trackTitle:setValue(msgs[2], duration)
-               -- one line message means use trackTitle for line 1 and keep 
what is already on screen for artistalbumTitle
-               -- keeping existing artistalbumTitle text is important for 
multiple-showBriefly cases e.g., rebuffering messages
+                       if string.len(msgs[2]) > 0 then 
self.trackTitle:setValue(msgs[2], duration) end
                else
+                       -- one line message means use trackTitle for line 1 and 
keep what is already on screen for artistalbumTitle
+                       -- keeping existing artistalbumTitle text is important 
for multiple-showBriefly cases e.g., rebuffering messages
+                       -- awy: This may no longer be true.
                        self.trackTitle:setValue(msgs[1], duration)
                        
self.artistalbumTitle:setValue(self.artistalbumTitle:getValue(), duration) 
--keep any temporary text up for same duration to avoid flickering
                end

_______________________________________________
Jive-checkins mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/jive-checkins

Reply via email to