From 8220be404ab8cc8d768a5b7415be0d13747e8cbb Mon Sep 17 00:00:00 2001 From: ShikiSuen Date: Thu, 28 Apr 2022 09:15:56 +0800 Subject: [PATCH] ctlIME // Update InputMode conditioning. --- Source/Modules/IMEModules/ctlInputMethod.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Modules/IMEModules/ctlInputMethod.swift b/Source/Modules/IMEModules/ctlInputMethod.swift index 2e2dc926..ad7fc055 100644 --- a/Source/Modules/IMEModules/ctlInputMethod.swift +++ b/Source/Modules/IMEModules/ctlInputMethod.swift @@ -112,7 +112,7 @@ class ctlInputMethod: IMKInputController { } override func setValue(_ value: Any!, forTag _: Int, client: Any!) { - var newInputMode = InputMode(rawValue: value as? String ?? InputMode.imeModeNULL.rawValue) + var newInputMode: InputMode = InputMode(rawValue: value as? String ?? "") ?? InputMode.imeModeNULL switch newInputMode { case InputMode.imeModeCHS: newInputMode = InputMode.imeModeCHS