diff options
Diffstat (limited to 'AudioManagerDaemon/src/CAmRoutingReceiver.cpp')
-rw-r--r-- | AudioManagerDaemon/src/CAmRoutingReceiver.cpp | 64 |
1 files changed, 32 insertions, 32 deletions
diff --git a/AudioManagerDaemon/src/CAmRoutingReceiver.cpp b/AudioManagerDaemon/src/CAmRoutingReceiver.cpp index f1f0e09..a9f8642 100644 --- a/AudioManagerDaemon/src/CAmRoutingReceiver.cpp +++ b/AudioManagerDaemon/src/CAmRoutingReceiver.cpp @@ -387,22 +387,46 @@ void am::CAmRoutingReceiver::waitOnStartup(bool startup) mLastStartupError=E_OK; } -am_Error_e CAmRoutingReceiver::updateGateway(const am_gatewayID_t gatewayID, std::vector<am_ConnectionFormat_e> listSourceFormats, const std::vector<am_ConnectionFormat_e> listSinkFormats, std::vector<bool> convertionMatrix) +void CAmRoutingReceiver::ackSinkNotificationConfiguration(const am_Handle_s handle, const am_Error_e error) +{ + CAmRoutingSender::am_handleData_c handleData = mpRoutingSender->returnHandleData(handle); + if (error == E_OK && handleData.sinkID != 0) + { + mpDatabaseHandler->changeSinkNotificationConfigurationDB(handleData.sinkID,*handleData.notificationConfiguration); + delete handleData.notificationConfiguration; + } + mpRoutingSender->removeHandle(handle); + mpControlSender->cbAckSetSinkNotificationConfiguration(handle,error); +} + +void CAmRoutingReceiver::ackSourceNotificationConfiguration(const am_Handle_s handle, const am_Error_e error) +{ + CAmRoutingSender::am_handleData_c handleData = mpRoutingSender->returnHandleData(handle); + if (error == E_OK && handleData.sourceID != 0) + { + mpDatabaseHandler->changeSourceNotificationConfigurationDB(handleData.sourceID,*handleData.notificationConfiguration); + delete handleData.notificationConfiguration; + } + mpRoutingSender->removeHandle(handle); + mpControlSender->cbAckSetSourceNotificationConfiguration(handle,error); +} + +am_Error_e CAmRoutingReceiver::updateGateway(const am_gatewayID_t gatewayID, const std::vector<am_ConnectionFormat_e>& listSourceFormats, const std::vector<am_ConnectionFormat_e>& listSinkFormats, const std::vector<bool>& convertionMatrix) { return (mpControlSender->hookSystemUpdateGateway(gatewayID,listSourceFormats,listSinkFormats,convertionMatrix)); } -am_Error_e CAmRoutingReceiver::updateSink(const am_sinkID_t sinkID, const am_sinkClass_t sinkClassID, const std::vector<am_SoundProperty_s> listSoundProperties, const std::vector<am_ConnectionFormat_e> listConnectionFormats, std::vector<am_MainSoundProperty_s> listMainSoundProperties) +am_Error_e CAmRoutingReceiver::updateSink(const am_sinkID_t sinkID, const am_sinkClass_t sinkClassID, const std::vector<am_SoundProperty_s>& listSoundProperties, const std::vector<am_ConnectionFormat_e>& listConnectionFormats, const std::vector<am_MainSoundProperty_s>& listMainSoundProperties) { return (mpControlSender->hookSystemUpdateSink(sinkID,sinkClassID,listSoundProperties,listConnectionFormats,listMainSoundProperties)); } -am_Error_e CAmRoutingReceiver::updateSource(const am_sourceID_t sourceID, const am_sourceClass_t sourceClassID, std::vector<am_SoundProperty_s> listSoundProperties, std::vector<am_ConnectionFormat_e> listConnectionFormats, const std::vector<am_MainSoundProperty_s> listMainSoundProperties) +am_Error_e CAmRoutingReceiver::updateSource(const am_sourceID_t sourceID, const am_sourceClass_t sourceClassID, const std::vector<am_SoundProperty_s>& listSoundProperties, const std::vector<am_ConnectionFormat_e>& listConnectionFormats, const std::vector<am_MainSoundProperty_s>& listMainSoundProperties) { return (mpControlSender->hookSystemUpdateSource(sourceID,sourceClassID,listSoundProperties,listConnectionFormats,listMainSoundProperties)); } -void CAmRoutingReceiver::ackSetVolumes(const am_Handle_s handle, const std::vector<am_Volumes_s> listvolumes, const am_Error_e error) +void CAmRoutingReceiver::ackSetVolumes(const am_Handle_s handle, const std::vector<am_Volumes_s>& listvolumes, const am_Error_e error) { CAmRoutingSender::am_handleData_c handleData = mpRoutingSender->returnHandleData(handle); if (error == E_OK && handleData.volumeID.sink != 0) @@ -426,39 +450,15 @@ void CAmRoutingReceiver::ackSetVolumes(const am_Handle_s handle, const std::vect mpControlSender->cbAckSetVolume(handle,listvolumes,error); } -void CAmRoutingReceiver::ackSinkNotificationConfiguration(const am_Handle_s handle, const am_Error_e error) -{ - CAmRoutingSender::am_handleData_c handleData = mpRoutingSender->returnHandleData(handle); - if (error == E_OK && handleData.sinkID != 0) - { - mpDatabaseHandler->changeSinkNotificationConfigurationDB(handleData.sinkID,*handleData.notificationConfiguration); - delete handleData.notificationConfiguration; - } - mpRoutingSender->removeHandle(handle); - mpControlSender->cbAckSetSinkNotificationConfiguration(handle,error); -} - -void CAmRoutingReceiver::ackSourceNotificationConfiguration(const am_Handle_s handle, const am_Error_e error) -{ - CAmRoutingSender::am_handleData_c handleData = mpRoutingSender->returnHandleData(handle); - if (error == E_OK && handleData.sourceID != 0) - { - mpDatabaseHandler->changeSourceNotificationConfigurationDB(handleData.sourceID,*handleData.notificationConfiguration); - delete handleData.notificationConfiguration; - } - mpRoutingSender->removeHandle(handle); - mpControlSender->cbAckSetSourceNotificationConfiguration(handle,error); -} - -void CAmRoutingReceiver::hookSinkNotificationDataChange(const am_sinkID_t sinkID, const am_NotificationPayload_s payload) +void CAmRoutingReceiver::hookSinkNotificationDataChange(const am_sinkID_t sinkID, const am_NotificationPayload_s& payload) { - logInfo("CAmRoutingReceiver::hookSinkNotificationDataChange received, sinkID=",sinkID,"notificationType=",payload.notificationType,"notificationValue=",payload.notificationValue); + logInfo("CAmRoutingReceiver::hookSinkNotificationDataChange received, sinkID=",sinkID,"type=",payload.type,"notificationValue=",payload.value); mpControlSender->hookSinkNotificationDataChanged(sinkID,payload); } -void CAmRoutingReceiver::hookSourceNotificationDataChange(const am_sourceID_t sourceID, const am_NotificationPayload_s payload) +void CAmRoutingReceiver::hookSourceNotificationDataChange(const am_sourceID_t sourceID, const am_NotificationPayload_s& payload) { - logInfo("CAmRoutingReceiver::hookSourceNotificationDataChange received, sinkID=",sourceID,"notificationType=",payload.notificationType,"notificationValue=",payload.notificationValue); + logInfo("CAmRoutingReceiver::hookSourceNotificationDataChange received, sinkID=",sourceID,"type=",payload.type,"notificationValue=",payload.value); mpControlSender->hookSourceNotificationDataChanged(sourceID,payload); } |