mirror of
https://github.com/transmission/transmission
synced 2025-02-22 06:00:41 +00:00
enable and check group menu items appropriately; update news
This commit is contained in:
parent
d9246b1ad4
commit
93df72df07
2 changed files with 19 additions and 0 deletions
1
NEWS
1
NEWS
|
@ -8,6 +8,7 @@ NEWS file for Transmission <http://transmission.m0k.org/>
|
||||||
+ Updated icon
|
+ Updated icon
|
||||||
- OS X:
|
- OS X:
|
||||||
+ Redesigned Leopard-like look
|
+ Redesigned Leopard-like look
|
||||||
|
+ Group labels
|
||||||
+ Statistics window
|
+ Statistics window
|
||||||
+ Pieces Bar (return of Advanced Bar)
|
+ Pieces Bar (return of Advanced Bar)
|
||||||
+ Availability Bar (overlay on regular bar)
|
+ Availability Bar (overlay on regular bar)
|
||||||
|
|
|
@ -3076,6 +3076,24 @@ void sleepCallBack(void * controller, io_service_t y, natural_t messageType, voi
|
||||||
return YES;
|
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:))
|
if (action == @selector(toggleSmallView:))
|
||||||
{
|
{
|
||||||
[menuItem setState: [fDefaults boolForKey: @"SmallView"] ? NSOnState : NSOffState];
|
[menuItem setState: [fDefaults boolForKey: @"SmallView"] ? NSOnState : NSOffState];
|
||||||
|
|
Loading…
Reference in a new issue