core: Add volume arg to volume_changed() event
It was already called with the argument, and both the MPD and HTTP frontends handled it/expected it. It was just the default implementation in CoreListener that lacked the argument.
This commit is contained in:
parent
158b2344ff
commit
447864774e
@ -132,11 +132,14 @@ class CoreListener(object):
|
||||
"""
|
||||
pass
|
||||
|
||||
def volume_changed(self):
|
||||
def volume_changed(self, volume):
|
||||
"""
|
||||
Called whenever the volume is changed.
|
||||
|
||||
*MAY* be implemented by actor.
|
||||
|
||||
:param volume: the new volume in the range [0..100]
|
||||
:type volume: int
|
||||
"""
|
||||
pass
|
||||
|
||||
|
||||
@ -49,7 +49,7 @@ class CoreListenerTest(unittest.TestCase):
|
||||
self.listener.options_changed()
|
||||
|
||||
def test_listener_has_default_impl_for_volume_changed(self):
|
||||
self.listener.volume_changed()
|
||||
self.listener.volume_changed(70)
|
||||
|
||||
def test_listener_has_default_impl_for_seeked(self):
|
||||
self.listener.seeked(0)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user