summaryrefslogtreecommitdiff
path: root/indra/newview/llnotificationtiphandler.cpp
diff options
context:
space:
mode:
authorLeyla Farazha <leyla@lindenlab.com>2009-10-28 17:12:47 -0700
committerLeyla Farazha <leyla@lindenlab.com>2009-10-28 17:12:47 -0700
commit437449044583d50c8cad694e65e5a4a23a55d768 (patch)
treec7637a8dbc31d933ca05e999eea7f9fd34daa305 /indra/newview/llnotificationtiphandler.cpp
parent9426de7e10fa7cfe84048ae7dd58a793e981ee33 (diff)
parentd993ce14d83530544c0e0f05af10d235999d9a5f (diff)
tab container fixes..
Diffstat (limited to 'indra/newview/llnotificationtiphandler.cpp')
-rw-r--r--indra/newview/llnotificationtiphandler.cpp22
1 files changed, 14 insertions, 8 deletions
diff --git a/indra/newview/llnotificationtiphandler.cpp b/indra/newview/llnotificationtiphandler.cpp
index 7239f49b7f..543198c1d2 100644
--- a/indra/newview/llnotificationtiphandler.cpp
+++ b/indra/newview/llnotificationtiphandler.cpp
@@ -86,6 +86,20 @@ bool LLTipHandler::processNotification(const LLSD& notify)
if(notify["sigtype"].asString() == "add" || notify["sigtype"].asString() == "change")
{
+ // archive message in nearby chat
+ LLNearbyChat* nearby_chat = LLFloaterReg::getTypedInstance<LLNearbyChat>("nearby_chat", LLSD());
+ if(nearby_chat)
+ {
+ LLChat chat_msg(notification->getMessage());
+ nearby_chat->addMessage(chat_msg);
+
+ // don't show toast if Nearby Chat is opened
+ if (nearby_chat->getVisible())
+ {
+ return true;
+ }
+ }
+
LLToastNotifyPanel* notify_box = new LLToastNotifyPanel(notification);
LLToast::Params p;
@@ -99,14 +113,6 @@ bool LLTipHandler::processNotification(const LLSD& notify)
LLScreenChannel* channel = dynamic_cast<LLScreenChannel*>(mChannel);
if(channel)
channel->addToast(p);
-
- // archive message in nearby chat
- LLNearbyChat* nearby_chat = LLFloaterReg::getTypedInstance<LLNearbyChat>("nearby_chat", LLSD());
- if(nearby_chat)
- {
- LLChat chat_msg(notification->getMessage());
- nearby_chat->addMessage(chat_msg);
- }
}
else if (notify["sigtype"].asString() == "delete")
{