Remove redundant suffix from TorrentHandle class

Originally, it was just a wrapper for libtorrent::torrent_handle class, so it mimicked its name.
It was then transformed into a more complex aggregate, but the name was retained (just by inertia).
Unlike libtorrent::torrent_handle class in whose name "handle" means the pattern used,
it does not matter for qBittorrent classes and just eats up space in the source code.
This commit is contained in:
Vladimir Golovnev (Glassez) 2021-01-06 15:12:40 +03:00
parent 35731b96dc
commit 0b4fef19f6
No known key found for this signature in database
GPG key ID: 52A2C7DEE2DFA6F7
52 changed files with 647 additions and 647 deletions

View file

@ -63,7 +63,7 @@
#include "base/bittorrent/infohash.h"
#include "base/bittorrent/session.h"
#include "base/bittorrent/torrenthandle.h"
#include "base/bittorrent/torrent.h"
#include "base/exceptions.h"
#include "base/iconprovider.h"
#include "base/logger.h"
@ -311,7 +311,7 @@ void Application::processMessage(const QString &message)
m_paramsQueue.append(params);
}
void Application::runExternalProgram(const BitTorrent::TorrentHandle *torrent) const
void Application::runExternalProgram(const BitTorrent::Torrent *torrent) const
{
QString program = Preferences::instance()->getAutoRunProgram().trimmed();
program.replace("%N", torrent->name());
@ -405,7 +405,7 @@ void Application::runExternalProgram(const BitTorrent::TorrentHandle *torrent) c
#endif
}
void Application::sendNotificationEmail(const BitTorrent::TorrentHandle *torrent)
void Application::sendNotificationEmail(const BitTorrent::Torrent *torrent)
{
// Prepare mail content
const QString content = tr("Torrent name: %1").arg(torrent->name()) + '\n'
@ -424,7 +424,7 @@ void Application::sendNotificationEmail(const BitTorrent::TorrentHandle *torrent
content);
}
void Application::torrentFinished(BitTorrent::TorrentHandle *const torrent)
void Application::torrentFinished(BitTorrent::Torrent *const torrent)
{
Preferences *const pref = Preferences::instance();