Skip to content

Commit

Permalink
Harmonize style
Browse files Browse the repository at this point in the history
  • Loading branch information
BatchDrake committed Aug 18, 2024
1 parent 7d3eda9 commit 0234f8f
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 18 deletions.
8 changes: 4 additions & 4 deletions AbstractWaterfall.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -559,7 +559,7 @@ void AbstractWaterfall::setWaterfallSpan(quint64 span_ms)
}

/** Get waterfall time resolution in milleconds / line. */
double AbstractWaterfall::getWfTimeRes(void)
double AbstractWaterfall::getWfTimeRes()
{
if (msec_per_wfline)
return msec_per_wfline;
Expand Down Expand Up @@ -1646,7 +1646,7 @@ void AbstractWaterfall::updateOverlay()
}

/** Reset horizontal zoom to 100% and centered around 0. */
void AbstractWaterfall::resetHorizontalZoom(void)
void AbstractWaterfall::resetHorizontalZoom()
{
setFftCenterFreq(0);
setSpanFreq(static_cast<qint64>(m_SampleFreq));
Expand All @@ -1655,15 +1655,15 @@ void AbstractWaterfall::resetHorizontalZoom(void)
}

/** Center FFT plot around 0 (corresponds to center freq). */
void AbstractWaterfall::moveToCenterFreq(void)
void AbstractWaterfall::moveToCenterFreq()
{
setFftCenterFreq(0);
updateOverlay();
m_PeakHoldValid = false;
}

/** Center FFT plot around the demodulator frequency. */
void AbstractWaterfall::moveToDemodFreq(void)
void AbstractWaterfall::moveToDemodFreq()
{
setFftCenterFreq(m_DemodCenterFreq-m_CenterFreq);
updateOverlay();
Expand Down
28 changes: 14 additions & 14 deletions AbstractWaterfall.h
Original file line number Diff line number Diff line change
Expand Up @@ -124,15 +124,15 @@ class AbstractWaterfall : public QOpenGLWidget

virtual void setMaxBlending(bool val)
{
(void)val; // suppress unused variable warning
(void) val; // suppress unused variable warning
}

void setCenterFreq(qint64 f);
void setFreqUnits(qint32 unit) { m_FreqUnits = unit; }

void setDemodCenterFreq(qint64 f) { m_DemodCenterFreq = f; }

bool slow(void) const
bool slow() const
{
if (m_fftDataSize == 0)
return true;
Expand All @@ -149,7 +149,7 @@ class AbstractWaterfall : public QOpenGLWidget
m_DemodCenterFreq = m_CenterFreq + freq_hz;
drawOverlay();
}
qint64 getFilterOffset(void)
qint64 getFilterOffset()
{
return m_DemodCenterFreq - m_CenterFreq;
}
Expand Down Expand Up @@ -191,7 +191,7 @@ class AbstractWaterfall : public QOpenGLWidget
qint64 FHiCmax,
bool symetric);

qint64 getCenterFreq(void) const
qint64 getCenterFreq() const
{
return m_CenterFreq;
}
Expand All @@ -211,7 +211,7 @@ class AbstractWaterfall : public QOpenGLWidget
m_unitName = name;
}

QString getUnitName(void) const
QString getUnitName() const
{
return m_unitName;
}
Expand All @@ -226,17 +226,17 @@ class AbstractWaterfall : public QOpenGLWidget
drawOverlay();
}

quint64 getSpanFreq(void) const
quint64 getSpanFreq() const
{
return static_cast<quint64>(this->m_Span);
}

float getZoomLevel(void) const
float getZoomLevel() const
{
return (float)m_SampleFreq / m_Span;
}

qint64 getFftCenterFreq(void) const
qint64 getFftCenterFreq() const
{
return this->m_FftCenter;
}
Expand All @@ -256,7 +256,7 @@ class AbstractWaterfall : public QOpenGLWidget
}
}

double getSampleRate(void)
double getSampleRate()
{
return m_SampleFreq;
}
Expand All @@ -272,7 +272,7 @@ class AbstractWaterfall : public QOpenGLWidget

int getNearestPeak(QPoint pt);
void setWaterfallSpan(quint64 span_ms);
double getWfTimeRes(void);
double getWfTimeRes();
void setFftRate(int rate_hz);
void setFrequencyLimits(qint64 min, qint64 max);
void setFrequencyLimitsEnabled(bool);
Expand Down Expand Up @@ -308,9 +308,9 @@ class AbstractWaterfall : public QOpenGLWidget

public slots:
// zoom functions
void resetHorizontalZoom(void);
void moveToCenterFreq(void);
void moveToDemodFreq(void);
void resetHorizontalZoom();
void moveToCenterFreq();
void moveToDemodFreq();
void zoomOnXAxis(float level);

// other FFT slots
Expand Down Expand Up @@ -430,7 +430,7 @@ class AbstractWaterfall : public QOpenGLWidget
qint64 m_partialFreqStart;
qint64 m_partialFreqEnd;

#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
#if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
Qt::MouseButton m_freqDragBtn = Qt::MiddleButton;
#else
Qt::MouseButton m_freqDragBtn = Qt::MidButton;
Expand Down

0 comments on commit 0234f8f

Please sign in to comment.