From 780bcbc2ea75603f2eef7369a6f7b5ddfc5888b5 Mon Sep 17 00:00:00 2001 From: Yohann Ferreira Date: Tue, 28 Dec 2010 22:04:41 +0100 Subject: Revert "Remove the AFK response system" This reverts commit 3d6a2d9c80a969c3613f567dd7029e75ef59b5cb. I've by that readded the AFK system on master. Please, remove it when we've got a proper replacement. --- src/localplayer.h | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) (limited to 'src/localplayer.h') diff --git a/src/localplayer.h b/src/localplayer.h index 334a2598..a5328182 100644 --- a/src/localplayer.h +++ b/src/localplayer.h @@ -38,6 +38,12 @@ class Item; class Map; class OkDialog; +class AwayListener : public gcn::ActionListener +{ + public: + void action(const gcn::ActionEvent &event); +}; + /** * The local player character. */ @@ -178,6 +184,15 @@ class LocalPlayer : public Being bool isPathSetByMouse() const { return mPathSetByMouse; } + void changeAwayMode(); + + bool getAwayMode() + { return mAwayMode; } + + void setAway(const std::string &message); + + void afkRespond(ChatTab *tab, const std::string &nick); + void addMessageToQueue(const std::string &message, int color = UserPalette::EXP_INFO); @@ -227,6 +242,11 @@ class LocalPlayer : public Being int mMessageTime; bool mShowIp; + + AwayListener *mAwayListener; + OkDialog *mAwayDialog; + int mAfkTime; + bool mAwayMode; }; extern LocalPlayer *player_node; -- cgit v1.2.3-60-g2f50