show the priority images in the menu popup for files

This commit is contained in:
Mitchell Livingston 2007-09-11 19:23:14 +00:00
parent c351a19124
commit 3836abcfb8
4 changed files with 12 additions and 19 deletions

3
NEWS
View File

@ -2,12 +2,13 @@ NEWS file for Transmission <http://transmission.m0k.org/>
0.90 (2007/xx/yy)
- Improved compliance with BitTorrent spec
- Multiscrape support added
- Multiscrape support
- Only report downloaded, verified good pieces in tracker `download' field
- OS X:
+ Per-torrent action menu
+ Redesigned message log
+ Inspector can be resized vertically in Peers and Files tabs
+ Various smaller interface improvements
0.82 (2007/09/09)
- Fixed bug that could limit transfer speeds

View File

@ -101,6 +101,11 @@
//set file table
[fFileOutline setDoubleAction: @selector(revealFile:)];
//set priority item images
[fFilePriorityNormal setImage: [NSImage imageNamed: @"PriorityNormal.png"]];
[fFilePriorityLow setImage: [NSImage imageNamed: @"PriorityLow.png"]];
[fFilePriorityHigh setImage: [NSImage imageNamed: @"PriorityHigh.png"]];
//set blank inspector
[self updateInfoForTorrents: [NSArray array]];

View File

@ -30,7 +30,7 @@
#define LEVEL_DEBUG 2
#define UPDATE_SECONDS 0.6
#define MAX_MESSAGES 2500
#define MAX_MESSAGES 4000
@interface MessageWindowController (Private)
@ -70,8 +70,6 @@
[window setFrameAutosaveName: @"MessageWindowFrame"];
[window setFrameUsingName: @"MessageWindowFrame"];
[window center];
//initially sort peer table by IP
if ([[fMessageTable sortDescriptors] count] == 0)
{
@ -95,14 +93,8 @@
[fLevelButton selectItemAtIndex: LEVEL_ERROR];
else if (level == TR_MSG_INF)
[fLevelButton selectItemAtIndex: LEVEL_INFO];
else if (level == TR_MSG_DBG)
[fLevelButton selectItemAtIndex: LEVEL_DEBUG];
else
{
level = TR_MSG_ERR;
[fLevelButton selectItemAtIndex: LEVEL_ERROR];
[[NSUserDefaults standardUserDefaults] setInteger: level forKey: @"MessageLevel"];
}
[fLevelButton selectItemAtIndex: LEVEL_DEBUG];
[self setDebugWarningHidden: level != TR_MSG_DBG];
}
@ -121,7 +113,6 @@
tr_freeMessageList(messages);
#warning still needed?
int total = [fMessages count];
if (total > MAX_MESSAGES)
{
@ -158,10 +149,8 @@
return fErrorImage;
else if (level == TR_MSG_INF)
return fInfoImage;
else if (level == TR_MSG_DBG)
return fDebugImage;
else
return nil;
return fDebugImage;
}
else
return [message objectForKey: @"Message"];
@ -289,12 +278,10 @@
levelString = @"Error";
else if (level == TR_MSG_INF)
levelString = @"Info";
else if (level == TR_MSG_DBG)
levelString = @"Debug";
else
levelString = @"???";
levelString = @"Debug";
return [NSString stringWithFormat: @"%@ %@ %@", [message objectForKey: @"Date"], levelString, [message objectForKey: @"Message"]];
return [NSString stringWithFormat: @"%@ [%@] %@", [message objectForKey: @"Date"], levelString, [message objectForKey: @"Message"]];
}
- (void) setDebugWarningHidden: (BOOL) hide