mirror of
https://github.com/qbittorrent/qBittorrent
synced 2025-08-21 13:53:37 -07:00
Fix torrent renaming. Closes #3398
This commit is contained in:
parent
20f4b95180
commit
7c164dfcb9
1 changed files with 1 additions and 1 deletions
|
@ -684,7 +684,7 @@ void TransferListWidget::renameSelectedTorrent()
|
||||||
const QModelIndexList selectedIndexes = selectionModel()->selectedRows();
|
const QModelIndexList selectedIndexes = selectionModel()->selectedRows();
|
||||||
if (selectedIndexes.size() != 1) return;
|
if (selectedIndexes.size() != 1) return;
|
||||||
if (!selectedIndexes.first().isValid()) return;
|
if (!selectedIndexes.first().isValid()) return;
|
||||||
QModelIndex mi = mapToSource(selectedIndexes.first());
|
QModelIndex mi = listModel->index(mapToSource(selectedIndexes.first()).row(), TorrentModelItem::TR_NAME);
|
||||||
const QString hash = getHashFromRow(mi.row());
|
const QString hash = getHashFromRow(mi.row());
|
||||||
const QTorrentHandle h = BTSession->getTorrentHandle(hash);
|
const QTorrentHandle h = BTSession->getTorrentHandle(hash);
|
||||||
if (!h.is_valid()) return;
|
if (!h.is_valid()) return;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue