1
0
Fork 0
mirror of https://github.com/transmission/transmission synced 2025-02-20 13:16:53 +00:00

enable and check group menu items appropriately; update news

This commit is contained in:
Mitchell Livingston 2007-12-17 16:32:32 +00:00
parent d9246b1ad4
commit 93df72df07
2 changed files with 19 additions and 0 deletions

1
NEWS
View file

@ -8,6 +8,7 @@ NEWS file for Transmission <http://transmission.m0k.org/>
+ Updated icon
- OS X:
+ Redesigned Leopard-like look
+ Group labels
+ Statistics window
+ Pieces Bar (return of Advanced Bar)
+ Availability Bar (overlay on regular bar)

View file

@ -3076,6 +3076,24 @@ void sleepCallBack(void * controller, io_service_t y, natural_t messageType, voi
return YES;
}
if (action == @selector(setGroup:))
{
BOOL checked = NO;
int index = [[menuItem representedObject] intValue];
NSEnumerator * enumerator = [[fDisplayedTorrents objectsAtIndexes: [fTableView selectedRowIndexes]] objectEnumerator];
Torrent * torrent;
while ((torrent = [enumerator nextObject]))
if (index == [torrent groupValue])
{
checked = YES;
break;
}
[menuItem setState: checked ? NSOnState : NSOffState];
return canUseTable && [fTableView numberOfSelectedRows] > 0;
}
if (action == @selector(toggleSmallView:))
{
[menuItem setState: [fDefaults boolForKey: @"SmallView"] ? NSOnState : NSOffState];