tst_qwindowcapturebackend: Fix flaky ZeroStartTime testcase


46c66c8b90b00568a6bacfece2302f6f4fc26d9c changed the semantics of how
we capture the first frame of a stream. It had a side-effect of making
the test 'firstFrame_hasZeroStartTime_whenCaptureIsStartedOrRestarted'
flaky. This test restarts the capture several times and expects the
first frame have start time 0. However, because QVideoFrames are
queued onto the main thread, some frames can be waiting to be processed
even after setActive(false) is done.

This caused the FrameGrabber to sometimes interpret a stale frame from
the previous stream, as the first frame of the new stream.

Pick-to: 6.12
Change-Id: Ia4c935eeff8e4025829dbda0122fa8715d8c80e3
Reviewed-by: Artem Dyomin <artem.dyomin@qt.io>
commit784de078d2c88a9576afb0c915ae5f017a3e5ca8
parent99eda9976d1a12892a85292683bb10e112b1bb72
authorNils Petter Skålerud <nils.petter.skalerud@qt.io>
committerNils Petter Skålerud <nils.petter.skalerud@qt.io>
commit timeTue, 6 Oct 2026 13:31:46 +0000