mirror of
https://github.com/d47081/qBittorrent.git
synced 2025-01-23 13:04:23 +00:00
Open files with ".!qB" appended to the filename
Filenames do not include ".!qB" in the file list, so the generated path could be wrong.
This commit is contained in:
parent
301294fbff
commit
e41de25919
@ -463,11 +463,14 @@ void PropertiesWidget::openFolder(const QModelIndex &index, bool containing_fold
|
|||||||
|
|
||||||
const QDir saveDir(h.save_path());
|
const QDir saveDir(h.save_path());
|
||||||
const QString filename = path_items.join("/");
|
const QString filename = path_items.join("/");
|
||||||
const QString file_path = fsutils::expandPath(saveDir.absoluteFilePath(filename));
|
|
||||||
qDebug("Trying to open folder at %s", qPrintable(file_path));
|
|
||||||
// Flush data
|
// Flush data
|
||||||
h.flush_cache();
|
h.flush_cache();
|
||||||
|
|
||||||
|
QString file_path = fsutils::expandPath(saveDir.absoluteFilePath(filename));
|
||||||
|
if (QFile::exists(file_path + ".!qB"))
|
||||||
|
file_path += ".!qB";
|
||||||
|
qDebug("Trying to open folder at %s", qPrintable(file_path));
|
||||||
|
|
||||||
#ifdef Q_OS_WIN
|
#ifdef Q_OS_WIN
|
||||||
if (containing_folder) {
|
if (containing_folder) {
|
||||||
// Syntax is: explorer /select, "C:\Folder1\Folder2\file_to_select"
|
// Syntax is: explorer /select, "C:\Folder1\Folder2\file_to_select"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user