mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-08-02 03:26:14 -04:00
Handle KeyRelease events of global shortcuts.
This commit is contained in:
parent
54641a2304
commit
8b0409b228
1 changed files with 6 additions and 2 deletions
|
@ -154,10 +154,14 @@ int AutoTypePlatformX11::platformEventFilter(void* event)
|
|||
{
|
||||
XEvent* xevent = static_cast<XEvent*>(event);
|
||||
|
||||
if (xevent->type == KeyPress && m_currentGlobalKey && xevent->xkey.keycode == m_currentGlobalKeycode
|
||||
if ((xevent->type == KeyPress || xevent->type == KeyRelease)
|
||||
&& m_currentGlobalKey
|
||||
&& xevent->xkey.keycode == m_currentGlobalKeycode
|
||||
&& (xevent->xkey.state & m_modifierMask) == m_currentGlobalNativeModifiers
|
||||
&& !QApplication::focusWidget()) {
|
||||
Q_EMIT globalShortcutTriggered();
|
||||
if (xevent->type == KeyPress) {
|
||||
Q_EMIT globalShortcutTriggered();
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
if (xevent->type == MappingNotify) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue