diff options
author | Martin Koch <mkoch@de.adit-jv.com> | 2020-01-16 15:31:05 +0100 |
---|---|---|
committer | Martin Koch <mkoch@de.adit-jv.com> | 2020-01-17 09:14:36 +0100 |
commit | a2af83777be4860d554bceaf28c87218729cf309 (patch) | |
tree | 58472fdde28c6660ba60d1efd4f8b119eafd1ab5 /AudioManagerCore/src/CAmCommandSender.cpp | |
parent | ce501a931e9eeb20013406373156bf70fb007cda (diff) | |
download | audiomanager-a2af83777be4860d554bceaf28c87218729cf309.tar.gz |
AM: add plural form of set...SoundProperties for sources and sinks to command and control interface
- implement plural form of requests and acknowledgments in core
- provide empty default implementations in interfaces to ensure backward compatibility with older plugins
- accommodate extensions in module tests
- leave existing singular form untouched
Main purpose of this extension is to allow for one-shot (uninterrupted), consistent change of multiple, possibly interrelated sound properties.
Signed-off-by: Martin Koch <mkoch@de.adit-jv.com>
Diffstat (limited to 'AudioManagerCore/src/CAmCommandSender.cpp')
-rw-r--r-- | AudioManagerCore/src/CAmCommandSender.cpp | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/AudioManagerCore/src/CAmCommandSender.cpp b/AudioManagerCore/src/CAmCommandSender.cpp index d1a4a22..622e5fd 100644 --- a/AudioManagerCore/src/CAmCommandSender.cpp +++ b/AudioManagerCore/src/CAmCommandSender.cpp @@ -118,9 +118,15 @@ CAmCommandSender::CAmCommandSender(const std::vector<std::string> &listOfPluginD dboMainSinkSoundPropertyChanged = [&](const am_sinkID_t sinkID, const am_MainSoundProperty_s &SoundProperty) { mSerializer.asyncCall(this, &CAmCommandSender::cbMainSinkSoundPropertyChanged, sinkID, SoundProperty); }; + dboMainSinkSoundPropertiesChanged = [&](const am_sinkID_t sinkID, const std::vector<am_MainSoundProperty_s> &listSoundProperties) { + mSerializer.asyncCall(this, &CAmCommandSender::cbMainSinkSoundPropertiesChanged, sinkID, listSoundProperties); + }; dboMainSourceSoundPropertyChanged = [&](const am_sourceID_t sourceID, const am_MainSoundProperty_s &SoundProperty) { mSerializer.asyncCall(this, &CAmCommandSender::cbMainSourceSoundPropertyChanged, sourceID, SoundProperty); }; + dboMainSourceSoundPropertiesChanged = [&](const am_sourceID_t sourceID, const std::vector<am_MainSoundProperty_s> &listSoundProperties) { + mSerializer.asyncCall(this, &CAmCommandSender::cbMainSourceSoundPropertiesChanged, sourceID, listSoundProperties); + }; dboSinkAvailabilityChanged = [&](const am_sinkID_t sinkID, const am_Availability_s &availability) { mSerializer.asyncCall(this, &CAmCommandSender::cbSinkAvailabilityChanged, sinkID, availability); }; @@ -310,11 +316,21 @@ void CAmCommandSender::cbMainSinkSoundPropertyChanged(const am_sinkID_t sinkID, CALL_ALL_INTERFACES(cbMainSinkSoundPropertyChanged(sinkID, SoundProperty)) } +void CAmCommandSender::cbMainSinkSoundPropertiesChanged(const am_sinkID_t sinkID, const std::vector<am_MainSoundProperty_s> &listSoundProperties) +{ + CALL_ALL_INTERFACES(cbMainSinkSoundPropertiesChanged(sinkID, listSoundProperties)) +} + void CAmCommandSender::cbMainSourceSoundPropertyChanged(const am_sourceID_t sourceID, const am_MainSoundProperty_s &SoundProperty) { CALL_ALL_INTERFACES(cbMainSourceSoundPropertyChanged(sourceID, SoundProperty)) } +void CAmCommandSender::cbMainSourceSoundPropertiesChanged(const am_sourceID_t sourceID, const std::vector<am_MainSoundProperty_s> &listSoundProperties) +{ + CALL_ALL_INTERFACES(cbMainSourceSoundPropertiesChanged(sourceID, listSoundProperties)) +} + void CAmCommandSender::cbSinkAvailabilityChanged(const am_sinkID_t sinkID, const am_Availability_s &availability) { CALL_ALL_INTERFACES(cbSinkAvailabilityChanged(sinkID, availability)) |