summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorIgor Borovkov <iborovkov@productengine.com>2009-11-12 15:24:58 +0200
committerIgor Borovkov <iborovkov@productengine.com>2009-11-12 15:24:58 +0200
commit2e01e2bfbd52aa599e8faa5f65b8861f989bee85 (patch)
treef86b79fd885d4ce7c1589e3b7dd72705c969c375 /indra
parentb4e3d34791497188537680a4556ccacaa004db09 (diff)
no ticket, fixed IM message counting and firing new message balloon
--HG-- branch : product-engine
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llchiclet.cpp7
-rw-r--r--indra/newview/llimview.cpp6
2 files changed, 7 insertions, 6 deletions
diff --git a/indra/newview/llchiclet.cpp b/indra/newview/llchiclet.cpp
index b919195fb2..b5119790c0 100644
--- a/indra/newview/llchiclet.cpp
+++ b/indra/newview/llchiclet.cpp
@@ -830,8 +830,13 @@ LLChicletPanel::~LLChicletPanel()
void im_chiclet_callback(LLChicletPanel* panel, const LLSD& data){
LLUUID session_id = data["session_id"].asUUID();
- S32 unread = data["num_unread"].asInteger();
+ LLUUID from_id = data["from_id"].asUUID();
+ const std::string from = data["from"].asString();
+
+ //we do not show balloon (indicator of new messages) for system messages and our own messages
+ if (from_id.isNull() || from_id == gAgentID || SYSTEM_FROM == from) return;
+ S32 unread = data["num_unread"].asInteger();
LLIMFloater* im_floater = LLIMFloater::findInstance(session_id);
if (im_floater && im_floater->getVisible())
{
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index be5fbdbbf8..9c38d9c5fc 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -439,11 +439,7 @@ bool LLIMModel::addMessage(const LLUUID& session_id, const std::string& from, co
addToHistory(session_id, from, from_id, utf8_text);
if (log2file) logToFile(session_id, from, from_id, utf8_text);
- //we do not count system messages and our messages
- if (from_id.notNull() && from_id != gAgentID && SYSTEM_FROM != from)
- {
- session->mNumUnread++;
- }
+ session->mNumUnread++;
// notify listeners
LLSD arg;