Update slideshowMusic.lua

Only pause, if the old view was "slideshow".
This commit is contained in:
supertobi
2015-08-19 18:19:35 +02:00
parent 3d0e5362f7
commit c2f2912b4f

View File

@@ -59,9 +59,11 @@ local function playSlideshowMusic(_, old_view, new_view)
--dt.print_error(playCommand)
coroutine.yield("RUN_COMMAND", playCommand)
else
stopCommand = "rhythmbox-client --pause"
--dt.print_error(stopCommand)
coroutine.yield("RUN_COMMAND", stopCommand)
if (old_view.id == "slideshow") then
stopCommand = "rhythmbox-client --pause"
--dt.print_error(stopCommand)
coroutine.yield("RUN_COMMAND", stopCommand)
end
end
end
end