mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-07-15 01:33:07 -07:00
- Files / Folders can also be renamed directly from torrent addition dialog
This commit is contained in:
parent
533e402bca
commit
add2475700
5 changed files with 248 additions and 97 deletions
|
@ -960,6 +960,14 @@ QTorrentHandle Bittorrent::addTorrent(QString path, bool fromScanDir, QString fr
|
|||
qDebug("addTorrent: Setting download as sequential (from tmp data)");
|
||||
h.prioritize_files(TorrentTempData::getFilesPriority(hash));
|
||||
h.set_sequential_download(TorrentTempData::isSequential(hash));
|
||||
// Import Files names from torrent addition dialog
|
||||
QStringList files_path = TorrentTempData::getFilesPath(hash);
|
||||
if(files_path.size() == h.num_files()) {
|
||||
for(int i=0; i<h.num_files(); ++i) {
|
||||
QString path = files_path.at(i);
|
||||
h.rename_file(i, path);
|
||||
}
|
||||
}
|
||||
}
|
||||
QString label = TorrentTempData::getLabel(hash);
|
||||
// Save persistent data for new torrent
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue