summaryrefslogtreecommitdiff
path: root/vcl/inc
diff options
context:
space:
mode:
authorAleksei Nikiforov <darktemplar@basealt.ru>2019-01-16 14:57:42 +0300
committerSamuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>2019-01-28 15:52:37 +0100
commit04dff1b796c1ee84da0b2861fc42e35891f76101 (patch)
tree1f13814fb1039b432de0659090c08322cdce1d14 /vcl/inc
parenta454fe6ca36924bfcb0db984aab54ad5242949f0 (diff)
tdf#122238 KDE5: disable mechanism of Qt for shortcut activation
When QEvent::KeyPress event is processed, QEvent::ShortcutOverride event is created and processed before finishing processing original event. If it's an active shortcut, and QEvent::ShortcutOverride event is not accepted, the shortcut is activated, but QEvent::KeyPress event is omitted. If it's an active shortcut, and QEvent::ShortcutOverride event is accepted, the shortcut is not activated, and QEvent::KeyPress event is sent as usual. But it looks like even if shortcut activation is suppressed, shortcut is still called somewhere from insides SalEvent::KeyInput event processing callback from Qt5Widget::handleKeyEvent function. Shortcuts are still assigned to menu actions since it shows the key combinations used to activate them. Change-Id: I1ffc63c2530dd61ae67ab66a96ea3efe767218c0 Reviewed-on: https://gerrit.libreoffice.org/66444 Tested-by: Jenkins Reviewed-by: Thorsten Behrens <Thorsten.Behrens@CIB.de> (cherry picked from commit 5843e14a4ddc6d2b1e375ca26eec33033bfad455) Reviewed-on: https://gerrit.libreoffice.org/66990 Reviewed-by: Samuel Mehrbrodt <Samuel.Mehrbrodt@cib.de>
Diffstat (limited to 'vcl/inc')
-rw-r--r--vcl/inc/qt5/Qt5Widget.hxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/vcl/inc/qt5/Qt5Widget.hxx b/vcl/inc/qt5/Qt5Widget.hxx
index 26f26c8bf0a3..4337792dfc43 100644
--- a/vcl/inc/qt5/Qt5Widget.hxx
+++ b/vcl/inc/qt5/Qt5Widget.hxx
@@ -45,6 +45,8 @@ class Qt5Widget : public QWidget
bool handleKeyEvent(QKeyEvent*, bool);
void handleMouseButtonEvent(QMouseEvent*, bool);
+ virtual bool event(QEvent*) override;
+
virtual void focusInEvent(QFocusEvent*) override;
virtual void focusOutEvent(QFocusEvent*) override;
virtual void keyPressEvent(QKeyEvent*) override;