Split Session class into interface/implementation parts

PR #17579.
This commit is contained in:
Vladimir Golovnev
2022-08-27 08:01:24 +03:00
committed by GitHub
parent e5491645e4
commit 525692759d
14 changed files with 1421 additions and 1079 deletions

View File

@@ -67,7 +67,7 @@
#include "lttypecast.h"
#include "peeraddress.h"
#include "peerinfo.h"
#include "session.h"
#include "sessionimpl.h"
using namespace BitTorrent;
@@ -227,7 +227,7 @@ namespace
// TorrentImpl
TorrentImpl::TorrentImpl(Session *session, lt::session *nativeSession
TorrentImpl::TorrentImpl(SessionImpl *session, lt::session *nativeSession
, const lt::torrent_handle &nativeHandle, const LoadTorrentParams &params)
: QObject(session)
, m_session(session)
@@ -738,7 +738,7 @@ bool TorrentImpl::hasTag(const QString &tag) const
bool TorrentImpl::addTag(const QString &tag)
{
if (!Session::isValidTag(tag))
if (!m_session->isValidTag(tag))
return false;
if (hasTag(tag))
return false;