fix: some typos in macos source code comments (#5475)

This commit is contained in:
Gary Elshaw 2023-04-30 07:00:35 +12:00 committed by GitHub
parent 908e8a551e
commit 52c45eb85f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 6 deletions

View File

@ -3002,7 +3002,7 @@ void onTorrentCompletenessChanged(tr_torrent* tor, tr_completeness status, bool
{
//for each torrent, removes the previous piece info if it's not in allTorrents, and keeps track of which torrents we already found in allTorrents
void (^removePreviousFinishedPieces)(id, NSUInteger, BOOL*) = ^(Torrent* torrent, NSUInteger /*idx*/, BOOL* /*stop*/) {
//we used to keep track of which torrents we already found in allTorrents, but it wasn't safe fo concurrent enumeration
//we used to keep track of which torrents we already found in allTorrents, but it wasn't safe for concurrent enumeration
if (![allTorrents containsObject:torrent])
{
torrent.previousFinishedPieces = nil;
@ -4598,7 +4598,7 @@ void onTorrentCompletenessChanged(tr_torrent* tor, tr_completeness status, bool
return YES;
}
//only enable some items if it is in a context menu or the window is useable
//only enable some items if it is in a context menu or the window is usable
BOOL canUseTable = self.fWindow.keyWindow || menuItem.menu.supermenu != NSApp.mainMenu;
//enable open items

View File

@ -256,7 +256,7 @@ typedef NS_ENUM(NSInteger, TrackerSegmentTag) {
[self.fTrackerTable reloadData];
[self.fTrackerTable deselectAll:self];
[NSNotificationCenter.defaultCenter postNotificationName:@"UpdateUI" object:nil]; //incase sort by tracker
[NSNotificationCenter.defaultCenter postNotificationName:@"UpdateUI" object:nil]; //in case sort by tracker
}
- (void)addRemoveTracker:(id)sender
@ -463,7 +463,7 @@ typedef NS_ENUM(NSInteger, TrackerSegmentTag) {
[self.fTrackerTable endUpdates];
[NSNotificationCenter.defaultCenter postNotificationName:@"UpdateUI" object:nil]; //incase sort by tracker
[NSNotificationCenter.defaultCenter postNotificationName:@"UpdateUI" object:nil]; //in case sort by tracker
}
@end

View File

@ -828,10 +828,10 @@ bool trashDataFile(char const* filename, void* /*user_data*/, tr_error** error)
}
if (self.fStat->leftUntilDone <= 0)
{
// We return smallest amount of time remaining for simpliest compliance with sorting.
// We return smallest amount of time remaining for simplest compliance with sorting.
return 0;
}
// We return highest amount of time remaining for simpliest compliance with sorting.
// We return highest amount of time remaining for simplest compliance with sorting.
return LONG_MAX;
}