From 589df7180575a61cc7bfb13008b8a8c4caeeacb8 Mon Sep 17 00:00:00 2001 From: Phil Taylor Date: Sat, 6 Nov 2021 10:42:13 +0000 Subject: [PATCH] Change MAX/MIN to use qMax/qMin instead --- transceiveradjustments.cpp | 4 ++-- transceiveradjustments.h | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/transceiveradjustments.cpp b/transceiveradjustments.cpp index c87c612..309cd43 100644 --- a/transceiveradjustments.cpp +++ b/transceiveradjustments.cpp @@ -46,8 +46,8 @@ void transceiverAdjustments::on_IFShiftSlider_valueChanged(int value) unsigned char inner = ui->TPBFInnerSlider->value(); unsigned char outer = ui->TPBFOuterSlider->value(); int shift = value - previousIFShift; - inner = MAX( 0, MIN(255,int (inner + shift)) ); - outer = MAX( 0, MIN(255,int (outer + shift)) ); + inner = qMax( 0, qMin(255,int (inner + shift)) ); + outer =qMax( 0, qMin(255,int (outer + shift)) ); ui->TPBFInnerSlider->setValue(inner); ui->TPBFOuterSlider->setValue(outer); diff --git a/transceiveradjustments.h b/transceiveradjustments.h index bec6a34..2f5ecd6 100644 --- a/transceiveradjustments.h +++ b/transceiveradjustments.h @@ -1,7 +1,9 @@ #ifndef TRANSCEIVERADJUSTMENTS_H #define TRANSCEIVERADJUSTMENTS_H -#include + + +#include #include #include "rigidentities.h"