ctlIME // +arrClientShiftHandlingExceptionList.

This commit is contained in:
ShikiSuen 2022-08-14 16:53:51 +08:00
parent 831ef6f8dd
commit bc6d840694
1 changed files with 8 additions and 3 deletions

View File

@ -202,9 +202,10 @@ class ctlInputMethod: IMKInputController {
_ = sender //
// Shift macOS 10.15 macOS
let shouldUseHandle = IME.arrClientShiftHandlingExceptionList.contains(clientBundleIdentifier)
if #available(macOS 10.15, *) {
if ShiftKeyUpChecker.check(event) {
if !rencentKeyHandledByKeyHandler {
if !shouldUseHandle || (!rencentKeyHandledByKeyHandler && shouldUseHandle) {
NotifierController.notify(
message: String(
format: "%@%@%@", NSLocalizedString("Alphanumerical Mode", comment: ""), "\n",
@ -214,7 +215,9 @@ class ctlInputMethod: IMKInputController {
)
)
}
if shouldUseHandle {
rencentKeyHandledByKeyHandler = false
}
return false
}
}
@ -250,7 +253,9 @@ class ctlInputMethod: IMKInputController {
} errorCallback: {
clsSFX.beep()
}
if shouldUseHandle {
rencentKeyHandledByKeyHandler = result
}
return result
}