SessionCtl // Deprecate .isCapsLocked().

This commit is contained in:
ShikiSuen 2023-10-30 11:56:42 +08:00
parent 65cf83d902
commit 36fe4fced3
2 changed files with 1 additions and 4 deletions

View File

@ -79,9 +79,6 @@ public class SessionCtl: IMKInputController {
// MARK: - // MARK: -
/// Caps Lock
public static var isCapsLocked: Bool { NSEvent.keyModifierFlags.contains(.capsLock) }
/// SessionCtl /// SessionCtl
public var isASCIIMode: Bool { public var isASCIIMode: Bool {
get { get {

View File

@ -195,7 +195,7 @@ public extension SessionCtl {
? NSLocalizedString("Alphanumerical Input Mode", comment: "") + "\n" + status ? NSLocalizedString("Alphanumerical Input Mode", comment: "") + "\n" + status
: NSLocalizedString("Chinese Input Mode", comment: "") + "\n" + status : NSLocalizedString("Chinese Input Mode", comment: "") + "\n" + status
) )
if PrefMgr.shared.shiftEisuToggleOffTogetherWithCapsLock, oldValue, !newValue, Self.isCapsLocked { if PrefMgr.shared.shiftEisuToggleOffTogetherWithCapsLock, oldValue, !newValue, CapsLockToggler.isOn {
CapsLockToggler.turnOff() CapsLockToggler.turnOff()
} }
} }