[Interest] QtWinMigrate and QThread event loop (4.8.3)

Douglas.Lee at teledynelecroy.com Douglas.Lee at teledynelecroy.com
Wed Oct 31 17:56:10 CET 2012


Hi,

I've recently discovered that if an application creates a new background 
QThread and calls QThread::start() to start the thread's event loop, that 
thread will sometimes process QMfcApp::winEventFilter, which in turn will 
cause MFC events to be processed in the background thread. However, this 
will cause some problems because the MFC events are only meant to be 
processed in the application's main thread.

Would it be appropriate to do a thread check inside 
QMfcApp::winEventFilter and only allow it to proceed if the current thread 
is the main thread? I'm not familiar with the lineage of this class, but 
the way it's written, I think there was an assumption that it would only 
get called from the main thread.

Thanks,

Doug
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20121031/0ff2971e/attachment.html>


More information about the Interest mailing list