mirror of
https://github.com/transmission/transmission.git
synced 2025-12-24 12:28:52 +00:00
hopefully fix weird drawing issues when resizing, and eliminate a memory leak
This commit is contained in:
@@ -58,6 +58,8 @@
|
||||
{
|
||||
fDefaults = [NSUserDefaults standardUserDefaults];
|
||||
|
||||
fTorrentCell = [[TorrentCell alloc] init];
|
||||
|
||||
fMouseControlRow = -1;
|
||||
fMouseRevealRow = -1;
|
||||
fMouseActionRow = -1;
|
||||
@@ -73,8 +75,10 @@
|
||||
|
||||
- (void) awakeFromNib
|
||||
{
|
||||
[self setGridStyleMask: NSTableViewSolidVerticalGridLineMask]; //weird redrawing issues if set to none
|
||||
|
||||
if (![NSApp isOnLeopardOrBetter])
|
||||
[[self tableColumnWithIdentifier: @"Torrent"] setDataCell: [[[TorrentCell alloc] init] autorelease]];
|
||||
[[self tableColumnWithIdentifier: @"Torrent"] setDataCell: fTorrentCell];
|
||||
}
|
||||
|
||||
- (void) dealloc
|
||||
@@ -86,6 +90,8 @@
|
||||
[fKeyStrokes release];
|
||||
[fMenuTorrent release];
|
||||
|
||||
[fTorrentCell release];
|
||||
|
||||
[super dealloc];
|
||||
}
|
||||
|
||||
@@ -99,9 +105,10 @@
|
||||
fGroupIndexes = indexes;
|
||||
}
|
||||
|
||||
#warning needed?
|
||||
- (id) dataCellForRow: (NSInteger) row
|
||||
{
|
||||
return (row == -1 || ![fGroupIndexes containsIndex: row]) ? [[[TorrentCell alloc] init] autorelease] : nil;
|
||||
return (row == -1 || ![fGroupIndexes containsIndex: row]) ? fTorrentCell : nil;
|
||||
}
|
||||
|
||||
- (BOOL) tableView: (NSTableView *) tableView isGroupRow: (NSInteger) row
|
||||
|
||||
Reference in New Issue
Block a user