mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-26 18:55:38 +08:00
refactor: Remove unused methods
This commit is contained in:
@@ -4,7 +4,6 @@
|
|||||||
#include "blackgui/components/audionotificationcomponent.h"
|
#include "blackgui/components/audionotificationcomponent.h"
|
||||||
#include "blackgui/guiapplication.h"
|
#include "blackgui/guiapplication.h"
|
||||||
#include "blackcore/context/contextaudio.h"
|
#include "blackcore/context/contextaudio.h"
|
||||||
#include "blackmisc/audio/audiodeviceinfo.h"
|
|
||||||
#include "blackmisc/audio/notificationsounds.h"
|
#include "blackmisc/audio/notificationsounds.h"
|
||||||
#include "blackmisc/audio/audiosettings.h"
|
#include "blackmisc/audio/audiosettings.h"
|
||||||
#include "blackmisc/sequence.h"
|
#include "blackmisc/sequence.h"
|
||||||
@@ -82,15 +81,6 @@ namespace BlackGui::Components
|
|||||||
CAudioNotificationComponent::~CAudioNotificationComponent()
|
CAudioNotificationComponent::~CAudioNotificationComponent()
|
||||||
{}
|
{}
|
||||||
|
|
||||||
bool CAudioNotificationComponent::playNotificationSounds() const
|
|
||||||
{
|
|
||||||
return ui->cb_SetupAudioPTTClickDown->isChecked() || ui->cb_SetupAudioPTTClickUp->isChecked() ||
|
|
||||||
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_SetupAudioNotificationLogin->isChecked() || ui->cb_SetupAudioNotificationLogoff->isChecked();
|
|
||||||
}
|
|
||||||
|
|
||||||
void CAudioNotificationComponent::reloadSettings()
|
void CAudioNotificationComponent::reloadSettings()
|
||||||
{
|
{
|
||||||
const CSettings as(m_audioSettings.getThreadLocal());
|
const CSettings as(m_audioSettings.getThreadLocal());
|
||||||
|
|||||||
@@ -32,10 +32,7 @@ namespace BlackGui::Components
|
|||||||
explicit CAudioNotificationComponent(QWidget *parent = nullptr);
|
explicit CAudioNotificationComponent(QWidget *parent = nullptr);
|
||||||
|
|
||||||
//! Destructor
|
//! Destructor
|
||||||
virtual ~CAudioNotificationComponent() override;
|
~CAudioNotificationComponent() override;
|
||||||
|
|
||||||
//! Play any sounds?
|
|
||||||
bool playNotificationSounds() const;
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! Init
|
//! Init
|
||||||
|
|||||||
@@ -53,13 +53,7 @@ namespace BlackGui::Components
|
|||||||
connect(ui->pb_DataLoadAndCaches, &QPushButton::released, this, &CSettingsComponent::onOverviewButtonClicked);
|
connect(ui->pb_DataLoadAndCaches, &QPushButton::released, this, &CSettingsComponent::onOverviewButtonClicked);
|
||||||
}
|
}
|
||||||
|
|
||||||
CSettingsComponent::~CSettingsComponent()
|
CSettingsComponent::~CSettingsComponent() = default; // declared in cpp to avoid incomplete type of Ui::CSettingsComponent
|
||||||
{}
|
|
||||||
|
|
||||||
bool CSettingsComponent::playNotificationSounds() const
|
|
||||||
{
|
|
||||||
return ui->comp_AudioNotification->playNotificationSounds();
|
|
||||||
}
|
|
||||||
|
|
||||||
CSpecializedSimulatorSettings CSettingsComponent::getSimulatorSettings(const CSimulatorInfo &simulator) const
|
CSpecializedSimulatorSettings CSettingsComponent::getSimulatorSettings(const CSimulatorInfo &simulator) const
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -49,10 +49,7 @@ namespace BlackGui::Components
|
|||||||
explicit CSettingsComponent(QWidget *parent = nullptr);
|
explicit CSettingsComponent(QWidget *parent = nullptr);
|
||||||
|
|
||||||
//! Destructor
|
//! Destructor
|
||||||
virtual ~CSettingsComponent();
|
~CSettingsComponent() override;
|
||||||
|
|
||||||
//! \copydoc CAudioNotificationComponent::playNotificationSounds
|
|
||||||
bool playNotificationSounds() const;
|
|
||||||
|
|
||||||
//! Settings for given simulator
|
//! Settings for given simulator
|
||||||
BlackMisc::Simulation::Settings::CSpecializedSimulatorSettings getSimulatorSettings(const BlackMisc::Simulation::CSimulatorInfo &simulator) const;
|
BlackMisc::Simulation::Settings::CSpecializedSimulatorSettings getSimulatorSettings(const BlackMisc::Simulation::CSimulatorInfo &simulator) const;
|
||||||
@@ -70,15 +67,6 @@ namespace BlackGui::Components
|
|||||||
//! Change the windows opacity 0..100
|
//! Change the windows opacity 0..100
|
||||||
void changedWindowsOpacity(int opacity);
|
void changedWindowsOpacity(int opacity);
|
||||||
|
|
||||||
//! Update interval changed (ATC)
|
|
||||||
void changedAtcStationsUpdateInterval(int seconds);
|
|
||||||
|
|
||||||
//! Update interval changed (aircrafts)
|
|
||||||
void changedAircraftUpdateInterval(int seconds);
|
|
||||||
|
|
||||||
//! Update interval changed (users)
|
|
||||||
void changedUsersUpdateInterval(int seconds);
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
//! An overview button was clicked
|
//! An overview button was clicked
|
||||||
void onOverviewButtonClicked();
|
void onOverviewButtonClicked();
|
||||||
|
|||||||
Reference in New Issue
Block a user