another switch
This commit is contained in:
parent
b85c64d635
commit
197e94910f
|
@ -52,16 +52,23 @@
|
||||||
|
|
||||||
//only for when clicking manually
|
//only for when clicking manually
|
||||||
int priority;
|
int priority;
|
||||||
if (segment == 0)
|
switch (segment)
|
||||||
priority = TR_PRI_LOW;
|
{
|
||||||
else if (segment == 2)
|
case 0:
|
||||||
priority = TR_PRI_HIGH;
|
priority = TR_PRI_LOW;
|
||||||
else
|
break;
|
||||||
priority = TR_PRI_NORMAL;
|
case 1:
|
||||||
|
priority = TR_PRI_NORMAL;
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
|
priority = TR_PRI_HIGH;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
Torrent * torrent = [(FileOutlineView *)[self controlView] torrent];
|
FileOutlineView * controlView = (FileOutlineView *)[self controlView];
|
||||||
|
Torrent * torrent = [controlView torrent];
|
||||||
[torrent setFilePriority: priority forIndexes: [[self representedObject] objectForKey: @"Indexes"]];
|
[torrent setFilePriority: priority forIndexes: [[self representedObject] objectForKey: @"Indexes"]];
|
||||||
[(FileOutlineView *)[self controlView] reloadData];
|
[controlView reloadData];
|
||||||
}
|
}
|
||||||
|
|
||||||
- (void) drawWithFrame: (NSRect) cellFrame inView: (NSView *) controlView
|
- (void) drawWithFrame: (NSRect) cellFrame inView: (NSView *) controlView
|
||||||
|
|
Loading…
Reference in New Issue