summaryrefslogtreecommitdiffstats
path: root/tests/auto/gui/kernel/qevent
diff options
context:
space:
mode:
authorMikolaj Boc <mikolaj.boc@qt.io>2023-05-08 08:21:49 +0200
committerMikolaj Boc <mikolaj.boc@qt.io>2023-06-09 16:31:35 +0200
commit78acaf4fb6acfc51f8cc823e381e4cf593a715b7 (patch)
tree453a5dffa9a01cdad9b8a1d959a580c0a617a57f /tests/auto/gui/kernel/qevent
parent30e5ff3ff223d665fbed3baf2d08ad3fcf2b8455 (diff)
Fix sending deferred delete events when posted before outermost loop
QDeferredDeleteEvent has the loopLevel field, which is a sum of scope and loop levels found at posting. In sendPostedEvents however, it is impossible to only use this information to find delete events posted before the outermost loop (which should be handled by any loop) based solely on this information, as the scope level essentialy removes the information on loop level. Break the loopLevel in two, storing both loop and scope levels in QDeferredDeleteEvent, so that we can check whether an event was posted before the outermost event loop (for which we need to compare only the loop level). QDeferredDeleteEvent was also made private as it should - it is an implementation detail that wasn't hidden properly. Change-Id: I0a607a0bd3a2deb5024acad67f740dbf4338574c Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> Reviewed-by: Mikołaj Boc <Mikolaj.Boc@qt.io>
Diffstat (limited to 'tests/auto/gui/kernel/qevent')
-rw-r--r--tests/auto/gui/kernel/qevent/tst_qevent.cpp1
1 files changed, 0 insertions, 1 deletions
diff --git a/tests/auto/gui/kernel/qevent/tst_qevent.cpp b/tests/auto/gui/kernel/qevent/tst_qevent.cpp
index f1ffb8c35e..56d483107b 100644
--- a/tests/auto/gui/kernel/qevent/tst_qevent.cpp
+++ b/tests/auto/gui/kernel/qevent/tst_qevent.cpp
@@ -14,7 +14,6 @@
X(QTimerEvent, (42)) \
X(QChildEvent, (QEvent::ChildAdded, nullptr)) \
X(QDynamicPropertyChangeEvent, ("size")) \
- X(QDeferredDeleteEvent, ()) \
/* qfutureinterface_p.h */ \
X(QFutureCallOutEvent, ()) \
/* end */