mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-25 02:05:43 +08:00
committed by
Lars Toenning
parent
5e5b3f830d
commit
7691e42a5b
@@ -50,8 +50,8 @@ namespace BlackCore
|
||||
//! Signature just to set an icon for an action
|
||||
CActionBind(const QString &action, BlackMisc::CIcons::IconIndex icon, QObject *parent = nullptr);
|
||||
|
||||
//! Not copyable
|
||||
//! @{
|
||||
//! Not copyable
|
||||
CActionBind(const CActionBind &) = delete;
|
||||
CActionBind &operator =(const CActionBind &) = delete;
|
||||
//! @}
|
||||
|
||||
@@ -32,8 +32,8 @@ namespace BlackCore::Afv::Audio
|
||||
//! Success
|
||||
void success(const QString &callsign);
|
||||
|
||||
//! Delay plus/minus
|
||||
//! @{
|
||||
//! Delay plus/minus
|
||||
void increaseDelayMs(const QString &callsign);
|
||||
void decreaseDelayMs(const QString &callsign);
|
||||
//! @}
|
||||
|
||||
@@ -49,8 +49,8 @@ namespace BlackCore::Afv::Audio
|
||||
//! Type
|
||||
const QString &type() const { return m_aircraftType; }
|
||||
|
||||
//! Is active?
|
||||
//! @{
|
||||
//! Is active?
|
||||
void active(const QString &callsign, const QString &aircraftType);
|
||||
void activeSilent(const QString &callsign, const QString &aircraftType);
|
||||
//! @}
|
||||
@@ -58,8 +58,8 @@ namespace BlackCore::Afv::Audio
|
||||
//! Clean
|
||||
void clear();
|
||||
|
||||
//! Add samples
|
||||
//! @{
|
||||
//! Add samples
|
||||
void addOpusSamples(const IAudioDto &audioDto, float distanceRatio);
|
||||
void addSilentSamples(const IAudioDto &audioDto);
|
||||
//! @}
|
||||
|
||||
@@ -92,16 +92,16 @@ namespace BlackCore::Afv::Audio
|
||||
this->stop();
|
||||
}
|
||||
|
||||
//! Number of encoded bytes
|
||||
//! @{
|
||||
//! Number of encoded bytes
|
||||
int opusBytesEncoded() const { return m_opusBytesEncoded; }
|
||||
void setOpusBytesEncoded(int opusBytesEncoded) { m_opusBytesEncoded = opusBytesEncoded; }
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Gain ratio, value a amplitude need to be multiplied with
|
||||
//! \see http://www.sengpielaudio.com/calculator-amplification.htm
|
||||
//! \remark gain ratio is voltage ratio/or amplitude ratio, something between 0.001-7.95 for -60dB to 80dB
|
||||
//! @{
|
||||
double getGainRatio() const { return m_gainRatio; }
|
||||
bool setGainRatio(double gainRatio);
|
||||
//! @}
|
||||
@@ -110,8 +110,8 @@ namespace BlackCore::Afv::Audio
|
||||
// bool setVolume(double volume);
|
||||
|
||||
/* disabled as not needed
|
||||
//! The device's volume 0..1
|
||||
//! @{
|
||||
//! The device's volume 0..1
|
||||
double getDeviceInputVolume() const;
|
||||
bool setDeviceInputVolume(double volume);
|
||||
//! @}
|
||||
|
||||
@@ -86,8 +86,8 @@ namespace BlackCore::Afv::Audio
|
||||
const BlackMisc::Audio::CAudioDeviceInfo &device() const { return m_device; }
|
||||
|
||||
/* disabled as not used
|
||||
//! The device's volume 0..1
|
||||
//! @{
|
||||
//! The device's volume 0..1
|
||||
double getDeviceOutputVolume() const;
|
||||
bool setDeviceOutputVolume(double volume);
|
||||
//! @}
|
||||
|
||||
@@ -56,8 +56,8 @@ namespace BlackCore::Afv::Audio
|
||||
//! Volume
|
||||
double volume() const { return 1.0; }
|
||||
|
||||
//! Mute
|
||||
//! @{
|
||||
//! Mute
|
||||
bool getMute() const { return m_mute; }
|
||||
void setMute(bool value);
|
||||
//! @}
|
||||
@@ -65,8 +65,8 @@ namespace BlackCore::Afv::Audio
|
||||
//! \copydoc BlackSound::SampleProvider::ISampleProvider::readSamples
|
||||
virtual int readSamples(QVector<float> &samples, qint64 count) override;
|
||||
|
||||
//! Add samples
|
||||
//! @{
|
||||
//! Add samples
|
||||
void addOpusSamples(const IAudioDto &audioDto, uint frequency, float distanceRatio);
|
||||
void addSilentSamples(const IAudioDto &audioDto, uint frequency, float distanceRatio);
|
||||
//! @}
|
||||
|
||||
@@ -45,8 +45,8 @@ namespace BlackCore::Afv::Clients
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
//! AFV client properties
|
||||
//! @{
|
||||
//! AFV client properties
|
||||
Q_PROPERTY(double inputVolumePeakVU READ getInputVolumePeakVU NOTIFY inputVolumePeakVU)
|
||||
Q_PROPERTY(double outputVolumePeakVU READ getOutputVolumePeakVU NOTIFY outputVolumePeakVU)
|
||||
Q_PROPERTY(BlackCore::Afv::Clients::CAfvClient::ConnectionStatus connectionStatus READ getConnectionStatus NOTIFY connectionStatusChanged)
|
||||
@@ -68,9 +68,9 @@ namespace BlackCore::Afv::Clients
|
||||
//! Dtor
|
||||
virtual ~CAfvClient() override { this->stopAudio(); }
|
||||
|
||||
//! @{
|
||||
//! Corresponding callsign
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
QString getCallsign() const;
|
||||
void setCallsign(const QString &getCallsign);
|
||||
//! @}
|
||||
@@ -88,17 +88,17 @@ namespace BlackCore::Afv::Clients
|
||||
//! \remark runs in thread of CAfvClient object and is ASYNC when called from another thread
|
||||
Q_INVOKABLE void connectTo(const QString &cid, const QString &password, const QString &callsign, const QString &client);
|
||||
|
||||
//! @{
|
||||
//! Disconnect from network
|
||||
//! \threadsafe
|
||||
//! \remark runs in thread of CAfvClient object and is ASYNC when called from another thread
|
||||
//! @{
|
||||
void disconnectFrom(bool stop);
|
||||
Q_INVOKABLE void disconnectFrom() { this->disconnectFrom(false); }
|
||||
void disconnectFromAndStop() { this->disconnectFrom(true); }
|
||||
//! @}
|
||||
|
||||
//! Audio devices
|
||||
//! @{
|
||||
//! Audio devices
|
||||
Q_INVOKABLE QStringList availableInputDevices() const;
|
||||
Q_INVOKABLE QStringList availableOutputDevices() const;
|
||||
//! @}
|
||||
@@ -109,15 +109,15 @@ namespace BlackCore::Afv::Clients
|
||||
//! Client started?
|
||||
bool isStarted() const { return m_isStarted; }
|
||||
|
||||
//! @{
|
||||
//! Muted
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
bool isMuted() const;
|
||||
void setMuted(bool mute);
|
||||
//! @}
|
||||
|
||||
//! Start/stop client
|
||||
//! @{
|
||||
//! Start/stop client
|
||||
void startAudio();
|
||||
void startAudio(const BlackMisc::Audio::CAudioDeviceInfo &inputDevice, const BlackMisc::Audio::CAudioDeviceInfo &outputDevice);
|
||||
Q_INVOKABLE void startAudio(const QString &inputDeviceName, const QString &outputDeviceName);
|
||||
@@ -130,8 +130,8 @@ namespace BlackCore::Afv::Clients
|
||||
bool isComUnitIntegrated() const { return m_integratedComUnit; }
|
||||
|
||||
/* NOT used
|
||||
//! The device's volume 0..1
|
||||
//! @{
|
||||
//! The device's volume 0..1
|
||||
double getDeviceInputVolume() const;
|
||||
bool setDeviceInputVolume(double volume);
|
||||
double getDeviceOutputVolume() const;
|
||||
@@ -143,55 +143,55 @@ namespace BlackCore::Afv::Clients
|
||||
//! \threadsafe
|
||||
void setReceiveAudio(bool receive);
|
||||
|
||||
//! @{
|
||||
//! Enable COM unit/transceiver
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
Q_INVOKABLE void enableTransceiver(quint16 id, bool enable);
|
||||
void enableComUnit(BlackMisc::Aviation::CComSystem::ComUnit comUnit, bool enable);
|
||||
bool isEnabledTransceiver(quint16 id) const;
|
||||
bool isEnabledComUnit(BlackMisc::Aviation::CComSystem::ComUnit comUnit) const;
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Set transmitting transceivers
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
void setTransmittingTransceiver(quint16 transceiverID);
|
||||
void setTransmittingComUnit(BlackMisc::Aviation::CComSystem::ComUnit comUnit);
|
||||
void setTransmittingTransceivers(const QVector<TxTransceiverDto> &transceivers);
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Transmitting transceiver/COM unit
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
bool isTransmittingTransceiver(quint16 id) const;
|
||||
bool isTransmittingComUnit(BlackMisc::Aviation::CComSystem::ComUnit comUnit) const;
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Simplified enable/disable
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
void setRxTx(bool rx1, bool tx1, bool rx2, bool tx2);
|
||||
void getRxTx(bool &rx1, bool &tx1, bool &rx2, bool &tx2) const;
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Get transceivers
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
QVector<TransceiverDto> getTransceivers() const;
|
||||
QVector<TxTransceiverDto> getTransmittingTransceivers() const;
|
||||
QSet<quint16> getEnabledTransceivers() const;
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Aliased stations enabled?
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
bool isAliasedStationsEnabled() const { return m_enableAliased; }
|
||||
void enableAliasedStations(bool enabled) { m_enableAliased = enabled; }
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Update frequency
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
Q_INVOKABLE void updateComFrequency(quint16 id, quint32 frequencyHz);
|
||||
void updateComFrequency(BlackMisc::Aviation::CComSystem::ComUnit comUnit, const BlackMisc::PhysicalQuantities::CFrequency &comFrequency);
|
||||
void updateComFrequency(BlackMisc::Aviation::CComSystem::ComUnit comUnit, const BlackMisc::Aviation::CComSystem &comSystem);
|
||||
@@ -206,30 +206,30 @@ namespace BlackCore::Afv::Clients
|
||||
//! \threadsafe
|
||||
void updateFromOwnAircraft(const BlackMisc::Simulation::CSimulatedAircraft &aircraft, bool withSignals = true);
|
||||
|
||||
//! @{
|
||||
//! Push to talk
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
Q_INVOKABLE void setPtt(bool active);
|
||||
void setPttForCom(bool active, BlackMisc::Audio::PTTCOM com);
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Loopback
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
Q_INVOKABLE void setLoopBack(bool on) { m_loopbackOn = on; }
|
||||
Q_INVOKABLE bool isLoopback() const { return m_loopbackOn; }
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Input volume in dB, [MinDbIn, MaxDbIn]dB
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
double getInputVolumeDb() const;
|
||||
Q_INVOKABLE bool setInputVolumeDb(double valueDb);
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Output volume for each COM in dB, [MinDbOut, MaxDbOut]dB
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
double getComOutputVolumeDb(BlackMisc::Aviation::CComSystem::ComUnit comUnit) const;
|
||||
Q_INVOKABLE bool setComOutputVolumeDb(BlackMisc::Aviation::CComSystem::ComUnit comUnit, double valueDb);
|
||||
//! @}
|
||||
@@ -238,9 +238,9 @@ namespace BlackCore::Afv::Clients
|
||||
//! \threadsafe
|
||||
double getOutputGainRatio(BlackMisc::Aviation::CComSystem::ComUnit comUnit) const;
|
||||
|
||||
//! @{
|
||||
//! Normalized volumes 0..100
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
int getNormalizedInputVolume() const;
|
||||
int getNormalizedComOutputVolume(BlackMisc::Aviation::CComSystem::ComUnit comUnit) const;
|
||||
int getNormalizedMasterOutputVolume() const;
|
||||
@@ -249,24 +249,24 @@ namespace BlackCore::Afv::Clients
|
||||
bool setNormalizedMasterOutputVolume(int volume);
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! VU values, 0..1
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
double getInputVolumePeakVU() const;
|
||||
double getOutputVolumePeakVU() const;
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Recently used device
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
const BlackMisc::Audio::CAudioDeviceInfo &getInputDevice() const;
|
||||
const BlackMisc::Audio::CAudioDeviceInfo &getOutputDevice() const;
|
||||
bool usesSameDevices(const BlackMisc::Audio::CAudioDeviceInfo &inputDevice, const BlackMisc::Audio::CAudioDeviceInfo &outputDevice);
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Callsigns currently received
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
QString getReceivingCallsignsStringCom1() const;
|
||||
QString getReceivingCallsignsStringCom2() const;
|
||||
BlackMisc::Aviation::CCallsignSet getReceivingCallsignsCom1() const;
|
||||
@@ -301,8 +301,8 @@ namespace BlackCore::Afv::Clients
|
||||
//! PTT status in this particular AFV client
|
||||
void ptt(bool active, BlackMisc::Audio::PTTCOM pttcom, const BlackMisc::CIdentifier &identifier);
|
||||
|
||||
//! VU levels
|
||||
//! @{
|
||||
//! VU levels
|
||||
void inputVolumePeakVU(double value);
|
||||
void outputVolumePeakVU(double value);
|
||||
//! @}
|
||||
@@ -344,9 +344,9 @@ namespace BlackCore::Afv::Clients
|
||||
//! Connect again in given ms
|
||||
void reconnectTo(const QString &cid, const QString &password, const QString &callsign, const QString &client, int delayMs, const BlackMisc::CStatusMessage &msg);
|
||||
|
||||
//! @{
|
||||
//! All aliased stations
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
QVector<StationDto> getAliasedStations() const;
|
||||
void setAliasedStations(const QVector<StationDto> &stations);
|
||||
//! @}
|
||||
|
||||
@@ -79,8 +79,8 @@ namespace BlackCore::Afv::Connection
|
||||
//! Get the URL
|
||||
const QString &getUrl() const { return m_addressUrl; }
|
||||
|
||||
//! User data
|
||||
//! @{
|
||||
//! User data
|
||||
const QString &getUserName() const { return m_username; }
|
||||
const QString &getPassword() const { return m_password; }
|
||||
const QString &getClient() const { return m_client; }
|
||||
|
||||
@@ -54,8 +54,8 @@ namespace BlackCore::Afv::Connection
|
||||
//! Is alive?
|
||||
bool isVoiceServerAlive() const { return m_connection.isVoiceServerAlive(); }
|
||||
|
||||
//! Receiving audio?
|
||||
//! @{
|
||||
//! Receiving audio?
|
||||
void setReceiveAudio(bool value) { m_connection.setReceiveAudio(value); }
|
||||
bool receiveAudio() const { return m_connection.isReceivingAudio(); }
|
||||
bool receiveAudioDto() const { return m_receiveAudioDto; }
|
||||
@@ -94,8 +94,8 @@ namespace BlackCore::Afv::Connection
|
||||
//! Authenticated since when
|
||||
qint64 secondsSinceAuthentication() const { return m_connection.secondsSinceAuthentication(); }
|
||||
|
||||
//! User data
|
||||
//! @{
|
||||
//! User data
|
||||
const QString &getUserName() const { return m_connection.getUserName(); }
|
||||
const QString &getCallsign() const { return m_connection.getCallsign(); }
|
||||
const QString &getPassword() const { static const QString e; return m_apiServerConnection ? m_apiServerConnection->getPassword() : e; }
|
||||
|
||||
@@ -36,20 +36,20 @@ namespace BlackCore::Afv::Connection
|
||||
//! Time since authentication
|
||||
qint64 secondsSinceAuthentication() const;
|
||||
|
||||
//! Servers alive
|
||||
//! @{
|
||||
//! Servers alive
|
||||
bool isVoiceServerAlive() const;
|
||||
bool isDataServerAlive() const;
|
||||
//! @}
|
||||
|
||||
//! Is connected?
|
||||
//! @{
|
||||
//! Is connected?
|
||||
bool isConnected() const { return m_connected; }
|
||||
void setConnected(bool connected) { m_connected = connected; }
|
||||
//! @}
|
||||
|
||||
//! Receiving audio?
|
||||
//! @{
|
||||
//! Receiving audio?
|
||||
bool isReceivingAudio() const { return m_receiveAudio; }
|
||||
void setReceiveAudio(bool receive) { m_receiveAudio = receive; }
|
||||
//! @}
|
||||
@@ -57,26 +57,26 @@ namespace BlackCore::Afv::Connection
|
||||
//! Crypto channels for voice and data
|
||||
void createCryptoChannels();
|
||||
|
||||
//! Tokens
|
||||
//! @{
|
||||
//! Tokens
|
||||
const PostCallsignResponseDto &getTokens() const { return m_tokens; }
|
||||
void setTokens(const PostCallsignResponseDto &dto) { m_tokens = dto; }
|
||||
//! @}
|
||||
|
||||
//! Callsign
|
||||
//! @{
|
||||
//! Callsign
|
||||
const QString &getCallsign() const { return m_callsign; }
|
||||
void setCallsign(const QString &callsign) { m_callsign = callsign; }
|
||||
//! @}
|
||||
|
||||
//! Uername
|
||||
//! @{
|
||||
//! Uername
|
||||
const QString &getUserName() const { return m_userName; }
|
||||
void setUserName(const QString &un) { m_userName = un; }
|
||||
//! @}
|
||||
|
||||
//! Timestamps
|
||||
//! @{
|
||||
//! Timestamps
|
||||
void setTsAuthenticatedToNow();
|
||||
void setTsHeartbeatToNow();
|
||||
//! @}
|
||||
|
||||
@@ -32,8 +32,8 @@ namespace BlackCore::Afv::Crypto
|
||||
//! Ctor
|
||||
CCryptoDtoChannel(const CryptoDtoChannelConfigDto &channelConfig, int receiveSequenceHistorySize = 10);
|
||||
|
||||
//! Transmit key
|
||||
//! @{
|
||||
//! Transmit key
|
||||
QByteArray getTransmitKey(CryptoDtoMode mode);
|
||||
QByteArray getTransmitKey(CryptoDtoMode mode, uint &sequenceToSend);
|
||||
//! @}
|
||||
|
||||
@@ -137,20 +137,20 @@ namespace BlackCore::Afv::Crypto
|
||||
return {};
|
||||
}
|
||||
|
||||
//! Header data
|
||||
//! @{
|
||||
//! Header data
|
||||
quint16 m_headerLength;
|
||||
CryptoDtoHeaderDto m_header;
|
||||
//! @}
|
||||
|
||||
//! Name data
|
||||
//! @{
|
||||
//! Name data
|
||||
quint16 m_dtoNameLength;
|
||||
QByteArray m_dtoNameBuffer;
|
||||
//! @}
|
||||
|
||||
//! Data
|
||||
//! @{
|
||||
//! Data
|
||||
quint16 m_dataLength;
|
||||
QByteArray m_dataBuffer;
|
||||
//! @}
|
||||
|
||||
@@ -25,8 +25,8 @@ namespace BlackCore::Afv
|
||||
//! Channel config DTO
|
||||
struct CryptoDtoChannelConfigDto
|
||||
{
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString channelTag;
|
||||
QByteArray aeadReceiveKey;
|
||||
QByteArray aeadTransmitKey;
|
||||
@@ -60,8 +60,8 @@ namespace BlackCore::Afv
|
||||
//! Voice server DTO
|
||||
struct VoiceServerConnectionDataDto
|
||||
{
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString addressIpV4; // Example: 123.123.123.123:50000
|
||||
QString addressIpV6; // Example: 123.123.123.123:50000
|
||||
CryptoDtoChannelConfigDto channelConfig;
|
||||
@@ -91,8 +91,8 @@ namespace BlackCore::Afv
|
||||
//! Callsign DTO
|
||||
struct PostCallsignResponseDto
|
||||
{
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
// DataServerConnectionDataDto DataServer;
|
||||
VoiceServerConnectionDataDto VoiceServer;
|
||||
bool isValid = false;
|
||||
@@ -121,8 +121,8 @@ namespace BlackCore::Afv
|
||||
//! Transceiver DTO
|
||||
struct TransceiverDto
|
||||
{
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
quint16 id;
|
||||
quint32 frequencyHz;
|
||||
double LatDeg = 0.0;
|
||||
@@ -162,8 +162,8 @@ namespace BlackCore::Afv
|
||||
//! Station DTO
|
||||
struct StationDto
|
||||
{
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QUuid id;
|
||||
QString name;
|
||||
quint32 frequencyHz;
|
||||
@@ -185,8 +185,8 @@ namespace BlackCore::Afv
|
||||
//! Heartbeat DTO
|
||||
struct HeartbeatDto
|
||||
{
|
||||
//! Name
|
||||
//! @{
|
||||
//! Name
|
||||
static QByteArray getDtoName() { return "HeartbeatDto"; }
|
||||
static QByteArray getShortDtoName() { return "H"; }
|
||||
//! @}
|
||||
@@ -198,8 +198,8 @@ namespace BlackCore::Afv
|
||||
//! Heartbeat DTO
|
||||
struct HeartbeatAckDto
|
||||
{
|
||||
//! Name
|
||||
//! @{
|
||||
//! Name
|
||||
static QByteArray getDtoName() { return "HeartbeatAckDto"; }
|
||||
static QByteArray getShortDtoName() { return "HA"; }
|
||||
//! @}
|
||||
@@ -210,8 +210,8 @@ namespace BlackCore::Afv
|
||||
//! Receive transceiver DTO
|
||||
struct RxTransceiverDto
|
||||
{
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
uint16_t id;
|
||||
uint32_t frequency;
|
||||
float distanceRatio;
|
||||
@@ -246,14 +246,14 @@ namespace BlackCore::Afv
|
||||
//! AudioTxOnTransceiversDto
|
||||
struct AudioTxOnTransceiversDto
|
||||
{
|
||||
//! Names
|
||||
//! @{
|
||||
//! Names
|
||||
static QByteArray getDtoName() { return "AudioTxOnTransceiversDto"; }
|
||||
static QByteArray getShortDtoName() { return "AT"; }
|
||||
//! @}
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
std::string callsign;
|
||||
uint sequenceCounter;
|
||||
std::vector<char> audio;
|
||||
@@ -266,14 +266,14 @@ namespace BlackCore::Afv
|
||||
//! AudioRxOnTransceiversDto
|
||||
struct AudioRxOnTransceiversDto
|
||||
{
|
||||
//! Names
|
||||
//! @{
|
||||
//! Names
|
||||
static QByteArray getDtoName() { return "AudioRxOnTransceiversDto"; }
|
||||
static QByteArray getShortDtoName() { return "AR"; }
|
||||
//! @}
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
std::string callsign;
|
||||
uint sequenceCounter;
|
||||
std::vector<char> audio;
|
||||
|
||||
@@ -22,8 +22,8 @@ namespace BlackCore::Afv::Model
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
//! Map reader properties
|
||||
//! @{
|
||||
//! Map reader properties
|
||||
Q_PROPERTY(CSampleAtcStationModel *atcStationModel READ getAtcStationModel CONSTANT)
|
||||
//! @}
|
||||
|
||||
|
||||
@@ -31,8 +31,8 @@ namespace BlackCore::Afv::Model
|
||||
//! Ctor
|
||||
CSampleAtcStation(const QString &callsign, const BlackCore::Afv::TransceiverDto &transceiver);
|
||||
|
||||
//! Getter
|
||||
//! @{
|
||||
//! Getter
|
||||
const QString &callsign() const { return m_callsign; }
|
||||
QString formattedFrequency() const;
|
||||
double latitude() const;
|
||||
|
||||
@@ -80,9 +80,9 @@ namespace BlackCore
|
||||
Fsd::CFSDClient *fsdClient,
|
||||
QObject *parent);
|
||||
|
||||
//! @{
|
||||
//! Members not implenented or fully implenented by CRemoteAircraftProvider
|
||||
//! \ingroup remoteaircraftprovider
|
||||
//! @{
|
||||
virtual QObject *asQObject() override { return this; }
|
||||
virtual BlackMisc::Simulation::CAirspaceAircraftSnapshot getLatestAirspaceAircraftSnapshot() const override;
|
||||
virtual bool updateFastPositionEnabled(const BlackMisc::Aviation::CCallsign &callsign, bool enableFastPositonUpdates) override;
|
||||
@@ -167,18 +167,16 @@ namespace BlackCore
|
||||
};
|
||||
Q_DECLARE_FLAGS(MatchingReadiness, MatchingReadinessFlag)
|
||||
|
||||
//! As string
|
||||
//! @{
|
||||
//! As string
|
||||
static const QString &enumFlagToString(MatchingReadinessFlag r);
|
||||
static QString enumToString(MatchingReadiness r);
|
||||
//! @}
|
||||
|
||||
//! \addtogroup swiftdotcommands
|
||||
//! @{
|
||||
//! <pre>
|
||||
//! .fsd range distance max.range e.g. ".fsd range 100NM"
|
||||
//! </pre>
|
||||
//! @}
|
||||
//! \copydoc BlackCore::Context::IContextNetwork::parseCommandLine
|
||||
bool parseCommandLine(const QString &commandLine, const BlackMisc::CIdentifier &originator);
|
||||
|
||||
|
||||
@@ -315,6 +315,8 @@ namespace BlackCore
|
||||
//! cmd line arguments as string
|
||||
virtual QString cmdLineArgumentsAsString(bool withExecutable = true);
|
||||
|
||||
//! @}
|
||||
|
||||
//! Simulate a crash
|
||||
//! \private only for testing purposes
|
||||
void simulateCrash();
|
||||
@@ -378,15 +380,15 @@ namespace BlackCore
|
||||
//! Get the facade
|
||||
CCoreFacade *getCoreFacade() { return m_coreFacade.data(); }
|
||||
|
||||
//! Local or DBus application?
|
||||
//! @{
|
||||
//! Local application? (not DBus)
|
||||
bool isLocalContext() const;
|
||||
|
||||
//! DBus application? (not Local)
|
||||
bool isDBusContext() const;
|
||||
//! @}
|
||||
|
||||
//! Get the facade
|
||||
//! @{
|
||||
const CCoreFacade *getCoreFacade() const { return m_coreFacade.data(); }
|
||||
|
||||
//! @}
|
||||
|
||||
//! Direct access to contexts if a CCoreFacade has been initialized
|
||||
@@ -450,6 +452,9 @@ namespace BlackCore
|
||||
|
||||
// ------------------------- network -----------------------------------------------
|
||||
|
||||
//! \name network
|
||||
//! @{
|
||||
|
||||
static constexpr int NoRedirects = -1; //!< network request not allowing redirects
|
||||
static constexpr int NoLogRequestId = -1; //!< network request without logging
|
||||
static constexpr int DefaultMaxRedirects = 2; //!< network request, default for max.redirects
|
||||
@@ -565,6 +570,7 @@ namespace BlackCore
|
||||
//! \threadsafe
|
||||
QNetworkReply *downloadFromNetwork(const BlackMisc::Network::CUrl &url, const QString &saveAsFileName,
|
||||
const BlackMisc::CSlot<void(const BlackMisc::CStatusMessage &)> &callback, int maxRedirects = DefaultMaxRedirects);
|
||||
//! @}
|
||||
|
||||
signals:
|
||||
//! Setup available (cache, web load, ..) or failed to load setup
|
||||
|
||||
@@ -33,17 +33,14 @@
|
||||
|
||||
// clazy:excludeall=const-signal-or-slot
|
||||
|
||||
//! \addtogroup dbus
|
||||
//! @{
|
||||
|
||||
//! DBus interface for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTAPPLICATION_INTERFACENAME "org.swift_project.blackcore.contextapplication"
|
||||
|
||||
//! DBus object path for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTAPPLICATION_OBJECTPATH "/application"
|
||||
|
||||
//! @}
|
||||
|
||||
class QDBusConnection;
|
||||
namespace BlackMisc { class CDBusServer; }
|
||||
namespace BlackCore
|
||||
|
||||
@@ -46,8 +46,6 @@ namespace BlackCore
|
||||
friend class IContextApplication;
|
||||
|
||||
public slots:
|
||||
//! \publicsection
|
||||
//! @{
|
||||
virtual void changeSettings(const BlackMisc::CValueCachePacket &settings, const BlackMisc::CIdentifier &origin) override;
|
||||
virtual BlackMisc::CValueCachePacket getAllSettings() const override;
|
||||
virtual QStringList getUnsavedSettingsKeys() const override;
|
||||
@@ -67,7 +65,6 @@ namespace BlackCore
|
||||
virtual bool removeFile(const QString &fileName) override;
|
||||
virtual bool existsFile(const QString &fileName) const override;
|
||||
virtual QString dotCommandsHtmlHelp() const override;
|
||||
//! @}
|
||||
|
||||
protected:
|
||||
//! Constructor
|
||||
|
||||
@@ -49,8 +49,6 @@ namespace BlackCore
|
||||
virtual ~CContextApplicationProxy() override {}
|
||||
|
||||
public slots:
|
||||
//! \publicsection
|
||||
//! @{
|
||||
virtual void changeSettings(const BlackMisc::CValueCachePacket &settings, const BlackMisc::CIdentifier &origin) override;
|
||||
virtual BlackMisc::CValueCachePacket getAllSettings() const override;
|
||||
virtual QStringList getUnsavedSettingsKeys() const override;
|
||||
@@ -70,7 +68,6 @@ namespace BlackCore
|
||||
virtual bool removeFile(const QString &fileName) override;
|
||||
virtual bool existsFile(const QString &fileName) const override;
|
||||
virtual QString dotCommandsHtmlHelp() const override;
|
||||
//! @}
|
||||
|
||||
//! Used to test if there is a core running?
|
||||
//! \note creates and connects via proxy object, so not meant for very frequent tests
|
||||
|
||||
@@ -43,17 +43,14 @@
|
||||
|
||||
// clazy:excludeall=const-signal-or-slot
|
||||
|
||||
//! \addtogroup dbus
|
||||
//! @{
|
||||
|
||||
//! DBus interface for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTAUDIO_INTERFACENAME "org.swift_project.blackcore.contextaudio"
|
||||
|
||||
//! DBus object path for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTAUDIO_OBJECTPATH "/audio"
|
||||
|
||||
//! @}
|
||||
|
||||
class QDBusConnection;
|
||||
|
||||
namespace BlackMisc { class CDBusServer; }
|
||||
@@ -144,23 +141,23 @@ namespace BlackCore
|
||||
//! Graceful shutdown
|
||||
void gracefulShutdown();
|
||||
|
||||
//! Enable/disable
|
||||
//! @{
|
||||
//! Enable/disable
|
||||
void enableVoiceClient() { this->initVoiceClient(); }
|
||||
void enableVoiceClientAndStart();
|
||||
void disableVoiceClient() { this->terminateVoiceClient(); }
|
||||
//! @}
|
||||
|
||||
//! Receive/transmit
|
||||
//! @{
|
||||
//! Receive/transmit
|
||||
void setRxTx(bool rx1, bool tx1, bool rx2, bool tx2);
|
||||
void getRxTx(bool &rx1, bool &tx1, bool &rx2, bool &tx2) const;
|
||||
//! @}
|
||||
|
||||
// -------- parts which can run in core and GUI, referring to local voice client ------------
|
||||
|
||||
//! Audio devices
|
||||
//! @{
|
||||
//! Audio devices
|
||||
BlackMisc::Audio::CAudioDeviceInfoList getAudioDevices() const;
|
||||
BlackMisc::Audio::CAudioDeviceInfoList getAudioInputDevices() const;
|
||||
BlackMisc::Audio::CAudioDeviceInfoList getAudioOutputDevices() const;
|
||||
@@ -176,8 +173,8 @@ namespace BlackCore
|
||||
//! Set current audio devices
|
||||
void setCurrentAudioDevices(const BlackMisc::Audio::CAudioDeviceInfo &inputDevice, const BlackMisc::Audio::CAudioDeviceInfo &outputDevice);
|
||||
|
||||
//! Volume
|
||||
//! @{
|
||||
//! Volume
|
||||
void setMasterOutputVolume(int volume);
|
||||
void setComOutputVolume(BlackMisc::Aviation::CComSystem::ComUnit comUnit, int volume);
|
||||
int getMasterOutputVolume() const;
|
||||
@@ -192,14 +189,14 @@ namespace BlackCore
|
||||
//! Notification sounds
|
||||
void playNotification(BlackMisc::Audio::CNotificationSounds::NotificationFlag notification, bool considerSettings, int volume = -1);
|
||||
|
||||
//! Loopback
|
||||
//! @{
|
||||
//! Loopback
|
||||
void enableAudioLoopback(bool enable = true);
|
||||
bool isAudioLoopbackEnabled() const;
|
||||
//! @}
|
||||
|
||||
//! Voice setup
|
||||
//! @{
|
||||
//! Voice setup
|
||||
BlackMisc::Audio::CVoiceSetup getVoiceSetup() const;
|
||||
void setVoiceSetup(const BlackMisc::Audio::CVoiceSetup &setup);
|
||||
//! @}
|
||||
@@ -295,8 +292,8 @@ namespace BlackCore
|
||||
* Workaround those must be invisible for DBus
|
||||
*
|
||||
|
||||
//! VU levels
|
||||
//! @{
|
||||
//! VU levels
|
||||
void inputVolumePeakVU (double value);
|
||||
void outputVolumePeakVU(double value);
|
||||
//! @}
|
||||
@@ -318,8 +315,8 @@ namespace BlackCore
|
||||
//! Terminate the voice client
|
||||
void terminateVoiceClient();
|
||||
|
||||
//! Enable/disable voice transmission, nornally used with hotkey
|
||||
//! @{
|
||||
//! Enable/disable voice transmission, nornally used with hotkey
|
||||
void setVoiceTransmission(bool enable, BlackMisc::Audio::PTTCOM com);
|
||||
void setVoiceTransmissionComActive(bool enabled);
|
||||
//! @}
|
||||
@@ -333,8 +330,8 @@ namespace BlackCore
|
||||
//! Changed voice settings
|
||||
void onChangedVoiceSettings();
|
||||
|
||||
//! Audio increase/decrease volume
|
||||
//! @{
|
||||
//! Audio increase/decrease volume
|
||||
void audioIncreaseVolume(bool enabled);
|
||||
void audioDecreaseVolume(bool enabled);
|
||||
void audioIncreaseVolumeCom1(bool enabled);
|
||||
|
||||
@@ -42,9 +42,6 @@ namespace BlackCore
|
||||
friend class IContextAudio;
|
||||
|
||||
public slots:
|
||||
// Interface implementations for DBus
|
||||
//! \publicsection
|
||||
//! @{
|
||||
virtual BlackMisc::Audio::CAudioDeviceInfoList getRegisteredDevices() const override;
|
||||
virtual void registerDevices(const BlackMisc::Audio::CAudioDeviceInfoList &devices) override;
|
||||
virtual void unRegisterDevices(const BlackMisc::Audio::CAudioDeviceInfoList &devices) override;
|
||||
@@ -52,7 +49,6 @@ namespace BlackCore
|
||||
virtual void registerAudioCallsign(const BlackMisc::Aviation::CCallsign &callsign, const BlackMisc::CIdentifier &identifier) override;
|
||||
virtual void unRegisterAudioCallsign(const BlackMisc::Aviation::CCallsign &callsign, const BlackMisc::CIdentifier &identifier) override;
|
||||
virtual bool hasRegisteredAudioCallsign(const BlackMisc::Aviation::CCallsign &callsign) const override;
|
||||
//! @}
|
||||
|
||||
protected:
|
||||
//! Constructor
|
||||
|
||||
@@ -58,10 +58,6 @@ namespace BlackCore
|
||||
static void unitTestRelaySignals();
|
||||
|
||||
public slots:
|
||||
//! All DBus interface overrides
|
||||
//! \publicsection
|
||||
//! @{
|
||||
//! Register a device on a machine (for core/GUI it will return all known devices on all machines)
|
||||
virtual BlackMisc::Audio::CAudioDeviceInfoList getRegisteredDevices() const override;
|
||||
virtual void registerDevices(const BlackMisc::Audio::CAudioDeviceInfoList &devices) override;
|
||||
virtual void unRegisterDevices(const BlackMisc::Audio::CAudioDeviceInfoList &devices) override;
|
||||
@@ -69,7 +65,6 @@ namespace BlackCore
|
||||
virtual void registerAudioCallsign(const BlackMisc::Aviation::CCallsign &callsign, const BlackMisc::CIdentifier &identifier) override;
|
||||
virtual void unRegisterAudioCallsign(const BlackMisc::Aviation::CCallsign &callsign, const BlackMisc::CIdentifier &identifier) override;
|
||||
virtual bool hasRegisteredAudioCallsign(const BlackMisc::Aviation::CCallsign &callsign) const override;
|
||||
//! @}
|
||||
|
||||
private:
|
||||
BlackMisc::CGenericDBusInterface *m_dBusInterface;
|
||||
|
||||
@@ -44,17 +44,14 @@
|
||||
|
||||
// clazy:excludeall=const-signal-or-slot
|
||||
|
||||
//! \addtogroup dbus
|
||||
//! @{
|
||||
|
||||
//! DBus interface for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTNETWORK_INTERFACENAME "org.swift_project.blackcore.contextnetwork"
|
||||
|
||||
//! DBus object path for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTNETWORK_OBJECTPATH "/network"
|
||||
|
||||
//! @}
|
||||
|
||||
class QDBusConnection;
|
||||
namespace BlackMisc
|
||||
{
|
||||
|
||||
@@ -95,8 +95,7 @@ namespace BlackCore
|
||||
//! Destructor
|
||||
virtual ~CContextNetwork() override;
|
||||
|
||||
//! \ingroup remoteaircraftprovider
|
||||
//! @{
|
||||
// remoteaircraftprovider
|
||||
virtual BlackMisc::Aviation::CAircraftSituationList remoteAircraftSituations(const BlackMisc::Aviation::CCallsign &callsign) const override;
|
||||
virtual BlackMisc::Aviation::CAircraftSituation remoteAircraftSituation(const BlackMisc::Aviation::CCallsign &callsign, int index) const override;
|
||||
virtual BlackMisc::MillisecondsMinMaxMean remoteAircraftSituationsTimestampDifferenceMinMaxMean(const BlackMisc::Aviation::CCallsign &callsign) const override;
|
||||
@@ -126,10 +125,8 @@ namespace BlackCore
|
||||
std::function<void(const BlackMisc::Aviation::CCallsign &)> removedAircraftSlot,
|
||||
std::function<void(const BlackMisc::Simulation::CAirspaceAircraftSnapshot &)> aircraftSnapshotSlot
|
||||
) override;
|
||||
//! @}
|
||||
|
||||
//! \ingroup clientprovider
|
||||
//! @{
|
||||
// clientprovider
|
||||
virtual void setClients(const BlackMisc::Network::CClientList &clients) override;
|
||||
virtual void clearClients() override;
|
||||
virtual BlackMisc::Network::CClient getClientOrDefaultForCallsign(const BlackMisc::Aviation::CCallsign &callsign) const override;
|
||||
@@ -141,7 +138,6 @@ namespace BlackCore
|
||||
virtual bool addClientGndCapability(const BlackMisc::Aviation::CCallsign &callsign) override;
|
||||
virtual bool setClientGndCapability(const BlackMisc::Aviation::CCallsign &callsign, bool supportGndFlag) override;
|
||||
virtual void markAsSwiftClient(const BlackMisc::Aviation::CCallsign &callsign) override;
|
||||
//! @}
|
||||
|
||||
//! \copydoc IContextNetwork::connectRawFsdMessageSignal
|
||||
virtual QMetaObject::Connection connectRawFsdMessageSignal(QObject *receiver, RawFsdMessageReceivedSlot rawFsdMessageReceivedSlot) override;
|
||||
@@ -149,21 +145,20 @@ namespace BlackCore
|
||||
//! Gracefully shut down, e.g. for thread safety
|
||||
void gracefulShutdown();
|
||||
|
||||
//! Network library
|
||||
//! \protected
|
||||
//! \remarks normally only for core facade internal usage
|
||||
//! \remarks public so values can be logged/monitored
|
||||
//! @{
|
||||
//! Network library
|
||||
Fsd::CFSDClient *fsdClient() const { return m_fsdClient; }
|
||||
|
||||
//! Airspace
|
||||
//! \protected
|
||||
//! \remarks normally only for core facade internal usage
|
||||
//! \remarks public so values can be logged/monitored
|
||||
CAirspaceMonitor *airspace() const { return m_airspace; }
|
||||
//! @}
|
||||
|
||||
public slots:
|
||||
// ------------ from context and provider interface -------------
|
||||
//! \ingroup remoteaircraftprovider
|
||||
//! @{
|
||||
// remoteaircraftprovider
|
||||
|
||||
// emit signal when changed
|
||||
virtual bool updateAircraftEnabled(const BlackMisc::Aviation::CCallsign &callsign, bool enabledForRendering) override;
|
||||
@@ -203,14 +198,11 @@ namespace BlackCore
|
||||
virtual bool testAddAltitudeOffset(const BlackMisc::Aviation::CCallsign &callsign, const BlackMisc::PhysicalQuantities::CLength &offset = BlackMisc::PhysicalQuantities::CLength::null()) override;
|
||||
virtual QStringList getNetworkPresetValues() const override;
|
||||
virtual BlackMisc::Aviation::CCallsign getPartnerCallsign() const override;
|
||||
//! @}
|
||||
|
||||
//! \ingroup clientprovider
|
||||
//! @{
|
||||
// clientprovider
|
||||
virtual BlackMisc::Network::CClientList getClients() const override;
|
||||
virtual BlackMisc::Network::CClientList getClientsForCallsigns(const BlackMisc::Aviation::CCallsignSet &callsigns) const override;
|
||||
virtual bool setOtherClient(const BlackMisc::Network::CClient &client) override;
|
||||
//! @}
|
||||
|
||||
//! In transition state, e.g. connecting, disconnecting.
|
||||
//! \details In such a state it is advisable to wait until an end state (connected/disconnected) is reached
|
||||
@@ -219,7 +211,6 @@ namespace BlackCore
|
||||
|
||||
// --------------------- IContextNetwork implementations ---------------------
|
||||
//! \addtogroup swiftdotcommands
|
||||
//! @{
|
||||
//! <pre>
|
||||
//! .m .msg .chat callsign|freq. message message text
|
||||
//! .altos .altoffset altitude offset for testing
|
||||
@@ -228,7 +219,6 @@ namespace BlackCore
|
||||
//! .watchdog on|off watchdog on/off
|
||||
//! .wallop message send wallop message
|
||||
//! </pre>
|
||||
//! @}
|
||||
//! \copydoc IContextNetwork::parseCommandLine
|
||||
virtual bool parseCommandLine(const QString &commandLine, const BlackMisc::CIdentifier &originator) override;
|
||||
|
||||
@@ -250,8 +240,6 @@ namespace BlackCore
|
||||
BlackMisc::CSimpleCommandParser::registerCommand({".disable callsign", "disable/ignore callsign"});
|
||||
}
|
||||
|
||||
//! \publicsection
|
||||
//! @{
|
||||
virtual void requestAtcBookingsUpdate() const override;
|
||||
virtual BlackMisc::Aviation::CAtcStationList getAtcStationsBooked(bool recalculateDistance) const override;
|
||||
virtual BlackMisc::Aviation::CAtcStationList getAtcStationsOnline(bool recalculateDistance) const override;
|
||||
@@ -284,7 +272,6 @@ namespace BlackCore
|
||||
virtual void testReceivedAtisMessage(const BlackMisc::Aviation::CCallsign &callsign, const BlackMisc::Aviation::CInformationMessage &msg) override;
|
||||
virtual void testReceivedTextMessages(const BlackMisc::Network::CTextMessageList &textMessages) override;
|
||||
virtual void testRequestAircraftConfig(const BlackMisc::Aviation::CCallsign &callsign) override;
|
||||
//! @}
|
||||
// --------------------- IContextNetwork implementations ---------------------
|
||||
|
||||
protected:
|
||||
|
||||
@@ -29,17 +29,14 @@
|
||||
|
||||
// clazy:excludeall=const-signal-or-slot
|
||||
|
||||
//! \addtogroup dbus
|
||||
//! @{
|
||||
|
||||
//! DBus interface for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTOWNAIRCRAFT_INTERFACENAME "org.swift_project.blackcore.contextownaircraft"
|
||||
|
||||
//! DBus object path for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTOWNAIRCRAFT_OBJECTPATH "/ownaircraft"
|
||||
|
||||
//! @}
|
||||
|
||||
class QDBusConnection;
|
||||
namespace BlackMisc
|
||||
{
|
||||
|
||||
@@ -177,14 +177,12 @@ namespace BlackCore
|
||||
virtual bool setTransponderMode(BlackMisc::Aviation::CTransponder::TransponderMode mode) override;
|
||||
|
||||
//! \addtogroup swiftdotcommands
|
||||
//! @{
|
||||
//! <pre>
|
||||
//! .x .xpdr code set transponder code BlackCore::Context::CContextOwnAircraft
|
||||
//! .x .xpdr mode set transponder mode BlackCore::Context::CContextOwnAircraft
|
||||
//! .com1 .com2 frequency set COM1/2 frequency BlackCore::Context::CContextOwnAircraft
|
||||
//! .selcal code set SELCAL code BlackCore::Context::CContextOwnAircraft
|
||||
//! </pre>
|
||||
//! @}
|
||||
//! \copydoc IContextOwnAircraft::parseCommandLine
|
||||
virtual bool parseCommandLine(const QString &commandLine, const BlackMisc::CIdentifier &originator) override;
|
||||
|
||||
@@ -237,8 +235,8 @@ namespace BlackCore
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxChangedSimulatorStatus(int status);
|
||||
|
||||
//! Actions
|
||||
//! @{
|
||||
//! Actions
|
||||
void actionToggleTransponder(bool keydown);
|
||||
void actionIdent(bool keydown);
|
||||
//! @}
|
||||
|
||||
@@ -62,8 +62,6 @@ namespace BlackCore
|
||||
static void unitTestRelaySignals();
|
||||
|
||||
public slots:
|
||||
//! \publicsection
|
||||
//! @{
|
||||
virtual BlackMisc::Simulation::CSimulatedAircraft getOwnAircraft() const override;
|
||||
virtual BlackMisc::Aviation::CComSystem getOwnComSystem(BlackMisc::Aviation::CComSystem::ComUnit unit) const override;
|
||||
virtual BlackMisc::Aviation::CTransponder getOwnTransponder() const override;
|
||||
@@ -79,7 +77,6 @@ namespace BlackCore
|
||||
virtual void toggleTransponderMode() override;
|
||||
virtual bool setTransponderMode(BlackMisc::Aviation::CTransponder::TransponderMode mode) override;
|
||||
virtual bool parseCommandLine(const QString &commandLine, const BlackMisc::CIdentifier &originator) override;
|
||||
//! @}
|
||||
|
||||
protected:
|
||||
//! \brief Constructor
|
||||
|
||||
@@ -40,17 +40,14 @@
|
||||
|
||||
// clazy:excludeall=const-signal-or-slot
|
||||
|
||||
//! \addtogroup dbus
|
||||
//! @{
|
||||
|
||||
//! DBus interface for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTSIMULATOR_INTERFACENAME "org.swift_project.blackcore.contextsimulator"
|
||||
|
||||
//! DBus object path for context
|
||||
//! \addtogroup dbus
|
||||
#define BLACKCORE_CONTEXTSIMULATOR_OBJECTPATH "/simulator"
|
||||
|
||||
//! @}
|
||||
|
||||
class QDBusConnection;
|
||||
|
||||
namespace BlackMisc
|
||||
|
||||
@@ -75,8 +75,6 @@ namespace BlackCore
|
||||
|
||||
public slots:
|
||||
// ----------------------------- context interface -----------------------------
|
||||
//! \publicsection
|
||||
//! @{
|
||||
virtual BlackMisc::Simulation::CSimulatorPluginInfo getSimulatorPluginInfo() const override;
|
||||
virtual BlackMisc::Simulation::CSimulatorPluginInfoList getAvailableSimulatorPlugins() const override;
|
||||
virtual BlackMisc::Simulation::Settings::CSimulatorSettings getSimulatorSettings() const override;
|
||||
@@ -135,10 +133,8 @@ namespace BlackCore
|
||||
// also in IAircraftModelSetProvider
|
||||
virtual BlackMisc::Simulation::CAircraftModelList getModelSet() const override;
|
||||
virtual int getModelSetCount() const override;
|
||||
//! @}
|
||||
|
||||
//! \addtogroup swiftdotcommands
|
||||
//! @{
|
||||
//! <pre>
|
||||
//! .plugin forwarded to plugin, see details there
|
||||
//! .driver .drv forwarded to plugin (same as above)
|
||||
@@ -146,7 +142,6 @@ namespace BlackCore
|
||||
//! .ris debug on|off interpolation/rendering setup, debug messages
|
||||
//! .ris parts on|off interpolation/rendering setup, aircraft parts
|
||||
//! </pre>
|
||||
//! @}
|
||||
//! \copydoc IContextSimulator::parseCommandLine
|
||||
virtual bool parseCommandLine(const QString &commandLine, const BlackMisc::CIdentifier &originator) override;
|
||||
// ----------------------------- context interface -----------------------------
|
||||
@@ -189,39 +184,46 @@ namespace BlackCore
|
||||
static constexpr int MaxModelAddedFailoverTrials = 3; //!< if model cannot be added, try again max <n> times
|
||||
|
||||
// ------------ slots connected with network or other contexts ---------
|
||||
//! \ingroup crosscontextfunction
|
||||
//! @{
|
||||
|
||||
//! Remote aircraft added and ready for model matching
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxAddedRemoteAircraftReadyForModelMatching(const BlackMisc::Simulation::CSimulatedAircraft &remoteAircraft);
|
||||
|
||||
//! Remove remote aircraft
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxRemovedRemoteAircraft(const BlackMisc::Aviation::CCallsign &callsign);
|
||||
|
||||
//! Changed remote aircraft model
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxChangedRemoteAircraftModel(const BlackMisc::Simulation::CSimulatedAircraft &aircraft, const BlackMisc::CIdentifier &originator);
|
||||
|
||||
//! Changed own aircraft model
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxChangedOwnAircraftModel(const BlackMisc::Simulation::CAircraftModel &aircraftModel, const BlackMisc::CIdentifier &originator);
|
||||
|
||||
//! Enable / disable aircraft
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxChangedRemoteAircraftEnabled(const BlackMisc::Simulation::CSimulatedAircraft &aircraft);
|
||||
|
||||
//! Network connection status
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxNetworkConnectionStatusChanged(const BlackMisc::Network::CConnectionStatus &from, const BlackMisc::Network::CConnectionStatus &to);
|
||||
|
||||
//! Update simulator cockpit from context, because someone else has changed cockpit (e.g. GUI, 3rd party)
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxUpdateSimulatorCockpitFromContext(const BlackMisc::Simulation::CSimulatedAircraft &ownAircraft, const BlackMisc::CIdentifier &originator);
|
||||
|
||||
//! Update simulator SELCAL from context, because someone else has changed cockpit (e.g. GUI, 3rd party)
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxUpdateSimulatorSelcalFromContext(const BlackMisc::Aviation::CSelcal &selcal, const BlackMisc::CIdentifier &originator);
|
||||
|
||||
//! Raw data when a new aircraft was requested, used for statistics
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxNetworkRequestedNewAircraft(const BlackMisc::Aviation::CCallsign &callsign, const QString &aircraftIcao, const QString &airlineIcao, const QString &livery);
|
||||
|
||||
//! Text message received
|
||||
//! \ingroup crosscontextfunction
|
||||
void xCtxTextMessagesReceived(const BlackMisc::Network::CTextMessageList &textMessages);
|
||||
//! @}
|
||||
// ------------ slots connected with network or other contexts ---------
|
||||
|
||||
//! Handle new connection status of simulator
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace BlackCore::Fsd
|
||||
//! Construct from tokens
|
||||
static AtcDataUpdate fromTokens(const QStringList &tokens);
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
int m_frequencykHz = 0.0;
|
||||
BlackMisc::Network::CFacilityType m_facility;
|
||||
int m_visibleRange = 0.0;
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$ID"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
std::uint16_t m_clientId = 0;
|
||||
QString m_clientName;
|
||||
int m_clientVersionMajor = BlackConfig::CBuildConfig::getVersion().majorVersion();
|
||||
|
||||
@@ -37,8 +37,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$CQ"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
ClientQueryType m_queryType = ClientQueryType::Unknown;
|
||||
QStringList m_queryData;
|
||||
//! @}
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$CR"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
ClientQueryType m_queryType {};
|
||||
QStringList m_responseData;
|
||||
//! @}
|
||||
|
||||
@@ -176,8 +176,8 @@ namespace BlackCore::Fsd
|
||||
AircraftConfig = (1 << 9)
|
||||
};
|
||||
|
||||
//! Operators
|
||||
//! @{
|
||||
//! Operators
|
||||
inline Capabilities operator | (Capabilities lhs, Capabilities rhs)
|
||||
{
|
||||
return static_cast<Capabilities>(static_cast<int>(lhs) | static_cast<int>(rhs));
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return QStringLiteral("SIMDATA"); }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString m_model;
|
||||
QString m_livery;
|
||||
quint64 m_timestamp = 0;
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$FP"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
FlightType m_flightType {};
|
||||
QString m_aircraftIcaoType;
|
||||
int m_trueCruisingSpeed = 0;
|
||||
|
||||
@@ -50,8 +50,8 @@
|
||||
|
||||
#include <atomic>
|
||||
|
||||
//! Protocol version
|
||||
//! @{
|
||||
//! Protocol version
|
||||
#define PROTOCOL_REVISION_CLASSIC 9
|
||||
#define PROTOCOL_REVISION_VATSIM_ATC 10
|
||||
#define PROTOCOL_REVISION_VATSIM_AUTH 100
|
||||
@@ -96,10 +96,10 @@ namespace BlackCore::Fsd
|
||||
BlackMisc::Simulation::IRemoteAircraftProvider *remoteAircraftProvider,
|
||||
QObject *owner = nullptr);
|
||||
|
||||
//! @{
|
||||
//! Preset functions
|
||||
//! \remark Necessary functions to setup client. Set them all!
|
||||
//! \threadsafe
|
||||
//! @{
|
||||
void setClientName(const QString &clientName) { QWriteLocker l(&m_lockUserClientBuffered); m_clientName = clientName; }
|
||||
void setHostApplication(const QString &hostApplication) { QWriteLocker l(&m_lockUserClientBuffered); m_hostApplication = hostApplication; }
|
||||
void setVersion(int major, int minor) { QWriteLocker l(&m_lockUserClientBuffered); m_versionMajor = major; m_versionMinor = minor; }
|
||||
@@ -143,22 +143,22 @@ namespace BlackCore::Fsd
|
||||
//! \threadsafe
|
||||
PilotRating getPilotRating() const { QReadLocker l(&m_lockUserClientBuffered); return m_pilotRating; }
|
||||
|
||||
//! Connenct/disconnect
|
||||
//! @{
|
||||
//! Connenct/disconnect
|
||||
void connectToServer();
|
||||
void disconnectFromServer();
|
||||
//! @}
|
||||
|
||||
//! Interim positions
|
||||
//! @{
|
||||
//! Interim positions
|
||||
void addInterimPositionReceiver(const BlackMisc::Aviation::CCallsign &receiver) { m_interimPositionReceivers.push_back(receiver); }
|
||||
void removeInterimPositionReceiver(const BlackMisc::Aviation::CCallsign &receiver) { m_interimPositionReceivers.remove(receiver); }
|
||||
//! @}
|
||||
|
||||
//! @{
|
||||
//! Convenience functions for sendClientQuery
|
||||
//! \remark pseudo private, used in CAirspaceMonitor and network context
|
||||
//! \private
|
||||
//! @{
|
||||
void sendClientQueryCapabilities(const BlackMisc::Aviation::CCallsign &callsign);
|
||||
void sendClientQueryCom1Freq(const BlackMisc::Aviation::CCallsign &callsign);
|
||||
void sendClientQueryRealName(const BlackMisc::Aviation::CCallsign &callsign);
|
||||
@@ -175,22 +175,22 @@ namespace BlackCore::Fsd
|
||||
void sendPlaneInfoRequestFsinn(const BlackMisc::Aviation::CCallsign &callsign);
|
||||
//! @}
|
||||
|
||||
//! Interim pos.receivers
|
||||
//! @{
|
||||
//! Interim pos.receivers
|
||||
BlackMisc::Aviation::CCallsignSet getInterimPositionReceivers() const;
|
||||
void setInterimPositionReceivers(const BlackMisc::Aviation::CCallsignSet &interimPositionReceivers);
|
||||
//! @}
|
||||
|
||||
//! Connection status
|
||||
//! @{
|
||||
//! Connection status
|
||||
BlackMisc::Network::CConnectionStatus getConnectionStatus() const { QReadLocker l(&m_lockConnectionStatus); return m_connectionStatus; }
|
||||
bool isConnected() const { return this->getConnectionStatus().isConnected(); }
|
||||
bool isDisconnected() const { return this->getConnectionStatus().isDisconnected(); }
|
||||
bool isPendingConnection() const;
|
||||
//! @}
|
||||
|
||||
//! Statistics enable functions
|
||||
//! @{
|
||||
//! Statistics enable functions
|
||||
bool setStatisticsEnable(bool enabled) { m_statistics = enabled; return enabled; }
|
||||
bool isStatisticsEnabled() const { return m_statistics; }
|
||||
//! @}
|
||||
@@ -208,8 +208,8 @@ namespace BlackCore::Fsd
|
||||
void gracefulShutdown();
|
||||
|
||||
signals:
|
||||
//! Client responses received
|
||||
//! @{
|
||||
//! Client responses received
|
||||
void atcDataUpdateReceived(const BlackMisc::Aviation::CCallsign &callsign, const BlackMisc::PhysicalQuantities::CFrequency &freq,
|
||||
const BlackMisc::Geo::CCoordinateGeodetic &pos, const BlackMisc::PhysicalQuantities::CLength &range);
|
||||
void deleteAtcReceived(const QString &cid);
|
||||
@@ -256,11 +256,9 @@ namespace BlackCore::Fsd
|
||||
private:
|
||||
//! \cond
|
||||
friend BlackFsdTest::CTestFSDClient;
|
||||
//! \endcond
|
||||
|
||||
//! Convenience functions for sendClientQuery
|
||||
//! \remark really private, ONLY used by UNIT test, not CAirspaceMonitor
|
||||
//! @{
|
||||
// Convenience functions for sendClientQuery
|
||||
// really private, ONLY used by UNIT test, not CAirspaceMonitor
|
||||
void sendLogin(const QString &token = {});
|
||||
void sendDeletePilot();
|
||||
void sendDeleteAtc();
|
||||
@@ -279,10 +277,10 @@ namespace BlackCore::Fsd
|
||||
//
|
||||
void sendMessageString(const QString &message);
|
||||
void sendQueuedMessage();
|
||||
//! @}
|
||||
//! \endcond
|
||||
|
||||
//! Increase the statistics value for given identifier
|
||||
//! @{
|
||||
//! Increase the statistics value for given identifier
|
||||
int increaseStatisticsValue(const QString &identifier, const QString &appendix = {});
|
||||
int increaseStatisticsValue(const QString &identifier, int value);
|
||||
//! @}
|
||||
@@ -308,8 +306,8 @@ namespace BlackCore::Fsd
|
||||
this->sendMessageString(messageToFSDString(message));
|
||||
}
|
||||
|
||||
//! Unit test/debug functions
|
||||
//! @{
|
||||
//! Unit test/debug functions
|
||||
void sendFsdMessage(const QString &message);
|
||||
void setUnitTestMode(bool on) { m_unitTestMode = on; }
|
||||
//! @}
|
||||
@@ -360,8 +358,8 @@ namespace BlackCore::Fsd
|
||||
// Type to string
|
||||
const QString &messageTypeToString(MessageType mt) const;
|
||||
|
||||
//! Handle response tokens
|
||||
//! @{
|
||||
//! Handle response tokens
|
||||
void handleAtcDataUpdate(const QStringList &tokens);
|
||||
void handleAuthChallenge(const QStringList &tokens);
|
||||
void handleAuthResponse(const QStringList &tokens);
|
||||
@@ -441,8 +439,8 @@ namespace BlackCore::Fsd
|
||||
//! Save the statistics
|
||||
bool saveNetworkStatistics(const QString &server);
|
||||
|
||||
//! Timers
|
||||
//! @{
|
||||
//! Timers
|
||||
void startPositionTimers();
|
||||
void stopPositionTimers();
|
||||
//! @}
|
||||
|
||||
@@ -31,8 +31,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$DI"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString m_serverVersion;
|
||||
QString m_initialChallenge;
|
||||
//! @}
|
||||
|
||||
@@ -33,8 +33,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "#SB"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
double m_latitude = 0.0;
|
||||
double m_longitude = 0.0;
|
||||
int m_altitudeTrue = 0.0;
|
||||
|
||||
@@ -35,8 +35,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "@"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
BlackMisc::Aviation::CTransponder::TransponderMode m_transponderMode = BlackMisc::Aviation::CTransponder::StateStandby;
|
||||
int m_transponderCode = 0;
|
||||
PilotRating m_rating = PilotRating::Unknown;
|
||||
|
||||
@@ -36,8 +36,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return QStringLiteral("#SB"); }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString m_airlineIcao;
|
||||
QString m_aircraftIcao;
|
||||
QString m_aircraftIcaoCombinedType;
|
||||
|
||||
@@ -32,8 +32,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "#SB"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString m_aircraft;
|
||||
QString m_airline;
|
||||
QString m_livery;
|
||||
|
||||
@@ -36,8 +36,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "#SB"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString m_airlineIcao;
|
||||
QString m_aircraftIcao;
|
||||
QString m_aircraftIcaoCombinedType;
|
||||
|
||||
@@ -32,8 +32,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$XX"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString m_hostname;
|
||||
//! @}
|
||||
|
||||
|
||||
@@ -36,15 +36,10 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "-MD"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
ClientQueryType m_queryType = ClientQueryType::Unknown;
|
||||
QStringList m_queryData;
|
||||
//! @}
|
||||
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
QString m_partsval1;
|
||||
QString m_partsval2;
|
||||
QString m_partsval3;
|
||||
|
||||
@@ -35,14 +35,14 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$ER"; }
|
||||
|
||||
//! Getter
|
||||
//! @{
|
||||
//! Getter
|
||||
const QString &getCausingParameter() const { static const QString n("no details"); return m_causingParameter.isEmpty() ? n : m_causingParameter; }
|
||||
const QString &getDescription() const { static const QString n("no description"); return m_description.isEmpty() ? n : m_description; }
|
||||
//! @}
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
ServerErrorCode m_errorNumber {};
|
||||
QString m_causingParameter;
|
||||
QString m_description;
|
||||
|
||||
@@ -39,8 +39,8 @@ namespace BlackCore::Fsd
|
||||
//! Return a regular visual update with the same values
|
||||
VisualPilotDataUpdate toUpdate() const;
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
double m_latitude = 0.0;
|
||||
double m_longitude = 0.0;
|
||||
double m_altitudeTrue = 0.0;
|
||||
|
||||
@@ -38,8 +38,8 @@ namespace BlackCore::Fsd
|
||||
//! Return a regular visual update with the same values
|
||||
VisualPilotDataUpdate toUpdate() const;
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
double m_latitude = 0.0;
|
||||
double m_longitude = 0.0;
|
||||
double m_altitudeTrue = 0.0;
|
||||
|
||||
@@ -32,8 +32,8 @@ namespace BlackCore::Fsd
|
||||
//! PDU identifier
|
||||
static QString pdu() { return "$SF"; }
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
QString m_client;
|
||||
bool m_active = false;
|
||||
//! @}
|
||||
|
||||
@@ -43,8 +43,8 @@ namespace BlackCore::Fsd
|
||||
//! Return a stopped update with the same values
|
||||
VisualPilotDataStopped toStopped() const;
|
||||
|
||||
//! Properties
|
||||
//! @{
|
||||
//! Properties
|
||||
double m_latitude = 0.0;
|
||||
double m_longitude = 0.0;
|
||||
double m_altitudeTrue = 0.0;
|
||||
|
||||
@@ -286,7 +286,6 @@ namespace BlackCore
|
||||
bool isEmulatedDriver() const;
|
||||
|
||||
//! \addtogroup swiftdotcommands
|
||||
//! @{
|
||||
//! <pre>
|
||||
//! .drv cg length clear|modelstring set overridden CG for model string BlackCore::ISimulator
|
||||
//! .drv unload unload plugin BlackCore::ISimulator
|
||||
@@ -302,7 +301,6 @@ namespace BlackCore
|
||||
//! .drv aircraft rm callsign remove aircraft BlackCore::ISimulator
|
||||
//! .drv fsuipc on|off enable/disable FSUIPC (if applicable) BlackSimPlugin::FsCommon::CSimulatorFsCommon
|
||||
//! </pre>
|
||||
//! @}
|
||||
//! Parse command line for simulator drivers, derived classes can add specific parsing by overriding ISimulator::parseDetails
|
||||
virtual bool parseCommandLine(const QString &commandLine, const BlackMisc::CIdentifier &originator);
|
||||
|
||||
@@ -423,8 +421,8 @@ namespace BlackCore
|
||||
BlackMisc::Network::IClientProvider *clientProvider,
|
||||
QObject *parent = nullptr);
|
||||
|
||||
//! When swift DB data are read
|
||||
//! @{
|
||||
//! When swift DB data are read
|
||||
virtual void onSwiftDbAllDataRead();
|
||||
virtual void onSwiftDbModelMatchingEntitiesRead();
|
||||
virtual void onSwiftDbAirportsRead();
|
||||
@@ -445,11 +443,8 @@ namespace BlackCore
|
||||
//! Max.airports in range
|
||||
int maxAirportsInRange() const;
|
||||
|
||||
//! Connected with remote aircraft provider signals
|
||||
//! @{
|
||||
//! Recalculate the rendered aircraft, this happens when restrictions are applied (max. aircraft, range)
|
||||
virtual void onRecalculatedRenderedAircraft(const BlackMisc::Simulation::CAirspaceAircraftSnapshot &snapshot);
|
||||
//! @}
|
||||
|
||||
//! Add new remote aircraft physically to the simulator
|
||||
//! \sa changeRemoteAircraftEnabled to hide a remote aircraft
|
||||
@@ -738,8 +733,8 @@ namespace BlackCore
|
||||
//! ISimulatorVirtual destructor
|
||||
virtual ~ISimulatorFactory() {}
|
||||
|
||||
//! Not copyable
|
||||
//! @{
|
||||
//! Not copyable
|
||||
ISimulatorFactory(const ISimulatorFactory &) = delete;
|
||||
ISimulatorFactory &operator=(const ISimulatorFactory &) = delete;
|
||||
//! @}
|
||||
|
||||
@@ -48,10 +48,8 @@ namespace BlackCore::Vatsim
|
||||
void dataRead(BlackMisc::Network::CEntityFlags::Entity entity, BlackMisc::Network::CEntityFlags::ReadState state, int number, const QUrl &url);
|
||||
|
||||
protected:
|
||||
//! \name BlackCore::CThreadedReader overrides
|
||||
//! @{
|
||||
// CThreadedReader overrides
|
||||
virtual void doWorkImpl() override;
|
||||
//! @}
|
||||
|
||||
private:
|
||||
//! Bookings have been read
|
||||
|
||||
@@ -124,10 +124,8 @@ namespace BlackCore::Vatsim
|
||||
void dataRead(BlackMisc::Network::CEntityFlags::Entity entity, BlackMisc::Network::CEntityFlags::ReadState state, int number, const QUrl &url);
|
||||
|
||||
protected:
|
||||
//! \name BlackCore::CThreadedReader overrides
|
||||
//! @{
|
||||
// CThreadedReader overrides
|
||||
virtual void doWorkImpl() override;
|
||||
//! @}
|
||||
|
||||
private:
|
||||
//! Section in file
|
||||
|
||||
@@ -60,10 +60,8 @@ namespace BlackCore::Vatsim
|
||||
void dataRead(BlackMisc::Network::CEntityFlags::Entity entity, BlackMisc::Network::CEntityFlags::ReadState state, int number, const QUrl &url);
|
||||
|
||||
protected:
|
||||
//! \name BlackCore::CThreadedReader overrides
|
||||
//! @{
|
||||
// CThreadedReader overrides
|
||||
virtual void doWorkImpl() override;
|
||||
//! @}
|
||||
|
||||
private:
|
||||
//! Decode METARs
|
||||
|
||||
@@ -30,8 +30,8 @@ namespace BlackCore
|
||||
//! Ctor
|
||||
Q_INVOKABLE MSWebServices() {}
|
||||
|
||||
//! Functions calling the web services
|
||||
//! @{
|
||||
//! Functions calling the web services
|
||||
Q_INVOKABLE int countAircraftIcaoCodesForDesignator(const QString &designator) const;
|
||||
Q_INVOKABLE int countAirlineIcaoCodesForDesignator(const QString &designator) const;
|
||||
//! @}
|
||||
|
||||
Reference in New Issue
Block a user