summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-02-19 00:30:24 +0300
committerAndrei Karas <akaras@inbox.ru>2013-02-19 00:30:24 +0300
commite63b10c3a63d93b9a6dfa144624fea8610d7768c (patch)
tree2c537174bb2134ea7b58cbaa6f648c2acd7a8006 /src/localplayer.cpp
parente73c5ecc896c14fa43b19e42e5b24c79766cdb44 (diff)
downloadmanaplus-e63b10c3a63d93b9a6dfa144624fea8610d7768c.tar.gz
manaplus-e63b10c3a63d93b9a6dfa144624fea8610d7768c.tar.bz2
manaplus-e63b10c3a63d93b9a6dfa144624fea8610d7768c.tar.xz
manaplus-e63b10c3a63d93b9a6dfa144624fea8610d7768c.zip
Add support for GM tab.
This tab visible all messages from @wgm chat command and local messages in this tab.
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r--src/localplayer.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 99ef5a242..43c15428a 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -51,6 +51,7 @@
#include "gui/socialwindow.h"
#include "gui/viewport.h"
+#include "gui/widgets/gmtab.h"
#include "gui/widgets/whispertab.h"
#include "net/beinghandler.h"
@@ -392,11 +393,14 @@ void LocalPlayer::setGMLevel(const int level)
{
setGM(true);
if (chatWindow)
+ {
chatWindow->loadGMCommands();
+ if (!gmChatTab)
+ gmChatTab = new GmTab(chatWindow);
+ }
}
}
-
Position LocalPlayer::getNextWalkPosition(const unsigned char dir) const
{
// Compute where the next tile will be set.