qt5base-lts/tests/auto/corelib/thread/qfuture
Sona Kurazyan 2f15927f01 Add a way of notifying QFutureWatcher when pause is in effect
Because setting QFutureInterface to paused state does not mean that
the computations that are already in progress will stop immediately,
it may be useful to get notified when pause actually takes effect.

Introduced the QFutureWatcher::suspended() signal, to be emitted when
there are no more computations in progress, and no more result ready
or progress reporting signals will be emitted, i.e. when pause took
effect. Added {QFuture, QFutureWatcher}::isSuspended() methods for
checking if pause took effect.

QtConcurrent will now to send QFutureCallOutEvent::Suspended event
when the state is paused and there are no more active threads.

[ChangeLog][QtCore][QFutureWatcher] Added a new QFutureWatcher::suspended()
signal, to be emitted when pause took effect, meaning that there are no
more computations in progress. Added {QFuture, QFutureWatcher}::isSuspended()
methods for checking if pause took effect.

Fixes: QTBUG-12152
Change-Id: I88f2ad24d800cd6293dec63977d45bd35f9a09f0
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
2020-05-29 16:58:43 +02:00
..
.gitignore Move QFuture from QtConcurrent to QtCore 2012-09-28 23:50:10 +02:00
.prev_CMakeLists.txt CMake: Regenerate tests projects 2020-03-12 11:41:39 +01:00
CMakeLists.txt Get rid of some QT_STRICT_ITERATORS leftover 2020-03-05 16:08:30 +01:00
qfuture.pro Get rid of QT_STRICT_ITERATORS 2019-11-04 12:52:26 +00:00
tst_qfuture.cpp Add a way of notifying QFutureWatcher when pause is in effect 2020-05-29 16:58:43 +02:00