1
0
mirror of https://github.com/d47081/qBittorrent.git synced 2025-01-10 23:07:59 +00:00

Fix size display for torrents without metadata

This commit is contained in:
Christophe Dumez 2010-11-14 18:56:06 +00:00
parent e57f8b6204
commit 2de4c50d4f

View File

@ -116,7 +116,7 @@ QVariant TorrentModelItem::data(int column, int role) const
case TR_PRIORITY:
return m_torrent.queue_position();
case TR_SIZE:
return static_cast<qlonglong>(m_torrent.actual_size());
return m_torrent.has_metadata() ? static_cast<qlonglong>(m_torrent.actual_size()) : -1;
case TR_PROGRESS:
return m_torrent.progress();
case TR_STATUS: