From 530d5e4b43d8df214008f24b15bafb35824fd30a Mon Sep 17 00:00:00 2001 From: Andrey Filipenkov Date: Mon, 19 Feb 2024 15:13:51 +0300 Subject: [PATCH] fix broken focus behavior on macOS after showing root warning --- creator.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/creator.cpp b/creator.cpp index 449c3cb..93f2cc7 100644 --- a/creator.cpp +++ b/creator.cpp @@ -191,7 +191,9 @@ Creator::Creator(Privileges &privilegesArg, QWidget *parent) : } setAcceptDrops(true); // allow droping files on a window - showRootMessageBox(); + + // singleShot fixes broken focus behavior if the message is shown on macOS + QTimer::singleShot(0, this, &Creator::showRootMessageBox); // call web browser through our wrapper for Linux QDesktopServices::setUrlHandler("http", this, "httpsUrlHandler");