mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-01-01 13:18:06 -06:00
Provide v1 and v2 infohashes in UI (#15097)
This commit is contained in:
committed by
GitHub
parent
f6eb29d800
commit
37f227ae74
@@ -96,8 +96,9 @@ QVariantMap serialize(const BitTorrent::Torrent &torrent)
|
||||
};
|
||||
|
||||
return {
|
||||
// TODO: Add fields for real SHA1 and SHA256 hashes
|
||||
{KEY_TORRENT_ID, QString(torrent.id().toString())},
|
||||
{KEY_TORRENT_ID, torrent.id().toString()},
|
||||
{KEY_TORRENT_INFOHASHV1, torrent.infoHash().v1().toString()},
|
||||
{KEY_TORRENT_INFOHASHV2, torrent.infoHash().v2().toString()},
|
||||
{KEY_TORRENT_NAME, torrent.name()},
|
||||
{KEY_TORRENT_MAGNET_URI, torrent.createMagnetURI()},
|
||||
{KEY_TORRENT_SIZE, torrent.wantedSize()},
|
||||
|
||||
@@ -36,7 +36,10 @@ namespace BitTorrent
|
||||
}
|
||||
|
||||
// Torrent keys
|
||||
// TODO: Rename it to `id`.
|
||||
inline const char KEY_TORRENT_ID[] = "hash";
|
||||
inline const char KEY_TORRENT_INFOHASHV1[] = "infohash_v1";
|
||||
inline const char KEY_TORRENT_INFOHASHV2[] = "infohash_v2";
|
||||
inline const char KEY_TORRENT_NAME[] = "name";
|
||||
inline const char KEY_TORRENT_MAGNET_URI[] = "magnet_uri";
|
||||
inline const char KEY_TORRENT_SIZE[] = "size";
|
||||
|
||||
Reference in New Issue
Block a user