don't hardcode min and max sizes for the inspector

This commit is contained in:
Mitchell Livingston 2007-07-31 00:10:55 +00:00
parent e406ece219
commit cab06a5b29
4 changed files with 10 additions and 15 deletions

View File

@ -70,8 +70,6 @@
#define DOCK_SEEDING_TAG 101
#define DOCK_DOWNLOADING_TAG 102
#define ANNOUNCE_WAIT_INTERVAL_SECONDS -60.0
#define WEBSITE_URL @"http://transmission.m0k.org/"
#define FORUM_URL @"http://transmission.m0k.org/forum/"
@ -1324,8 +1322,8 @@ static void sleepCallBack(void * controller, io_service_t y, natural_t messageTy
NSDate * date;
while ((torrent = [enumerator nextObject]))
{
if ([torrent canAnnounce])
[torrent announce];
if ([torrent canManualAnnounce])
[torrent manualAnnounce];
}
}
@ -2883,7 +2881,7 @@ static void sleepCallBack(void * controller, io_service_t y, natural_t messageTy
return NO;
}
//enable announce item
//enable manual announce item
if (action == @selector(announceSelectedTorrents:))
{
if (!canUseTable)
@ -2895,7 +2893,7 @@ static void sleepCallBack(void * controller, io_service_t y, natural_t messageTy
while ((torrent = [enumerator nextObject]))
{
//time interval returned will be negative
if ([torrent canAnnounce])
if ([torrent canManualAnnounce])
return YES;
}
return NO;

View File

@ -27,9 +27,6 @@
#import "FilePriorityCell.h"
#import "StringAdditions.h"
#define MIN_WINDOW_WIDTH 300
#define MAX_WINDOW_WIDTH 5000
#define FILE_ROW_SMALL_HEIGHT 18.0
#define TAB_INFO_IDENT @"Info"
@ -734,8 +731,8 @@
else
[window setFrame: frame display: YES];
[window setMinSize: NSMakeSize(MIN_WINDOW_WIDTH, frame.size.height)];
[window setMaxSize: NSMakeSize(MAX_WINDOW_WIDTH, frame.size.height)];
[window setMinSize: NSMakeSize([window minSize].width, frame.size.height)];
[window setMaxSize: NSMakeSize([window maxSize].width, frame.size.height)];
}
- (void) setNextTab

View File

@ -90,8 +90,8 @@
- (void) sleep;
- (void) wakeUp;
- (void) announce;
- (BOOL) canAnnounce;
- (void) manualAnnounce;
- (BOOL) canManualAnnounce;
- (void) resetCache;

View File

@ -555,12 +555,12 @@ static uint32_t kRed = BE(0xFF6450FF), //255, 100, 80
tr_torrentStart(fHandle);
}
- (void) announce
- (void) manualAnnounce
{
tr_manualUpdate(fHandle);
}
- (BOOL) canAnnounce
- (BOOL) canManualAnnounce
{
return tr_torrentCanManualUpdate(fHandle);
}