diff options
Diffstat (limited to 'notifier.py')
-rw-r--r-- | notifier.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/notifier.py b/notifier.py index fc91e8c..06b4434 100644 --- a/notifier.py +++ b/notifier.py @@ -17,13 +17,13 @@ class Notifier: self._callbacks[event] = list() self._callbacks[event].append(callback) - def notify(self, event): + def notify(self, event, value): for callback in self._callbacks.get(event, list()): - callback() + callback(value) def _playingStateChangedCallback(self, *args): - self.notify(Notifier.PLAYING_STATE_EVENT) + self.notify(Notifier.PLAYING_STATE_EVENT, self._player.isPlaying()) def _playbackVolumeChangedCallback(self, *args): - self.notify(Notifier.PLAYBACK_VOLUME_EVENT) + self.notify(Notifier.PLAYBACK_VOLUME_EVENT, self._player.getPlaybackVolume()) |