From 88d34ded021ac61e2440720fd3deb2cf3eef21e4 Mon Sep 17 00:00:00 2001 From: Eddy Pedroni Date: Tue, 4 Jan 2022 14:05:24 +0100 Subject: Added playback volume notification to player mock --- player_mock.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'player_mock.py') diff --git a/player_mock.py b/player_mock.py index 92da675..2fd343f 100644 --- a/player_mock.py +++ b/player_mock.py @@ -10,6 +10,7 @@ class Player(): self.volume = 1.0 self.currentSong = None self.playingStateChangedCallback = None + self.playbackVolumeChangedCallback = None def play(self): previousState = self.state @@ -58,3 +59,9 @@ class Player(): def simulatePlayingStateChanged(self): self.playingStateChangedCallback() + + def setPlaybackVolumeChangedCallback(self, callback): + self.playbackVolumeChangedCallback = callback + + def simulatePlaybackVolumeChanged(self): + self.playbackVolumeChangedCallback() -- cgit v1.2.3