From 28acccbfc1174638945a323049290b685299437f Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Fri, 16 Dec 2016 14:48:30 +0100 Subject: Close the composer when done --- framework/domain/composercontroller.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'framework/domain/composercontroller.cpp') diff --git a/framework/domain/composercontroller.cpp b/framework/domain/composercontroller.cpp index 18ebc4c4..d2b3bc9c 100644 --- a/framework/domain/composercontroller.cpp +++ b/framework/domain/composercontroller.cpp @@ -183,6 +183,10 @@ Kube::Action* ComposerController::saveAsDraftAction() { auto action = new Kube::Action("org.kde.kube.actions.save-as-draft", *mContext); action->addPreHandler(messageHandler()); + action->addPostHandler(new Kube::ActionHandlerHelper( + [this](Kube::Context *context) { + emit done(); + })); return action; } @@ -193,6 +197,10 @@ Kube::Action* ComposerController::sendAction() // action->addPreHandler(identityHandler()); action->addPreHandler(messageHandler()); // action->addPreHandler(encryptionHandler()); + action->addPostHandler(new Kube::ActionHandlerHelper( + [this](Kube::Context *context) { + emit done(); + })); return action; } -- cgit v1.2.3