diff --git a/macosx/PiecesView.mm b/macosx/PiecesView.mm index 4294d872c57..69c4c1f4335 100644 --- a/macosx/PiecesView.mm +++ b/macosx/PiecesView.mm @@ -129,7 +129,7 @@ - (void)setTorrent:(Torrent*)torrent self.image = [[NSImage alloc] initWithSize:self.bounds.size]; [self clearView]; - self.needsDisplay = YES; + [self setNeedsDisplay]; } - (void)clearView @@ -196,7 +196,7 @@ - (void)updateView NSRectFillListWithColors(cFillRects, cFillColors, numCells); return YES; }]; - self.needsDisplay = YES; + [self setNeedsDisplay]; } // save the current state so we can compare it later diff --git a/macosx/TorrentTableView.mm b/macosx/TorrentTableView.mm index b886047722d..28f9a0ce6f5 100644 --- a/macosx/TorrentTableView.mm +++ b/macosx/TorrentTableView.mm @@ -126,13 +126,7 @@ - (void)awakeFromNib //disable highlight color and set manually in drawRow [self setSelectionHighlightStyle:NSTableViewSelectionHighlightStyleNone]; - [NSNotificationCenter.defaultCenter addObserver:self selector:@selector(refreshTorrentTable) name:@"RefreshTorrentTable" - object:nil]; -} - -- (void)refreshTorrentTable -{ - self.needsDisplay = YES; + [NSNotificationCenter.defaultCenter addObserver:self selector:@selector(setNeedsDisplay) name:@"RefreshTorrentTable" object:nil]; } - (BOOL)isGroupCollapsed:(NSInteger)value