https://bugs.kde.org/show_bug.cgi?id=416202
Bug ID: 416202
Summary: Unable to load file by starting Krita while running an
instance in single application mode
Product: krita
Version: git master
Platform: Other
OS: Linux
Status: REPORTED
Severity: normal
Priority: NOR
Component: General
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
When the "Allow only one instance of Krita" option is set and an instance of
Krita is already running, trying to load a document by the likes of "krita
./document.kra" will do nothing.
This seems to be a regression caused by the resolution of bug #415794.
The following patch fixes this by reintroducing a chunk that was removed in
4c715c4c9470b9a454413cd9002ace514abc7ee1.
I chose to submit this as bug rather than a patch because I have not properly
tested if it will make bug #415794 happen again and I don't have a clear
understanding of what this change does at the moment, but I can commit it if
desired.
diff --git a/libs/ui/KisApplication.cpp b/libs/ui/KisApplication.cpp
index 4d94ee428f..8b0bfc4676 100644
--- a/libs/ui/KisApplication.cpp
+++ b/libs/ui/KisApplication.cpp
@@ -696,6 +696,10 @@ void KisApplication::remoteArguments(QByteArray message,
QObject *socket)
// check if we have any mainwindow
KisMainWindow *mw = qobject_cast<KisMainWindow*>(qApp->activeWindow());
+ if (!mw) {
+ mw = KisPart::instance()->mainWindows().first();
+ }
+
if (!mw) {
d->earlyRemoteArguments << message;
return;
--
You are receiving this mail because:
You are watching all bug changes.