[Qt-interest] Is there a way to process all queued events before continuing?

Andre Somers andre at familiesomers.nl
Wed Dec 16 17:22:37 CET 2009


Preet wrote:
> Hi,
>
> Thanks for the reply. I'm trying to clear all pending events in my 
> secondary thread's event queue. Doesn't processEvents do this for my 
> main Gui thread? (not what I want to do). There's no 
> QThread::ProcessEvents() function... I'm looking for such an analog.
>
> -Preet
Interesting question. QEventLoop has a processEvents, but I don't see a 
method in QThread to access the thread's event loop... Perhaps the 
source could give you a pointer if there is an (undocumented) loophope 
to get it anyway?

André




More information about the Qt-interest-old mailing list