summaryrefslogtreecommitdiff
path: root/indra/newview/llconversationmodel.cpp
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2012-09-28 17:30:18 -0700
committerMerov Linden <merov@lindenlab.com>2012-09-28 17:30:18 -0700
commit7fc33cc47fdc080bbc7674cf118011b689ba1485 (patch)
tree5c5a74d7cfd06c23ee97ede9ad65011701624746 /indra/newview/llconversationmodel.cpp
parent166ff2b1b8dc21ad1a88c715a480ce1d2c5c2e07 (diff)
CHUI-367 : Completed : Show user name tooltip in all situations so to avoid the conversation name showing up
Diffstat (limited to 'indra/newview/llconversationmodel.cpp')
-rw-r--r--indra/newview/llconversationmodel.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/indra/newview/llconversationmodel.cpp b/indra/newview/llconversationmodel.cpp
index 176c05248d..9fa8758d11 100644
--- a/indra/newview/llconversationmodel.cpp
+++ b/indra/newview/llconversationmodel.cpp
@@ -36,7 +36,6 @@
LLConversationItem::LLConversationItem(std::string display_name, const LLUUID& uuid, LLFolderViewModelInterface& root_view_model) :
LLFolderViewModelItemCommon(root_view_model),
mName(display_name),
- mUseNameForSort(true),
mUUID(uuid),
mNeedsRefresh(true),
mConvType(CONV_UNKNOWN),
@@ -47,7 +46,6 @@ LLConversationItem::LLConversationItem(std::string display_name, const LLUUID& u
LLConversationItem::LLConversationItem(const LLUUID& uuid, LLFolderViewModelInterface& root_view_model) :
LLFolderViewModelItemCommon(root_view_model),
mName(""),
- mUseNameForSort(true),
mUUID(uuid),
mNeedsRefresh(true),
mConvType(CONV_UNKNOWN),
@@ -58,7 +56,6 @@ LLConversationItem::LLConversationItem(const LLUUID& uuid, LLFolderViewModelInte
LLConversationItem::LLConversationItem(LLFolderViewModelInterface& root_view_model) :
LLFolderViewModelItemCommon(root_view_model),
mName(""),
- mUseNameForSort(true),
mUUID(),
mNeedsRefresh(true),
mConvType(CONV_UNKNOWN),
@@ -254,9 +251,8 @@ LLConversationItemParticipant::LLConversationItemParticipant(const LLUUID& uuid,
void LLConversationItemParticipant::onAvatarNameCache(const LLAvatarName& av_name)
{
- mUseNameForSort = !av_name.mUsername.empty();
- mName = (mUseNameForSort ? av_name.mUsername : NO_TOOLTIP_STRING);
- mDisplayName = (av_name.mDisplayName.empty() ? mName : av_name.mDisplayName);
+ mName = (av_name.mUsername.empty() ? av_name.mDisplayName : av_name.mUsername);
+ mDisplayName = (av_name.mDisplayName.empty() ? av_name.mUsername : av_name.mDisplayName);
mNeedsRefresh = true;
if (mParent)
{
@@ -367,7 +363,7 @@ bool LLConversationSort::operator()(const LLConversationItem* const& a, const LL
}
// By default, in all other possible cases (including sort order type LLConversationFilter::SO_NAME of course),
// we sort by name
- S32 compare = LLStringUtil::compareDict((a->useNameForSort() ? a->getName() : a->getDisplayName()), (b->useNameForSort() ? b->getName() : b->getDisplayName()));
+ S32 compare = LLStringUtil::compareDict(a->getName(), b->getName());
return (compare < 0);
}