mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-02 05:38:06 -06:00
Revamp content layout handling
Apply content layout only if desired file names aren't provided. Remove helpers with confusing signatures. Don't remove root folder twice. PR #16724. Closes #16259.
This commit is contained in:
committed by
GitHub
parent
eecd221d40
commit
df2d449f9b
@@ -41,6 +41,7 @@
|
||||
#include <QVector>
|
||||
|
||||
#include "base/global.h"
|
||||
#include "base/path.h"
|
||||
#include "base/utils/fs.h"
|
||||
#include "base/utils/io.h"
|
||||
#include "base/utils/misc.h"
|
||||
@@ -408,14 +409,6 @@ int TorrentInfo::fileIndex(const Path &filePath) const
|
||||
return -1;
|
||||
}
|
||||
|
||||
TorrentContentLayout TorrentInfo::contentLayout() const
|
||||
{
|
||||
if (!isValid())
|
||||
return TorrentContentLayout::Original;
|
||||
|
||||
return detectContentLayout(filePaths());
|
||||
}
|
||||
|
||||
std::shared_ptr<lt::torrent_info> TorrentInfo::nativeInfo() const
|
||||
{
|
||||
if (!isValid())
|
||||
|
||||
Reference in New Issue
Block a user