[Development] Allowing event delivery prior to and after QCoreApplication
Thiago Macieira
thiago.macieira at intel.com
Fri Apr 17 00:22:04 CEST 2015
On Wednesday 15 April 2015 08:20:31 Thiago Macieira wrote:
> Thanks André. The above contains two use-cases for overriding notify():
>
> 1) catching exceptions, logging and resuming work
> 2) debugging / inspecting events
>
So far, given the responses in the interest mailing list, it appears that
applications would break imperceptibly for notify() no longer being called in
the auxiliary threads. Therefore, I'm redesigning the solution. I'm proposing
then the following:
1) deprecate use of notify() in auxiliary threads, with the functionality
getting removed in Qt 6 (this is a documentation change only)
2) add a way for threads to individually enable delivery past the
QCoreApplication's lifetime, which implies notify() is skipped. I will add
this as a private API only.
3) add new mechanisms for filtering and logging events
4) add a mechanism to catch, log and gracefully act on exceptions thrown from
event handlers and slots
5) after 3 and 4 are in, deprecate overriding of notify() altogether, with the
possibility removed altogether in Qt 6.
Since I only need 1 & 2 for my needs, I will not implement 3-5 any time soon
(or ever). Exercise left to the reader.
--
Thiago Macieira - thiago.macieira (AT) intel.com
Software Architect - Intel Open Source Technology Center
More information about the Development
mailing list