DCPlugin/src/ATBAPP/Utils.cpp

19 lines
310 B
C++
Raw Permalink Normal View History

#include "Utils.h"
Utils::Utils(QObject *parent) : QObject(parent)
{
}
int Utils::compare(const void* a, const void* b)
{
2023-07-19 15:30:30 +02:00
uint16_t int_a = * ( (uint16_t*) a );
uint16_t int_b = * ( (uint16_t*) b );
if ( int_a == int_b ) return 0;
else if ( int_a < int_b ) return -1;
else return 1;
}