qt5base-lts/tests/auto/widgets/kernel
Volker Hilsheimer 23b998fa45 QWidget: fix regression when changing focus proxy while it has focus
This follows up on commits 3e7463411e and
947883141d.

The changing of the pointer of QApplicationPrivate does not transfer
focus properly. It updates the pointer, but it doesn't deliver events
or update the widget hierarchy's focus chain. The result is that
multiple line edits might show a blinking cursor.

Instead, use QWidget::setFocus when the focus proxy has changed while
it had focus, and pass OtherFocusReason rather than NoFocusReason.

Add a basic test for QWidget::focusProxy, which exercises this code
path and verifies that pointers are consistent when focus changes as
a side effect of modifying the focusProxy.

Change-Id: I15a4d868bab2b590cfe4a1daa6a3c8cebc9c9ca2
Fixes: QTBUG-83720
Fixes: QTBUG-79707
Pick-to: 5.15
Reviewed-by: David Faure <david.faure@kdab.com>
2020-04-23 16:19:07 +02:00
..
qaction Remove QGuiAction again and split QAction implementation up instead 2020-03-29 11:18:57 +01:00
qactiongroup Remove QGuiAction again and split QAction implementation up instead 2020-03-29 11:18:57 +01:00
qapplication QApplication: remove obsolete globalStrut functionality 2020-04-10 13:59:30 +02:00
qboxlayout Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qdesktopwidget cmake: add widgets/kernel tests 2019-10-31 09:49:03 +00:00
qformlayout Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qgesturerecognizer Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qgridlayout Remove deprecated QStyle enum values 2020-04-16 16:53:18 +02:00
qlayout Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qshortcut Merge remote-tracking branch 'origin/dev' into merge-dev 2020-01-24 13:17:33 +01:00
qsizepolicy Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qstackedlayout Merge remote-tracking branch 'origin/dev' into wip/cmake 2019-11-19 13:53:21 +01:00
qtooltip Merge remote-tracking branch 'origin/dev' into wip/cmake 2019-11-19 13:53:21 +01:00
qwidget QWidget: fix regression when changing focus proxy while it has focus 2020-04-23 16:19:07 +02:00
qwidget_window Merge remote-tracking branch 'origin/5.15' into dev 2020-03-16 18:41:27 +01:00
qwidgetaction Regenerate projects one last time before merge 2020-02-12 17:30:49 +00:00
qwidgetmetatype cmake: add widgets/kernel tests 2019-10-31 09:49:03 +00:00
qwidgetsvariant cmake: add widgets/kernel tests 2019-10-31 09:49:03 +00:00
qwindowcontainer Merge remote-tracking branch 'origin/dev' into wip/cmake 2019-11-19 13:53:21 +01:00
CMakeLists.txt cmake: add widgets/kernel tests 2019-10-31 09:49:03 +00:00
kernel.pro Fix inversed qmake logic for widget action tests 2020-02-20 09:05:28 +01:00