mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-01 05:08:05 -06:00
Move Utils::Misc::isUrl() function
All usage of this function gets to call Net::DownloadManager eventually.
This commit is contained in:
@@ -50,7 +50,6 @@
|
||||
#include "base/utils/bytearray.h"
|
||||
#include "base/utils/foreignapps.h"
|
||||
#include "base/utils/fs.h"
|
||||
#include "base/utils/misc.h"
|
||||
#include "searchdownloadhandler.h"
|
||||
#include "searchhandler.h"
|
||||
|
||||
@@ -198,7 +197,7 @@ void SearchPluginManager::installPlugin(const QString &source)
|
||||
{
|
||||
clearPythonCache(engineLocation());
|
||||
|
||||
if (Utils::Misc::isUrl(source)) {
|
||||
if (Net::DownloadManager::hasSupportedScheme(source)) {
|
||||
using namespace Net;
|
||||
DownloadHandler *handler = DownloadManager::instance()->download(DownloadRequest(source).saveToFile(true));
|
||||
connect(handler, static_cast<void (DownloadHandler::*)(const QString &, const QString &)>(&DownloadHandler::downloadFinished)
|
||||
|
||||
Reference in New Issue
Block a user