X11 spawns painting threads and sends an expose event at the same time.
While the worker is still paining, QXcbScreen::topLevelAt() may not
find the window, even if it reports being exposed.
Wait until windows are exposed and painted.
Remove workaround to intercept warnings about undeliverable gestures.
Remove qWait() antipattern.
Fixes: QTBUG-130811
Fixes: QTBUG-84258
Fixes: QTBUG-69648
Fixes: QTBUG-67393
Fixes: QTBUG-67392
Fixes: QTBUG-67389
Fixes: QTBUG-68861
Fixes: QTBUG-70224
Fixes: QTBUG-70223
Fixes: QTBUG-67395
Fixes: QTBUG-70227
Fixes: QTBUG-70226
Fixes: QTBUG-70209
Fixes: QTBUG-70153
Pick-to: 6.5
Change-Id: Id126fe884ba360551425f3e2b29674f5b9419fff
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
(cherry picked from commit 705bac063cc5ec535ff5467a208d5653555ae8f9)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>