From 55c25229b79b1755c989e5996c8e8d118f369721 Mon Sep 17 00:00:00 2001 From: James Cook Date: Thu, 3 Apr 2008 18:43:54 +0000 Subject: svn merge -r 83778:83944 maint-ui-10-merge QAR-442 --- indra/newview/llcallingcard.cpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'indra/newview/llcallingcard.cpp') diff --git a/indra/newview/llcallingcard.cpp b/indra/newview/llcallingcard.cpp index 0e0880959e..11d4f4c651 100644 --- a/indra/newview/llcallingcard.cpp +++ b/indra/newview/llcallingcard.cpp @@ -60,6 +60,8 @@ #include "llviewerobjectlist.h" #include "llviewerwindow.h" #include "llvoavatar.h" +#include "llimview.h" +#include "llimpanel.h" ///---------------------------------------------------------------------------- /// Local function declarations, constants, enums, and typedefs @@ -671,7 +673,18 @@ void LLAvatarTracker::processNotify(LLMessageSystem* msg, bool online) } if(notify) { + // Popup a notify box with online status of this agent LLNotifyBox::showXml(online ? "FriendOnline" : "FriendOffline", args); + + // If there's an open IM session with this agent, send a notification there too. + LLUUID session_id = LLIMMgr::computeSessionID(IM_NOTHING_SPECIAL, agent_id); + LLFloaterIMPanel *floater = gIMMgr->findFloaterBySession(session_id); + if (floater) + { + LLUIString notifyMsg = LLNotifyBox::getTemplateMessage((online ? "FriendOnline" : "FriendOffline"),args); + if (!notifyMsg.empty()) + floater->addHistoryLine(notifyMsg,gSavedSettings.getColor4("SystemChatColor")); + } } mModifyMask |= LLFriendObserver::ONLINE; -- cgit v1.2.3