From a4f6021ace90c97d2fdb4bbad2c3953088068193 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Sun, 24 May 2015 12:02:17 +0200 Subject: [PATCH] Force to handle DCOP requests in KUniqueApplication (newInstance call) This resolves Bug 2437 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Slávek Banko (cherry picked from commit c6c1d781a5035e6740532366a09a48448a93666c) --- tdecore/kuniqueapplication.cpp | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/tdecore/kuniqueapplication.cpp b/tdecore/kuniqueapplication.cpp index 0a3a0962a..12c9c1297 100644 --- a/tdecore/kuniqueapplication.cpp +++ b/tdecore/kuniqueapplication.cpp @@ -322,9 +322,14 @@ KUniqueApplication::KUniqueApplication(bool allowStyles, bool GUIenabled, bool c d->processingRequest = false; d->firstInstance = true; - if (s_nofork) + if (s_nofork) { // Can't call newInstance directly from the constructor since it's virtual... TQTimer::singleShot( 0, this, TQT_SLOT(newInstanceNoFork()) ); + } + else { + // Force to handle DCOP requests (newInstance call) + TQTimer::singleShot( 0, this, TQT_SLOT(processDelayed())); + } } @@ -338,9 +343,14 @@ KUniqueApplication::KUniqueApplication(Display *display, Qt::HANDLE visual, d->processingRequest = false; d->firstInstance = true; - if (s_nofork) + if (s_nofork) { // Can't call newInstance directly from the constructor since it's virtual... TQTimer::singleShot( 0, this, TQT_SLOT(newInstanceNoFork()) ); + } + else { + // Force to handle DCOP requests (newInstance call) + TQTimer::singleShot( 0, this, TQT_SLOT(processDelayed())); + } } #endif