From 8fb90d064dc672213d8b7fc89584bafe2bc740b3 Mon Sep 17 00:00:00 2001 From: Jin Liu Date: Tue, 1 Oct 2024 19:20:04 +0800 Subject: [PATCH] daemon: prevent daemon to quit on `openNewWindow` --- src/main.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/main.cpp b/src/main.cpp index df725a33f..f811c4f06 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -164,6 +164,9 @@ int main(int argc, char **argv) } if (parser.isSet(QStringLiteral("daemon"))) { + // Prevent KApplicationLauncherJob from cause the application to quit on job finish. + QCoreApplication::setQuitLockEnabled(false); + // Disable session management for the daemonized version // See https://bugs.kde.org/show_bug.cgi?id=417219 auto disableSessionManagement = [](QSessionManager &sm) { -- 2.47.3