diff options
author | William Todd Stinson <stinson@lindenlab.com> | 2012-12-19 01:48:37 -0800 |
---|---|---|
committer | William Todd Stinson <stinson@lindenlab.com> | 2012-12-19 01:48:37 -0800 |
commit | bd6d34d312c3e3322ab62f3a60253fb88fcbc9e3 (patch) | |
tree | 9a32809b727586b0e816e085be29e332befeadff /indra/newview/llagent.cpp | |
parent | 6b9ead91459d702727b54ab7e51614c2d5959f5f (diff) |
CHUI-499: Loading the DND notifications upon exit from DND mode and after login.
Diffstat (limited to 'indra/newview/llagent.cpp')
-rwxr-xr-x | indra/newview/llagent.cpp | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp index 49c570c30b..fc3be9ca21 100755 --- a/indra/newview/llagent.cpp +++ b/indra/newview/llagent.cpp @@ -41,6 +41,7 @@ #include "llchannelmanager.h" #include "llchicletbar.h" #include "llconsole.h" +#include "lldonotdisturbnotificationstorage.h" #include "llenvmanager.h" #include "llfirstuse.h" #include "llfloatercamera.h" @@ -1389,11 +1390,16 @@ BOOL LLAgent::getAFK() const //----------------------------------------------------------------------------- // setDoNotDisturb() //----------------------------------------------------------------------------- -void LLAgent::setDoNotDisturb(bool pIsDotNotDisturb) +void LLAgent::setDoNotDisturb(bool pIsDoNotDisturb) { - mIsDoNotDisturb = pIsDotNotDisturb; - sendAnimationRequest(ANIM_AGENT_DO_NOT_DISTURB, (pIsDotNotDisturb ? ANIM_REQUEST_START : ANIM_REQUEST_STOP)); - LLNotificationsUI::LLChannelManager::getInstance()->muteAllChannels(pIsDotNotDisturb); + bool isDoNotDisturbSwitchedOff = (mIsDoNotDisturb && !pIsDoNotDisturb); + mIsDoNotDisturb = pIsDoNotDisturb; + sendAnimationRequest(ANIM_AGENT_DO_NOT_DISTURB, (pIsDoNotDisturb ? ANIM_REQUEST_START : ANIM_REQUEST_STOP)); + LLNotificationsUI::LLChannelManager::getInstance()->muteAllChannels(pIsDoNotDisturb); + if (isDoNotDisturbSwitchedOff) + { + LLDoNotDisturbNotificationStorage::getInstance()->loadNotifications(); + } } //----------------------------------------------------------------------------- |