mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-05 23:22:31 -06:00
Replace min, max, clamp functions with std counterparts
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
|
||||
#include "downloadedpiecesbar.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <cmath>
|
||||
|
||||
#include <QDebug>
|
||||
@@ -117,7 +118,7 @@ QVector<float> DownloadedPiecesBar::bitfieldToFloatVector(const QBitArray &vecin
|
||||
value /= ratio;
|
||||
|
||||
// float precision sometimes gives > 1, because it's not possible to store irrational numbers
|
||||
value = qMin(value, 1.0f);
|
||||
value = std::min(value, 1.0f);
|
||||
|
||||
result[x] = value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user