diff --git a/sixtyfps_runtime/rendering_backends/qt/lib.rs b/sixtyfps_runtime/rendering_backends/qt/lib.rs index 42e43825a..f15bba229 100644 --- a/sixtyfps_runtime/rendering_backends/qt/lib.rs +++ b/sixtyfps_runtime/rendering_backends/qt/lib.rs @@ -150,7 +150,11 @@ impl sixtyfps_corelib::backend::Backend for Backend { { use cpp::cpp; cpp! {unsafe [] { - qApp->quit(); + // Use a quit event to avoid qApp->quit() calling + // [NSApp terminate:nil] and us never returning from the + // event loop - sixtyfps-viewer relies on the ability to + // return from run(). + QCoreApplication::postEvent(qApp, new QEvent(QEvent::Quit)); } } }; }