Fixes typos.

This commit is contained in:
zonble 2021-11-11 00:14:49 +08:00
parent 36a5eee37f
commit 723a8402ab
4 changed files with 15 additions and 11 deletions

View File

@ -69,8 +69,8 @@
// current input mode // current input mode
NSString *_inputMode; NSString *_inputMode;
// if Chinese convertion is enabled // if Chinese conversion is enabled
BOOL _chineseConvertionEnabled; BOOL _chineseConversionEnabled;
} }
@end @end

View File

@ -78,7 +78,7 @@ static NSString *const kUseHorizontalCandidateListPreferenceKey = @"UseHorizonta
static NSString *const kComposingBufferSizePreferenceKey = @"ComposingBufferSize"; static NSString *const kComposingBufferSizePreferenceKey = @"ComposingBufferSize";
static NSString *const kDisableUserCandidateSelectionLearning = @"DisableUserCandidateSelectionLearning"; static NSString *const kDisableUserCandidateSelectionLearning = @"DisableUserCandidateSelectionLearning";
static NSString *const kChooseCandidateUsingSpaceKey = @"ChooseCandidateUsingSpaceKey"; static NSString *const kChooseCandidateUsingSpaceKey = @"ChooseCandidateUsingSpaceKey";
static NSString *const kChineseConvertionEnanledKey = @"ChineseConvertionEnanledKey"; static NSString *const kChineseConversionEnabledKey = @"ChineseConversionEnabledKey";
// advanced (usually optional) settings // advanced (usually optional) settings
static NSString *const kCandidateTextFontName = @"CandidateTextFontName"; static NSString *const kCandidateTextFontName = @"CandidateTextFontName";
@ -195,7 +195,7 @@ public:
} }
_inputMode = kBopomofoModeIdentifier; _inputMode = kBopomofoModeIdentifier;
_chineseConvertionEnabled = [[NSUserDefaults standardUserDefaults] boolForKey:kChineseConvertionEnanledKey]; _chineseConversionEnabled = [[NSUserDefaults standardUserDefaults] boolForKey:kChineseConversionEnabledKey];
} }
return self; return self;
@ -232,10 +232,10 @@ public:
} }
#endif //DEBUG #endif //DEBUG
NSMenuItem *chineseConvertionMenuItem = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"Chinese Convertion", @"") action:@selector(toggleChineseConverter:) keyEquivalent:@"G"]; NSMenuItem *chineseConversionMenuItem = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"Chinese Conversion", @"") action:@selector(toggleChineseConverter:) keyEquivalent:@"G"];
chineseConvertionMenuItem.keyEquivalentModifierMask = NSEventModifierFlagCommand | NSEventModifierFlagControl; chineseConversionMenuItem.keyEquivalentModifierMask = NSEventModifierFlagCommand | NSEventModifierFlagControl;
chineseConvertionMenuItem.state = _chineseConvertionEnabled ? NSControlStateValueOn : NSControlStateValueOff; chineseConversionMenuItem.state = _chineseConversionEnabled ? NSControlStateValueOn : NSControlStateValueOff;
[menu addItem:chineseConvertionMenuItem]; [menu addItem:chineseConversionMenuItem];
NSMenuItem *updateCheckItem = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"Check for Updates…", @"") action:@selector(checkForUpdate:) keyEquivalent:@""]; NSMenuItem *updateCheckItem = [[NSMenuItem alloc] initWithTitle:NSLocalizedString(@"Check for Updates…", @"") action:@selector(checkForUpdate:) keyEquivalent:@""];
[menu addItem:updateCheckItem]; [menu addItem:updateCheckItem];
@ -395,7 +395,7 @@ public:
} }
NSString *buffer = _composingBuffer; NSString *buffer = _composingBuffer;
if (_chineseConvertionEnabled) { if (_chineseConversionEnabled) {
buffer = [OpenCCBridge convert:_composingBuffer]; buffer = [OpenCCBridge convert:_composingBuffer];
} }
@ -1441,8 +1441,8 @@ public:
- (void)toggleChineseConverter:(id)sender - (void)toggleChineseConverter:(id)sender
{ {
_chineseConvertionEnabled = !_chineseConvertionEnabled; _chineseConversionEnabled = !_chineseConversionEnabled;
[[NSUserDefaults standardUserDefaults] setBool:_chineseConvertionEnabled forKey:kChineseConvertionEnanledKey]; [[NSUserDefaults standardUserDefaults] setBool:_chineseConversionEnabled forKey:kChineseConversionEnabledKey];
} }
- (void)clearLearningDictionary:(id)sender - (void)clearLearningDictionary:(id)sender

View File

@ -48,3 +48,5 @@
/* No comment provided by engineer. */ /* No comment provided by engineer. */
"You're currently using McBopomofo %@ (%@), a new version %@ (%@) is now available. Do you want to visit McBopomofo's website to download the version?%@" = "You're currently using McBopomofo %@ (%@), a new version %@ (%@) is now available. Do you want to visit McBopomofo's website to download the version?%@"; "You're currently using McBopomofo %@ (%@), a new version %@ (%@) is now available. Do you want to visit McBopomofo's website to download the version?%@" = "You're currently using McBopomofo %@ (%@), a new version %@ (%@) is now available. Do you want to visit McBopomofo's website to download the version?%@";
"Chinese Conversion" = "Chinese Conversion";

View File

@ -48,3 +48,5 @@
/* No comment provided by engineer. */ /* No comment provided by engineer. */
"You're currently using McBopomofo %@ (%@), a new version %@ (%@) is now available. Do you want to visit McBopomofo's website to download the version?%@" = "目前使用的小麥注音版本是 %1$@ (%2$@),網路上有更新版本 %3$@ (%4$@) 可供下載。是否要前往小麥注音網站下載新版來安裝?%5$@"; "You're currently using McBopomofo %@ (%@), a new version %@ (%@) is now available. Do you want to visit McBopomofo's website to download the version?%@" = "目前使用的小麥注音版本是 %1$@ (%2$@),網路上有更新版本 %3$@ (%4$@) 可供下載。是否要前往小麥注音網站下載新版來安裝?%5$@";
"Chinese Conversion" = "簡繁轉換";