Author: bklaas
Date: Thu Mar  4 11:39:11 2010
New Revision: 8633

URL: http://svn.slimdevices.com/jive?rev=8633&view=rev
Log:
Fixed Bug: 13607
Description: on track change NP window is now being recreated as a workaround 
for making sure windowListeners still work.
When replacing the window, make sure to update the repeat and shuffle buttons 
as needed for the new window.

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

Modified: 
7.5/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua
URL: 
http://svn.slimdevices.com/jive/7.5/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua?rev=8633&r1=8632&r2=8633&view=diff
==============================================================================
--- 
7.5/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua
 (original)
+++ 
7.5/trunk/squeezeplay/src/squeezeplay/share/applets/NowPlaying/NowPlayingApplet.lua
 Thu Mar  4 11:39:11 2010
@@ -833,6 +833,7 @@
 
 
 function _updateShuffle(self, mode)
+       log:debug("_updateShuffle(): ", mode)
        -- don't update this if SC/SN has remapped shuffle button
        if self.player then
                local playerStatus = self.player:getPlayerStatus()
@@ -849,12 +850,14 @@
                return
        end
        if self.controlsGroup then
+               log:warn("shuffle button style changed to: ", 
shuffleModes[token])
                self.shuffleButton:setStyle(shuffleModes[token])
        end
 end
 
 
 function _updateRepeat(self, mode)
+       log:debug("_updateRepeat(): ", mode)
        -- don't update this if SC/SN has remapped repeat button
        if self.player then
                local playerStatus = self.player:getPlayerStatus()
@@ -871,6 +874,7 @@
                return
        end
        if self.controlsGroup then
+               log:warn("repeat button style changed to: ", repeatModes[token])
                self.repeatButton:setStyle(repeatModes[token])
        end
 end
@@ -1083,9 +1087,13 @@
        self.window = _createUI(self)
        if self.player and self.player:getPlayerStatus() then
                self:_updateButtons(self.player:getPlayerStatus())
+               self:_updateRepeat(self.player:getPlayerStatus()['playlist 
repeat'])
+               self:_updateShuffle(self.player:getPlayerStatus()['playlist 
shuffle'])
        end
        self:_refreshRightButton()
        self.window:replace(oldWindow, Window.transitionFadeIn)
+
+
 end
 
 

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

Reply via email to