summaryrefslogtreecommitdiff
path: root/indra/newview/llavatarlistitem.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llavatarlistitem.cpp')
-rw-r--r--indra/newview/llavatarlistitem.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/indra/newview/llavatarlistitem.cpp b/indra/newview/llavatarlistitem.cpp
index a7ac14c948..7df278d887 100644
--- a/indra/newview/llavatarlistitem.cpp
+++ b/indra/newview/llavatarlistitem.cpp
@@ -62,6 +62,7 @@ LLAvatarListItem::LLAvatarListItem()
mIconWidth = mAvatarName->getRect().mLeft - mAvatarIcon->getRect().mLeft;
mInfoBtnWidth = mInfoBtn->getRect().mRight - mSpeakingIndicator->getRect().mRight;
mProfileBtnWidth = mProfileBtn->getRect().mRight - mInfoBtn->getRect().mRight;
+ mSpeakingIndicatorWidth = mSpeakingIndicator->getRect().mRight - mAvatarName->getRect().mRight;
}
LLAvatarListItem::~LLAvatarListItem()
@@ -230,6 +231,18 @@ void LLAvatarListItem::setShowProfileBtn(bool show)
mAvatarName->reshape(mAvatarName->getRect().getWidth() + width_delta, mAvatarName->getRect().getHeight());
}
+void LLAvatarListItem::setSpeakingIndicatorVisible(bool visible)
+{
+ // Already done? Then do nothing.
+ if (mSpeakingIndicator->getVisible() == (BOOL)visible)
+ return;
+ mSpeakingIndicator->setVisible(visible);
+ S32 width_delta = visible ? - mSpeakingIndicatorWidth : mSpeakingIndicatorWidth;
+
+ //Reshaping avatar name
+ mAvatarName->reshape(mAvatarName->getRect().getWidth() + width_delta, mAvatarName->getRect().getHeight());
+}
+
void LLAvatarListItem::setAvatarIconVisible(bool visible)
{
// Already done? Then do nothing.