Multiple OSs, one codebase, Part 4 - Blocking the main UI thread

October 10, 2026 Qt Software

In short, don't. Android can lock up. WASM will.

So, don't wait for dialogs to finish. Set up a connection to the done (Ok, Continue, whatever) and continue processing from there.

I had a bad habit of doing multiple dialogs in a method, one after the other. This led to almost immediate halts on the main UI thread (where the method started, and Qt spinning up a new thread for the new dialog and Bob's your uncle, you've just locked up.

Like I said before, connect the done signal, and the call open and gracefully continue to the end of the method and let the main UI handle the dialog,

Really, I can't think of any other showstoppers. I know they are out there, I just either already code around them, or haven't hit them yet.

Comments (0)

No comments yet. Be the first hero to speak up.

Leave a comment