Home GnuPG

qt: Differentiate unknown Caps Lock state from off state

Description

qt: Differentiate unknown Caps Lock state from off state

* qt/capslock.h (enum class LockState): New.
* qt/capslock.h, qt/capslock_unix.cpp, qt/capslock_win.cpp
(capsLockIsOn, capsLockState): Rename former to latter. Change return
type to LockState.
* qt/capslock_unix.cpp (capsLockState): Remove check for qApp.
* qt/pinentrydialog.cpp (checkCapsLock): Adapt to changed function name
and return type of capsLockIsOn/capsLockState.

This change allows the pinentry to ignore an unknown state of Caps Lock.

Details

Provenance
ikloeckerAuthored on Jul 26 2021, 3:06 PM
Parents
rP9dd46926f8d5: qt: Fix showing of pinentry window on Wayland
Branches
Unknown
Tags
Unknown
Tasks
T4950: pinentry: Add warning when capslock is on