[Interest] How to properly delete qApp?

Till Oliver Knoll till.oliver.knoll at gmail.com
Wed Mar 16 13:14:08 CET 2016



> Am 16.03.2016 um 13:01 schrieb Till Oliver Knoll <till.oliver.knoll at gmail.com>:
> 
> 
> ...
> 
> Oh, and somewhat related: just make double-sure on OS X that your Qt plugin - specifically all GUI and paint operations - happen in the /main/ thread of the host application (if that's possible at all, i.e. you control/own the host app, too). It won't work otherwise (unless you hack your own Cocoa event queue for the host application, and even then you're in a mine field whenever calling other Cocoa APIs... just google for "Qt event queue thread OS X" or the like...)

Just to clarify: this is not a limitation of the Qt implementation on OS X (iOS), but really a limitation (by design) of the underlying Cocoa.

And yes, having a Qt event loop running in a thread other than the "main" thread /does/ work on Windows and Linux (possibly/likely other Unix) - just not on OS X/Cocoa.

Here's a link for starters:

  http://stackoverflow.com/questions/22289423/how-to-avoid-qt-app-exec-blocking-main-thread

Cheers,
  Oliver
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/interest/attachments/20160316/fda3d042/attachment.html>


More information about the Interest mailing list