1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-03-10 06:02:57 +00:00

for the "torrent file" in the inspector, don't give information about the internal torrent file

This commit is contained in:
Mitchell Livingston 2008-10-30 01:37:46 +00:00
parent 6a954ef95c
commit 74f9ce520b
4 changed files with 9 additions and 9 deletions

View file

@ -441,12 +441,12 @@ typedef enum
{
NSString * location = [torrent publicTorrentLocation];
[fTorrentLocationField setStringValue: [location stringByAbbreviatingWithTildeInPath]];
[fTorrentLocationField setToolTip: [location stringByAppendingFormat: @"\n\n%@", [torrent torrentLocation]]];
[fTorrentLocationField setToolTip: location];
}
else
{
[fTorrentLocationField setStringValue: NSLocalizedString(@"Transmission Support Folder", "Inspector -> torrent location")];
[fTorrentLocationField setToolTip: [torrent torrentLocation]];
[fTorrentLocationField setStringValue: @""];
[fTorrentLocationField setToolTip: nil];
}
[fDateAddedField setObjectValue: [torrent dateAdded]];

View file

@ -33,7 +33,7 @@
NSColor * fGreenAvailabilityColor, * fBluePieceColor;
Torrent * fTorrent;
int fNumPieces, fAcross, fWidth, fExtraBorder;
NSInteger fNumPieces, fAcross, fWidth, fExtraBorder;
}
- (void) setTorrent: (Torrent *) torrent;

View file

@ -82,7 +82,7 @@
fNumPieces = MIN([fTorrent pieceCount], MAX_ACROSS * MAX_ACROSS);
fAcross = ceil(sqrt(fNumPieces));
float width = [self bounds].size.width;
CGFloat width = [self bounds].size.width;
fWidth = (width - (fAcross + 1) * BETWEEN) / fAcross;
fExtraBorder = (width - ((fWidth + BETWEEN) * fAcross + BETWEEN)) / 2;
}
@ -115,7 +115,7 @@
}
int8_t * pieces = NULL;
float * piecesPercent = NULL;
CGFloat * piecesPercent = NULL;
BOOL showAvailablity = [[NSUserDefaults standardUserDefaults] boolForKey: @"PiecesViewShowAvailability"];
if (showAvailablity)
@ -125,13 +125,13 @@
}
else
{
piecesPercent = (float *)tr_malloc(fNumPieces * sizeof(float));
piecesPercent = (CGFloat *)tr_malloc(fNumPieces * sizeof(CGFloat));
[fTorrent getAmountFinished: piecesPercent size: fNumPieces];
}
NSImage * image = [self image];
int index = -1;
NSInteger index = -1;
NSRect rect = NSMakeRect(0, 0, fWidth, fWidth);
BOOL change = NO;
@ -182,7 +182,7 @@
else
{
//always redraw "mixed"
float percent = showAvailablity ? (float)pieces[index]/HIGH_PEERS : piecesPercent[index];
CGFloat percent = showAvailablity ? (CGFloat)pieces[index]/HIGH_PEERS : piecesPercent[index];
NSColor * fullColor = showAvailablity ? fGreenAvailabilityColor : fBluePieceColor;
pieceColor = [[NSColor whiteColor] blendedColorWithFraction: percent ofColor: fullColor];
fPieces[index] = PIECE_SOME;

Binary file not shown.