diff --git a/src/blackcore/context/contextownaircraftimpl.cpp b/src/blackcore/context/contextownaircraftimpl.cpp index c58dca97d..b877efe9b 100644 --- a/src/blackcore/context/contextownaircraftimpl.cpp +++ b/src/blackcore/context/contextownaircraftimpl.cpp @@ -267,23 +267,6 @@ namespace BlackCore::Context const bool atcCom1 = atcs.hasComUnitTunedInChannelSpacing(com1); const bool atcCom2 = atcs.hasComUnitTunedInChannelSpacing(com2); - const bool tunedIn1 = atcCom1 && !lastCom1.isReceiveEnabled(); - const bool tunedIn2 = atcCom2 && !lastCom2.isReceiveEnabled(); - const bool tunedOut1 = !atcCom1 && lastCom1.isReceiveEnabled(); - const bool tunedOut2 = !atcCom2 && lastCom2.isReceiveEnabled(); - - if (sApp && sApp->getCContextAudioBase() && sApp->getIContextNetwork()->isConnected()) - { - if (tunedIn1 || tunedIn2) - { - sApp->getCContextAudioBase()->playNotification(CNotificationSounds::NotificationAtcTunedIn, true); - } - else if (tunedOut1 || tunedOut2) - { - sApp->getCContextAudioBase()->playNotification(CNotificationSounds::NotificationAtcTunedOut, true); - } - } - // remember if I was tuned in, abusing the flag com1.setReceiveEnabled(atcCom1); com2.setReceiveEnabled(atcCom2); diff --git a/src/blackgui/components/audionotificationcomponent.cpp b/src/blackgui/components/audionotificationcomponent.cpp index 3d1af2cec..2a307ac4c 100644 --- a/src/blackgui/components/audionotificationcomponent.cpp +++ b/src/blackgui/components/audionotificationcomponent.cpp @@ -63,10 +63,6 @@ namespace BlackGui::Components Q_ASSERT(c); c = connect(ui->cb_SetupAudioNotificationTextCallsignMentioned, &QCheckBox::toggled, this, &CAudioNotificationComponent::onNotificationsToggled, Qt::QueuedConnection); Q_ASSERT(c); - c = connect(ui->cb_SetupAudioNotificationAtcTunedOut, &QCheckBox::toggled, this, &CAudioNotificationComponent::onNotificationsToggled, Qt::QueuedConnection); - Q_ASSERT(c); - c = connect(ui->cb_SetupAudioNotificationAtcTunedIn, &QCheckBox::toggled, this, &CAudioNotificationComponent::onNotificationsToggled, Qt::QueuedConnection); - Q_ASSERT(c); c = connect(ui->cb_SetupAfvBlocked, &QCheckBox::toggled, this, &CAudioNotificationComponent::onNotificationsToggled, Qt::QueuedConnection); Q_ASSERT(c); c = connect(ui->cb_SetupAfvClicked, &QCheckBox::toggled, this, &CAudioNotificationComponent::onNotificationsToggled, Qt::QueuedConnection); @@ -91,8 +87,7 @@ namespace BlackGui::Components ui->cb_SetupAudioNotificationTextMessageFrequency->isChecked() || ui->cb_SetupAudioNotificationTextMessageUnicom->isChecked() || ui->cb_SetupAudioNotificationTextMessagePrivate->isChecked() || ui->cb_SetupAudioNotificationTextMessageSupervisor->isChecked() || ui->cb_SetupAudioNotificationTextCallsignMentioned->isChecked() || - ui->cb_SetupAfvBlocked->isChecked() || ui->cb_SetupAfvClicked->isChecked() || - ui->cb_SetupAudioNotificationAtcTunedIn->isChecked() || ui->cb_SetupAudioNotificationAtcTunedOut->isChecked(); + ui->cb_SetupAfvBlocked->isChecked() || ui->cb_SetupAfvClicked->isChecked(); } void CAudioNotificationComponent::reloadSettings() @@ -108,8 +103,6 @@ namespace BlackGui::Components ui->cb_SetupAudioNotificationTextMessageSupervisor->setChecked(as.isNotificationFlagSet(CNotificationSounds::NotificationTextMessageSupervisor)); ui->cb_SetupAudioNotificationTextMessageUnicom->setChecked(as.isNotificationFlagSet(CNotificationSounds::NotificationTextMessageUnicom)); ui->cb_SetupAudioNotificationTextCallsignMentioned->setChecked(as.isNotificationFlagSet(CNotificationSounds::NotificationTextCallsignMentioned)); - ui->cb_SetupAudioNotificationAtcTunedIn->setChecked(as.isNotificationFlagSet(CNotificationSounds::NotificationAtcTunedIn)); - ui->cb_SetupAudioNotificationAtcTunedOut->setChecked(as.isNotificationFlagSet(CNotificationSounds::NotificationAtcTunedOut)); ui->cb_SetupAfvBlocked->setChecked(as.isNotificationFlagSet(CNotificationSounds::AFVBlocked)); ui->cb_SetupAfvClicked->setChecked(as.isNotificationFlagSet(CNotificationSounds::AFVClicked)); @@ -140,8 +133,6 @@ namespace BlackGui::Components if (cb == ui->cb_SetupAudioNotificationTextMessagePrivate) { return CNotificationSounds::NotificationTextMessagePrivate; } if (cb == ui->cb_SetupAudioNotificationTextMessageSupervisor) { return CNotificationSounds::NotificationTextMessageSupervisor; } if (cb == ui->cb_SetupAudioNotificationTextMessageUnicom) { return CNotificationSounds::NotificationTextMessageUnicom; } - if (cb == ui->cb_SetupAudioNotificationAtcTunedIn) { return CNotificationSounds::NotificationAtcTunedIn; } - if (cb == ui->cb_SetupAudioNotificationAtcTunedOut) { return CNotificationSounds::NotificationAtcTunedOut; } if (cb == ui->cb_SetupAfvBlocked) { return CNotificationSounds::AFVBlocked; } if (cb == ui->cb_SetupAfvClicked) { return CNotificationSounds::AFVClicked; } @@ -167,9 +158,6 @@ namespace BlackGui::Components as.setNotificationFlag(CNotificationSounds::AFVBlocked, ui->cb_SetupAfvBlocked->isChecked()); as.setNotificationFlag(CNotificationSounds::AFVClicked, ui->cb_SetupAfvClicked->isChecked()); - as.setNotificationFlag(CNotificationSounds::NotificationAtcTunedOut, ui->cb_SetupAudioNotificationAtcTunedOut->isChecked()); - as.setNotificationFlag(CNotificationSounds::NotificationAtcTunedIn, ui->cb_SetupAudioNotificationAtcTunedIn->isChecked()); - const CStatusMessage msg = m_audioSettings.set(as); CLogMessage(this).preformatted(msg); diff --git a/src/blackgui/components/audionotificationcomponent.ui b/src/blackgui/components/audionotificationcomponent.ui index 855021ea7..3c0b640b3 100644 --- a/src/blackgui/components/audionotificationcomponent.ui +++ b/src/blackgui/components/audionotificationcomponent.ui @@ -171,13 +171,6 @@ - - - - ATC frequency selected - - - @@ -199,13 +192,6 @@ - - - - ATC frequency deselected - - - @@ -228,8 +214,6 @@ cb_SetupAudioPTTBlocked cb_SetupAfvClicked cb_SetupAfvBlocked - cb_SetupAudioNotificationAtcTunedIn - cb_SetupAudioNotificationAtcTunedOut diff --git a/src/blackmisc/audio/notificationsounds.cpp b/src/blackmisc/audio/notificationsounds.cpp index 80d83039a..e081f86a4 100644 --- a/src/blackmisc/audio/notificationsounds.cpp +++ b/src/blackmisc/audio/notificationsounds.cpp @@ -24,8 +24,6 @@ namespace BlackMisc::Audio static const QString pttBlocked("PTT blocked"); static const QString afvclick("AFC click"); static const QString afvblock("AFV blocked"); - static const QString tunein("ATC tuned in"); - static const QString tuneout("ATC tuned off"); switch (notification) { @@ -37,8 +35,6 @@ namespace BlackMisc::Audio case NotificationTextMessageSupervisor: return supMsg; case NotificationTextMessageUnicom: return unicomMsg; case NotificationTextCallsignMentioned: return mentioned; - case NotificationAtcTunedIn: return tunein; - case NotificationAtcTunedOut: return tuneout; case PTTClickKeyDown: return pttDown; case PTTClickKeyUp: return pttUp; case PTTBlocked: return pttBlocked; @@ -62,9 +58,6 @@ namespace BlackMisc::Audio if (notification.testFlag(NotificationTextMessageUnicom)) n << flagToString(NotificationTextMessageUnicom); if (notification.testFlag(NotificationTextCallsignMentioned)) n << flagToString(NotificationTextCallsignMentioned); - if (notification.testFlag(NotificationAtcTunedIn)) n << flagToString(NotificationAtcTunedIn); - if (notification.testFlag(NotificationAtcTunedOut)) n << flagToString(NotificationAtcTunedOut); - if (notification.testFlag(PTTClickKeyUp)) n << flagToString(PTTClickKeyUp); if (notification.testFlag(PTTClickKeyDown)) n << flagToString(PTTClickKeyDown); if (notification.testFlag(PTTBlocked)) n << flagToString(PTTBlocked); diff --git a/src/blackmisc/audio/notificationsounds.h b/src/blackmisc/audio/notificationsounds.h index 0a512685f..4723b7bd0 100644 --- a/src/blackmisc/audio/notificationsounds.h +++ b/src/blackmisc/audio/notificationsounds.h @@ -31,8 +31,8 @@ namespace BlackMisc::Audio NotificationTextMessageUnicom = 1 << 13, NotificationTextCallsignMentioned = 1 << 5, // 1 << 6 previously used for NoAudioTransmission - NotificationAtcTunedIn = 1 << 10, - NotificationAtcTunedOut = 1 << 11, + // 1 << 10 previously used for NotificationAtcTunedIn + // 1 << 11 previously used for NotificationAtcTunedOut PTTClickKeyDown = 1 << 7, PTTClickKeyUp = 1 << 8, PTTBlocked = 1 << 9, diff --git a/src/blacksound/notificationplayer.cpp b/src/blacksound/notificationplayer.cpp index 7c15b7a4a..7e1e3e7bf 100644 --- a/src/blacksound/notificationplayer.cpp +++ b/src/blacksound/notificationplayer.cpp @@ -65,8 +65,6 @@ namespace BlackSound this->updateEffect(CNotificationSounds::NotificationTextMessageSupervisor, directory, "supervisormessage.wav"); this->updateEffect(CNotificationSounds::NotificationTextMessageUnicom, directory, "unicommessage.wav"); this->updateEffect(CNotificationSounds::NotificationTextCallsignMentioned, directory, "callsignmentioned.wav"); - this->updateEffect(CNotificationSounds::NotificationAtcTunedIn, directory, "atctunedin.wav"); - this->updateEffect(CNotificationSounds::NotificationAtcTunedOut, directory, "atctunedout.wav"); this->updateEffect(CNotificationSounds::PTTBlocked, directory, "pttblocked.wav"); this->updateEffect(CNotificationSounds::PTTClickKeyDown, directory, "pttclick.wav"); this->updateEffect(CNotificationSounds::PTTClickKeyUp, directory, "pttclick.wav"); diff --git a/src/blacksound/share/sounds/atctunedin.wav b/src/blacksound/share/sounds/atctunedin.wav deleted file mode 100644 index 8eb87f8b3..000000000 Binary files a/src/blacksound/share/sounds/atctunedin.wav and /dev/null differ diff --git a/src/blacksound/share/sounds/atctunedout.wav b/src/blacksound/share/sounds/atctunedout.wav deleted file mode 100644 index 037fece6f..000000000 Binary files a/src/blacksound/share/sounds/atctunedout.wav and /dev/null differ