summaryrefslogtreecommitdiff
path: root/src/localplayer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/localplayer.cpp')
-rw-r--r--src/localplayer.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/localplayer.cpp b/src/localplayer.cpp
index 7fc1d8c7d..16409d16c 100644
--- a/src/localplayer.cpp
+++ b/src/localplayer.cpp
@@ -113,6 +113,7 @@ LocalPlayer::LocalPlayer(int id, int subtype):
mAwayDialog(0),
mAfkTime(0),
mAwayMode(false),
+ mPseudoAwayMode(false),
mShowNavigePath(false),
mDrawPath(false),
mActivityTime(0),
@@ -357,7 +358,7 @@ void LocalPlayer::logic()
if (mTradebot && shopWindow && !shopWindow->isShopEmpty())
smile += FLAG_SHOP;
- if (mAwayMode)
+ if (mAwayMode || mPseudoAwayMode)
smile += FLAG_AWAY;
if (mInactive)
@@ -3202,6 +3203,13 @@ void LocalPlayer::setAway(const std::string &message)
changeAwayMode();
}
+void LocalPlayer::setPseudoAway(const std::string &message)
+{
+ if (!message.empty())
+ config.setValue("afkMessage", message);
+ mPseudoAwayMode = !mPseudoAwayMode;
+}
+
void LocalPlayer::afkRespond(ChatTab *tab, const std::string &nick)
{
if (mAwayMode)