mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-11 15:56:17 -07:00
parent
d8a03cd8d8
commit
e045b4678d
3 changed files with 7 additions and 10 deletions
|
@ -29,6 +29,7 @@
|
|||
|
||||
#include "preferences.h"
|
||||
|
||||
#include <algorithm>
|
||||
#include <chrono>
|
||||
|
||||
#ifdef Q_OS_MACOS
|
||||
|
@ -2122,7 +2123,7 @@ int Preferences::addNewTorrentDialogSavePathHistoryLength() const
|
|||
|
||||
void Preferences::setAddNewTorrentDialogSavePathHistoryLength(const int value)
|
||||
{
|
||||
const int clampedValue = qBound(0, value, 99);
|
||||
const int clampedValue = std::clamp(value, 0, 99);
|
||||
const int oldValue = addNewTorrentDialogSavePathHistoryLength();
|
||||
if (clampedValue == oldValue)
|
||||
return;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue