diff options
author | Mitch Curtis <mitch.curtis@qt.io> | 2023-02-02 13:26:03 +0800 |
---|---|---|
committer | Mitch Curtis <mitch.curtis@qt.io> | 2023-02-13 14:18:41 +0800 |
commit | 62965b67a4b2396abf665645d9c27d5976d95c6e (patch) | |
tree | 4c158e88fd43333324c23cb2a71ab27a2c6b1118 /src/quicktemplates/qquickabstractbutton_p_p.h | |
parent | d99afad4007f9eb8c4cd837077ffb0f1aab09ad8 (diff) |
MenuBarItem: open menu on mouse press, touch release
Windows, macOS and Linux all open menus on mouse press.
Android opens overflow menus on touch release. iOS does too,
though it seems to also open after a press is held for long
enough.
Rather than simply connect the clicked() signal to the triggered()
signal, we need to instead override some event-handling functions
to get better control over when triggered() is emitted.
Task-number: QTBUG-79554
Pick-to: 6.5 6.4
Change-Id: I9dc8dadad9dc6dac52652986306d0e66a2532fb8
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Diffstat (limited to 'src/quicktemplates/qquickabstractbutton_p_p.h')
-rw-r--r-- | src/quicktemplates/qquickabstractbutton_p_p.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/quicktemplates/qquickabstractbutton_p_p.h b/src/quicktemplates/qquickabstractbutton_p_p.h index 9fcb5f5583..731d36189b 100644 --- a/src/quicktemplates/qquickabstractbutton_p_p.h +++ b/src/quicktemplates/qquickabstractbutton_p_p.h @@ -36,6 +36,7 @@ public: return button->d_func(); } + QPointF centerPressPoint() const; void setPressPoint(const QPointF &point); void setMovePoint(const QPointF &point); |