mirror of
https://github.com/transmission/transmission.git
synced 2026-05-08 09:39:08 +01:00
#3017 fix the pieces bar for magnet links
This commit is contained in:
@@ -571,6 +571,14 @@
|
||||
{
|
||||
Torrent * torrent = [self representedObject];
|
||||
|
||||
//fill an all-white bar for magnet links
|
||||
if ([torrent isMagnet])
|
||||
{
|
||||
[[NSColor whiteColor] set];
|
||||
NSRectFill(barRect);
|
||||
return;
|
||||
}
|
||||
|
||||
NSInteger pieceCount = MIN([torrent pieceCount], MAX_PIECES);
|
||||
float * piecesPercent = malloc(pieceCount * sizeof(float));
|
||||
[torrent getAmountFinished: piecesPercent size: pieceCount];
|
||||
|
||||
Reference in New Issue
Block a user