KeyHandler // Always return NO when ↓Shift & +CapsLock.
This commit is contained in:
parent
57c817486a
commit
721223e14f
|
@ -286,14 +286,10 @@ static NSString *const kGraphVizOutputfile = @"/tmp/vChewing-visualization.dot";
|
|||
InputStateEmpty *emptyState = [[InputStateEmpty alloc] init];
|
||||
stateCallback(emptyState);
|
||||
|
||||
// Non-Dynamic Keyboard Layouts Only: When shift is pressed, don't do further processing, since it outputs capital letter anyway.
|
||||
if ((![Preferences.basisKeyboardLayout isEqual: @"com.apple.keylayout.ZhuyinBopomofo"]
|
||||
&& ![Preferences.basisKeyboardLayout isEqual: @"com.apple.keylayout.ZhuyinEten"])
|
||||
|| [input isCapsLockOn]){
|
||||
// When shift is pressed, don't do further processing, since it outputs capital letter anyway.
|
||||
if ([input isShiftHold]) {
|
||||
return NO;
|
||||
}
|
||||
}
|
||||
|
||||
// if ASCII but not printable, don't use insertText:replacementRange: as many apps don't handle non-ASCII char insertions.
|
||||
if (charCode < 0x80 && !isprint(charCode)) {
|
||||
|
|
Loading…
Reference in New Issue