summaryrefslogtreecommitdiff
path: root/src/actions/chat.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/actions/chat.cpp')
-rw-r--r--src/actions/chat.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/actions/chat.cpp b/src/actions/chat.cpp
index 74f3fc691..22d31fbb9 100644
--- a/src/actions/chat.cpp
+++ b/src/actions/chat.cpp
@@ -68,6 +68,9 @@
#include "gui/widgets/tabs/chattab.h"
+#include "net/net.h"
+#include "net/partyhandler.h"
+
#include "utils/gettext.h"
#include "utils/stringutils.h"
@@ -242,4 +245,21 @@ impHandler0(clearChatTab)
return false;
}
+impHandler(createParty)
+{
+ if (!event.tab)
+ return false;
+
+ if (event.args.empty())
+ {
+ // TRANSLATORS: create party message
+ event.tab->chatLog(_("Party name is missing."), ChatMsgType::BY_SERVER);
+ }
+ else
+ {
+ Net::getPartyHandler()->create(event.args);
+ }
+ return true;
+}
+
} // namespace Actions