From d08042247a3f5fb8d6664b02997cf374fe5b66d9 Mon Sep 17 00:00:00 2001 From: Manuel Cortez Date: Sun, 25 Feb 2018 05:09:11 -0600 Subject: [PATCH] Play button changes according to its function --- src/controller/mainController.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/controller/mainController.py b/src/controller/mainController.py index 3b82de2..932e12f 100644 --- a/src/controller/mainController.py +++ b/src/controller/mainController.py @@ -96,8 +96,10 @@ class Controller(object): def on_play_pause(self, *args, **kwargs): if player.player.player.is_playing() == 1: + self.window.play.SetLabel(_("Play")) return player.player.pause() else: + self.window.play.SetLabel(_("Pause")) return player.player.player.play() def on_next(self, *args, **kwargs): @@ -109,10 +111,12 @@ class Controller(object): def on_play(self, *args, **kwargs): items = self.results[::] playing_item = self.window.get_item() + self.window.play.SetLabel(_("Pause")) return utils.call_threaded(player.player.play_all, items, playing=playing_item, shuffle=self.window.player_shuffle.IsChecked()) def on_stop(self, *args, **kwargs): player.player.stop() + self.window.play.SetLabel(_("Play")) def on_volume_down(self, *args, **kwargs): self.window.vol_slider.SetValue(self.window.vol_slider.GetValue()-5)