fix now-playing to query through the new playlist

workspace
Brendan Howell 4 years ago
parent 93c0c57058
commit dc2705b56b

@ -75,14 +75,13 @@ class Audio(Bureau):
""" """
Prints the currently playing song or stream on the small printer. Prints the currently playing song or stream on the small printer.
""" """
#out = subprocess.check_output(["mocp", "-i"]).decode("utf-8") media = self.player.get_media_player().get_media()
# TODO: sort out how to do this with
out = "Now Playing: " out = "Now Playing: "
out += self.player.get_media().get_meta(vlc.Meta.Title) + "\n" out += media.get_meta(vlc.Meta.Title) + "\n"
nowplaying = self.player.get_media().get_meta(vlc.Meta.NowPlaying) nowplaying = media.get_meta(vlc.Meta.NowPlaying)
if nowplaying == "": if nowplaying == "":
out += "by " + self.player.get_media().get_meta(vlc.Meta.Artist) + "\n" out += "by " + media.get_meta(vlc.Meta.Artist) + "\n"
out += "from the album '" + self.player.get_media().get_meta(vlc.Meta.Album) \ out += "from the album '" + media.get_meta(vlc.Meta.Album) \
+ "'\n" + "'\n"
else: else:
out += nowplaying + "\n" out += nowplaying + "\n"

Loading…
Cancel
Save