mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2025-12-31 20:58:07 -06:00
Make use of chrono literals from std library
This commit is contained in:
@@ -29,6 +29,8 @@
|
||||
|
||||
#include "searchhandler.h"
|
||||
|
||||
#include <chrono>
|
||||
|
||||
#include <QMetaObject>
|
||||
#include <QProcess>
|
||||
#include <QTimer>
|
||||
@@ -40,6 +42,8 @@
|
||||
#include "base/utils/fs.h"
|
||||
#include "searchpluginmanager.h"
|
||||
|
||||
using namespace std::chrono_literals;
|
||||
|
||||
namespace
|
||||
{
|
||||
enum SearchResultColumn
|
||||
@@ -85,7 +89,7 @@ SearchHandler::SearchHandler(const QString &pattern, const QString &category, co
|
||||
|
||||
m_searchTimeout->setSingleShot(true);
|
||||
connect(m_searchTimeout, &QTimer::timeout, this, &SearchHandler::cancelSearch);
|
||||
m_searchTimeout->start(180000); // 3 min
|
||||
m_searchTimeout->start(3min);
|
||||
|
||||
// deferred start allows clients to handle starting-related signals
|
||||
QMetaObject::invokeMethod(this, [this]() { m_searchProcess->start(QIODevice::ReadOnly); }
|
||||
|
||||
Reference in New Issue
Block a user