Ref T731, display received callsigns

This commit is contained in:
Klaus Basan
2019-09-26 14:27:46 +02:00
committed by Mat Sutcliffe
parent 7c89234f8c
commit 76fd0cfc91
3 changed files with 49 additions and 41 deletions

View File

@@ -27,6 +27,7 @@
using namespace BlackCore;
using namespace BlackCore::Afv::Clients;
using namespace BlackCore::Afv::Audio;
using namespace BlackCore::Context;
using namespace BlackMisc;
using namespace BlackMisc::Aviation;
@@ -114,6 +115,7 @@ namespace BlackGui
{
connect(afvClient, &CAfvClient::outputVolumePeakVU, this, &CAudioDeviceVolumeSetupComponent::onOutputVU);
connect(afvClient, &CAfvClient::inputVolumePeakVU, this, &CAudioDeviceVolumeSetupComponent::onInputVU);
connect(afvClient, &CAfvClient::receivingCallsignsChanged, this, &CAudioDeviceVolumeSetupComponent::onReceivingCallsignsChanged);
}
}
@@ -253,6 +255,11 @@ namespace BlackGui
ui->hs_VolumeOut->setValue((ui->hs_VolumeOut->maximum() - ui->hs_VolumeOut->minimum()) / 2);
}
void CAudioDeviceVolumeSetupComponent::onReceivingCallsignsChanged(const TransceiverReceivingCallsignsChangedArgs &args)
{
this->setInfo(args.receivingCallsigns.join(", "));
}
CAudioDeviceInfo CAudioDeviceVolumeSetupComponent::getSelectedInputDevice() const
{
if (!hasAudio()) { return CAudioDeviceInfo(); }