summaryrefslogtreecommitdiffstats
path: root/akonadish/main.cpp
diff options
context:
space:
mode:
authorAaron Seigo <aseigo@kde.org>2015-12-24 10:36:56 +0100
committerAaron Seigo <aseigo@kde.org>2015-12-24 10:36:56 +0100
commitb352f61f136f21854b3da5b76d49fe45cbb2d3fd (patch)
tree53accb06f16a6cf1c381176d59e3d2449212a4e8 /akonadish/main.cpp
parentf5d4b7dc12dbb3b38b70bcbe94298972208d64f5 (diff)
downloadsink-b352f61f136f21854b3da5b76d49fe45cbb2d3fd.tar.gz
sink-b352f61f136f21854b3da5b76d49fe45cbb2d3fd.zip
if not being run interactively, then use the main app loop
QEventLoop requires QCoreApplication is running; so when we don't have one running the whole app, just start/stop the core app on demand (from/for commands).
Diffstat (limited to 'akonadish/main.cpp')
-rw-r--r--akonadish/main.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/akonadish/main.cpp b/akonadish/main.cpp
index 695fb82..bd85fb4 100644
--- a/akonadish/main.cpp
+++ b/akonadish/main.cpp
@@ -60,6 +60,7 @@ int main(int argc, char *argv[])
60// JsonListener listener(syntax); 60// JsonListener listener(syntax);
61 } 61 }
62 62
63 State::setHasEventLoop(true);
63 return app.exec(); 64 return app.exec();
64 } else if (!interactive) { 65 } else if (!interactive) {
65 QTextStream inputStream(stdin); 66 QTextStream inputStream(stdin);