From 086356622db7b0734be68c58e064544fa243be1b Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Mon, 7 Mar 2016 01:13:22 +0300 Subject: Add /mailto chat command. --- src/gui/windows/mailwindow.cpp | 9 +++++++++ src/gui/windows/mailwindow.h | 2 ++ 2 files changed, 11 insertions(+) (limited to 'src/gui') diff --git a/src/gui/windows/mailwindow.cpp b/src/gui/windows/mailwindow.cpp index 071a1ecee..87b732bf8 100644 --- a/src/gui/windows/mailwindow.cpp +++ b/src/gui/windows/mailwindow.cpp @@ -283,3 +283,12 @@ void MailWindow::postConnection() { mailHandler->refresh(); } + +void MailWindow::createMail(const std::string &to) +{ + if (mailEditWindow) + return; + + CREATEWIDGETV0(mailEditWindow, MailEditWindow); + mailEditWindow->setTo(to); +} diff --git a/src/gui/windows/mailwindow.h b/src/gui/windows/mailwindow.h index 6500542c9..1a78c1de9 100644 --- a/src/gui/windows/mailwindow.h +++ b/src/gui/windows/mailwindow.h @@ -67,6 +67,8 @@ class MailWindow final : public Window, void postConnection(); + void createMail(const std::string &to); + private: std::vector mMessages; std::map mMessagesMap; -- cgit v1.2.3-70-g09d2