summaryrefslogtreecommitdiff
path: root/indra/newview/llimview.cpp
diff options
context:
space:
mode:
authormaxim_productengine <mnikolenko@productengine.com>2019-08-21 16:22:43 +0300
committermaxim_productengine <mnikolenko@productengine.com>2019-08-21 16:22:43 +0300
commit9773e06cc12b432772eda856c5281c749caec988 (patch)
tree9d600cf2d5af2993a6272df1c5f048e41a0c5451 /indra/newview/llimview.cpp
parent99a4bd23dadbdaf8e82ceca26af531c93d5fd4a6 (diff)
SL-11753 FIXED Group & Resident with the same name share chat history.
Diffstat (limited to 'indra/newview/llimview.cpp')
-rw-r--r--indra/newview/llimview.cpp11
1 files changed, 10 insertions, 1 deletions
diff --git a/indra/newview/llimview.cpp b/indra/newview/llimview.cpp
index 0f5d514660..c07064389b 100644
--- a/indra/newview/llimview.cpp
+++ b/indra/newview/llimview.cpp
@@ -848,7 +848,7 @@ void LLIMModel::LLIMSession::loadHistory()
std::list<LLSD> chat_history;
//involves parsing of a chat history
- LLLogChat::loadChatHistory(mHistoryFileName, chat_history);
+ LLLogChat::loadChatHistory(mHistoryFileName, chat_history, LLSD(), isGroupChat());
addMessagesFromHistory(chat_history);
}
}
@@ -912,6 +912,11 @@ bool LLIMModel::LLIMSession::isP2P()
return IM_NOTHING_SPECIAL == mType;
}
+bool LLIMModel::LLIMSession::isGroupChat()
+{
+ return IM_SESSION_GROUP_START == mType || (IM_SESSION_INVITE == mType && gAgent.isInGroup(mSessionID));
+}
+
bool LLIMModel::LLIMSession::isOtherParticipantAvaline()
{
return !mOtherParticipantIsAvatar;
@@ -969,6 +974,10 @@ void LLIMModel::LLIMSession::buildHistoryFileName()
mHistoryFileName = LLCacheName::buildUsername(mName);
}
}
+ else if (isGroupChat())
+ {
+ mHistoryFileName = mName + GROUP_CHAT_SUFFIX;
+ }
}
//static