summaryrefslogtreecommitdiff
path: root/indra/newview/llchathistory.cpp
diff options
context:
space:
mode:
authorLeyla Farazha <leyla@lindenlab.com>2010-06-21 10:21:52 -0700
committerLeyla Farazha <leyla@lindenlab.com>2010-06-21 10:21:52 -0700
commitc8970618567e867b619c9fb5e225978bc5f66781 (patch)
treed5ec9d2f27d887e9a39b1109469ca405b14c6a85 /indra/newview/llchathistory.cpp
parent6be9f280ff5b2e2eba3bb9c3f14d7166579d1a49 (diff)
parenta069e0d3db0e0771e54768a702fa18e57415992e (diff)
Merge with q/viewer-release
Diffstat (limited to 'indra/newview/llchathistory.cpp')
-rw-r--r--indra/newview/llchathistory.cpp9
1 files changed, 7 insertions, 2 deletions
diff --git a/indra/newview/llchathistory.cpp b/indra/newview/llchathistory.cpp
index b7bccf46be..4309d43498 100644
--- a/indra/newview/llchathistory.cpp
+++ b/indra/newview/llchathistory.cpp
@@ -256,7 +256,7 @@ public:
mSourceType = chat.mSourceType;
//*TODO overly defensive thing, source type should be maintained out there
- if((chat.mFromID.isNull() && chat.mFromName.empty()) || chat.mFromName == SYSTEM_FROM)
+ if((chat.mFromID.isNull() && chat.mFromName.empty()) || chat.mFromName == SYSTEM_FROM && chat.mFromID.isNull())
{
mSourceType = CHAT_SOURCE_SYSTEM;
}
@@ -605,6 +605,11 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL
{
bool use_plain_text_chat_history = args["use_plain_text_chat_history"].asBoolean();
+ if(mEditor)
+ {
+ mEditor->setPlainText(use_plain_text_chat_history);
+ }
+
if (!mEditor->scrolledToEnd() && chat.mFromID != gAgent.getID() && !chat.mFromName.empty())
{
mUnreadChatSources.insert(chat.mFromName);
@@ -715,7 +720,7 @@ void LLChatHistory::appendMessage(const LLChat& chat, const LLSD &args, const LL
// (don't let object names with hyperlinks override our objectim Url)
LLStyle::Params link_params(style_params);
link_params.color.control = "HTMLLinkColor";
- link_params.link_href = url;
+ link_params.link_href = LLURI::escape(url);
mEditor->appendText("<nolink>" + chat.mFromName + "</nolink>" + delimiter,
false, link_params);
}