1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-11-21 23:55:13 -05:00

Some clang warnong fixes

This commit is contained in:
f4exb 2022-07-24 21:48:02 +02:00
parent 994584cabc
commit 2c3ccc49af
9 changed files with 8 additions and 17 deletions

View File

@ -3362,7 +3362,6 @@ void ADSBDemodGUI::updateAirports()
++i;
}
// Save settings we've just used so we know if they've changed
m_currentAirportRange = m_currentAirportRange;
m_currentAirportMinimumSize = m_settings.m_airportMinimumSize;
m_currentDisplayHeliports = m_settings.m_displayHeliports;
}

View File

@ -115,7 +115,6 @@ private:
void *m_dab;
DABDemodDevice m_device;
audiodata m_ad;
packetdata m_pd;
API_struct m_api;
NCO m_nco;

View File

@ -370,8 +370,6 @@ void PagerDemodSink::decodeBatch()
void PagerDemodSink::processOneSample(Complex &ci)
{
Complex ca;
// FM demodulation
double magsqRaw;
Real deviation;

View File

@ -119,8 +119,6 @@ void RadiosondeDemodSink::feed(const SampleVector::const_iterator& begin, const
void RadiosondeDemodSink::processOneSample(Complex &ci)
{
Complex ca;
// FM demodulation
double magsqRaw;
Real deviation;

View File

@ -441,7 +441,6 @@ private:
int m_rotatorFeatureSetIndex;
int m_rotatorFeatureIndex;
void (*sweepState)();
float m_sweep1; // Current sweep position
float m_sweep2;
float m_sweep1Stop;

View File

@ -796,8 +796,6 @@ void RadioClockSink::wwvb()
void RadioClockSink::processOneSample(Complex &ci)
{
Complex ca;
// Calculate average and peak levels for level meter
Real re = ci.real() / SDR_RX_SCALEF;
Real im = ci.imag() / SDR_RX_SCALEF;

View File

@ -248,7 +248,7 @@ void DeviceSet::loadTxChannelSettings(const Preset *preset, PluginAPI *pluginAPI
for (int i = 0; i < preset->getChannelCount(); i++)
{
const Preset::ChannelConfig& channelConfig = preset->getChannelConfig(i);
ChannelAPI *channelAPI;
ChannelAPI *channelAPI = nullptr;
// if we have one instance available already, use it
@ -346,7 +346,7 @@ void DeviceSet::loadMIMOChannelSettings(const Preset *preset, PluginAPI *pluginA
for (int i = 0; i < preset->getChannelCount(); i++)
{
const Preset::ChannelConfig& channelConfig = preset->getChannelConfig(i);
ChannelAPI *channelAPI;
ChannelAPI *channelAPI = nullptr;
// if we have one instance available already, use it

View File

@ -27,8 +27,6 @@ class SDRBASE_API ObjectPipe : public QObject
Q_OBJECT
public:
ObjectPipe();
ObjectPipe(const ObjectPipe&) = default;
ObjectPipe& operator=(const ObjectPipe&) = default;
void setToBeDeleted(int reason, QObject *object);
void unsetToBeDeleted();

View File

@ -3337,6 +3337,8 @@ void GLSpectrum::mousePressEvent(QMouseEvent* event)
case SpectrumAnnotationMarker::ShowFull:
(*iMarker)->m_show = SpectrumAnnotationMarker::ShowTop;
break;
case SpectrumAnnotationMarker::Hidden:
break;
}
selected = true;
}
@ -3836,13 +3838,13 @@ QString GLSpectrum::displayScaledF(float value, char type, int precision, bool s
}
else
{
if (posValue < 1000) {
if (posValue < 1e3) {
return tr("%1").arg(QString::number(value, type, precision));
} else if (posValue < 1000000) {
} else if (posValue < 1e6) {
return tr("%1%2").arg(QString::number(value / 1000.0, type, precision)).arg(showMult ? "k" : "");
} else if (posValue < 1000000000) {
} else if (posValue < 1e9) {
return tr("%1%2").arg(QString::number(value / 1000000.0, type, precision)).arg(showMult ? "M" : "");
} else if (posValue < 1000000000000) {
} else if (posValue < 1e12) {
return tr("%1%2").arg(QString::number(value / 1000000000.0, type, precision)).arg(showMult ? "G" : "");
} else {
return tr("%1").arg(QString::number(value, 'e', precision));