summaryrefslogtreecommitdiff
path: root/indra/newview/llnearbychathandler.cpp
diff options
context:
space:
mode:
authorSteve Bennetts <steve@lindenlab.com>2009-11-02 10:55:59 -0800
committerSteve Bennetts <steve@lindenlab.com>2009-11-02 10:55:59 -0800
commitb877665551343dc94ca02c84622b06518f9c23d8 (patch)
tree9ad6a76d0363b56ccb249f105d6ee72207df8864 /indra/newview/llnearbychathandler.cpp
parentf732ee6d2e24cd42a06b9cf51c8f6c577f2e476e (diff)
parent6e018f7143537af7bd9a08f1cc5c87ea4c8382c8 (diff)
merge
Diffstat (limited to 'indra/newview/llnearbychathandler.cpp')
-rw-r--r--indra/newview/llnearbychathandler.cpp20
1 files changed, 20 insertions, 0 deletions
diff --git a/indra/newview/llnearbychathandler.cpp b/indra/newview/llnearbychathandler.cpp
index 4aefbd1a33..957513e154 100644
--- a/indra/newview/llnearbychathandler.cpp
+++ b/indra/newview/llnearbychathandler.cpp
@@ -162,6 +162,8 @@ bool LLNearbyChatScreenChannel::createPoolToast()
LLToast::Params p;
p.panel = panel;
+ p.lifetime_secs = gSavedSettings.getS32("NearbyToastLifeTime");
+ p.fading_time_secs = gSavedSettings.getS32("NearbyToastFadingTime");
LLToast* toast = new LLToast(p);
@@ -188,6 +190,17 @@ void LLNearbyChatScreenChannel::addNotification(LLSD& notification)
return;
}
+ int chat_type = notification["chat_type"].asInteger();
+
+ if( ((EChatType)chat_type == CHAT_TYPE_DEBUG_MSG))
+ {
+ if(gSavedSettings.getBOOL("ShowScriptErrors") == FALSE)
+ return;
+ if(gSavedSettings.getS32("ShowScriptErrorsLocation")== 1)
+ return;
+ }
+
+
//take 1st element from pool, (re)initialize it, put it in active toasts
LLToast* toast = m_toast_pool.back();
@@ -315,6 +328,12 @@ void LLNearbyChatHandler::processChat(const LLChat& chat_msg)
initChannel();
}
+ //only messages from AGENTS
+ if(CHAT_SOURCE_OBJECT == chat_msg.mSourceType)
+ {
+ return;//dn't show toast for messages from objects
+ }
+
LLUUID id;
id.generate();
@@ -330,6 +349,7 @@ void LLNearbyChatHandler::processChat(const LLChat& chat_msg)
notification["from_id"] = chat_msg.mFromID;
notification["time"] = chat_msg.mTime;
notification["source"] = (S32)chat_msg.mSourceType;
+ notification["chat_type"] = (S32)chat_msg.mChatType;
channel->addNotification(notification);
}