summaryrefslogtreecommitdiffstats
path: root/src/gui/text/qtextdocument.h
diff options
context:
space:
mode:
authorGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2016-09-06 17:26:07 +0100
committerGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2016-10-15 16:25:57 +0000
commit9944a12a0f57087ea19ae428ffcd974ac0fed7bc (patch)
treea39657ae2ca3d2de3ec9947aaa7e0783faf6b7ca /src/gui/text/qtextdocument.h
parent60e3bfe958cb0130e5dd71296c000c1f8e23ec0e (diff)
QMenuBar: do not gain focus when releasing Alt before X in a Alt+X shortcut
It might happen that, when pressing Alt+X to trigger a shortcut for an action in a menubar, that the user releases Alt first, followed by X. When that happens, QMenuBar gains focus as if the user just pressed and released Alt (to focus the menu bar). That's counterintuitive, frustating and not what native Windows seems to do. Fix this by resetting the "altPressed" state whenever a shortcut gets triggered with the Alt key pressed. (In the above discussion, X stands for any key). Task-number: QTBUG-46812 Change-Id: If4b7a47842791894a3a32d09db5de229ed33773e Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Diffstat (limited to 'src/gui/text/qtextdocument.h')
0 files changed, 0 insertions, 0 deletions