mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2024-11-27 03:39:39 +03:00
Correctly display the hash of torrents without metadata
This commit is contained in:
parent
a2ffecd6bd
commit
7d6df2a3c2
1 changed files with 12 additions and 10 deletions
|
@ -236,19 +236,21 @@ void PropertiesWidget::loadTorrentInfos(QTorrentHandle &_h) {
|
||||||
// Save path
|
// Save path
|
||||||
updateSavePath(h);
|
updateSavePath(h);
|
||||||
changeSavePathButton->setEnabled(h.has_metadata());
|
changeSavePathButton->setEnabled(h.has_metadata());
|
||||||
// Creation date
|
|
||||||
lbl_creationDate->setText(h.creation_date());
|
|
||||||
// Hash
|
// Hash
|
||||||
hash_lbl->setText(h.hash());
|
hash_lbl->setText(h.hash());
|
||||||
// Comment
|
|
||||||
comment_text->setHtml(h.comment());
|
|
||||||
// URL seeds
|
|
||||||
loadUrlSeeds();
|
|
||||||
// List files in torrent
|
|
||||||
PropListModel->clear();
|
PropListModel->clear();
|
||||||
PropListModel->setupModelData(h.get_torrent_info());
|
if(h.has_metadata()) {
|
||||||
// Expand first item if possible
|
// Creation date
|
||||||
filesList->expand(PropListModel->index(0, 0));
|
lbl_creationDate->setText(h.creation_date());
|
||||||
|
// Comment
|
||||||
|
comment_text->setHtml(h.comment());
|
||||||
|
// URL seeds
|
||||||
|
loadUrlSeeds();
|
||||||
|
// List files in torrent
|
||||||
|
PropListModel->setupModelData(h.get_torrent_info());
|
||||||
|
// Expand first item if possible
|
||||||
|
filesList->expand(PropListModel->index(0, 0));
|
||||||
|
}
|
||||||
} catch(invalid_handle e) {
|
} catch(invalid_handle e) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue