summaryrefslogtreecommitdiff
path: root/indra/newview/llavatarlistitem.cpp
diff options
context:
space:
mode:
authorDmitry Zaporozhan <dzaporozhan@productengine.com>2009-11-16 12:33:52 +0200
committerDmitry Zaporozhan <dzaporozhan@productengine.com>2009-11-16 12:33:52 +0200
commit471897cfabbfec8d4dbee65c837d5884310ea61a (patch)
treed9ef29f52786b380bd3d496c1f5a258aefeeb772 /indra/newview/llavatarlistitem.cpp
parentd149b28173c2b255bd1bf1db902368dfbdf3064a (diff)
parente7519e8a977138627b429ca43a10184c82efc66e (diff)
Merge
--HG-- branch : product-engine
Diffstat (limited to 'indra/newview/llavatarlistitem.cpp')
-rw-r--r--indra/newview/llavatarlistitem.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/indra/newview/llavatarlistitem.cpp b/indra/newview/llavatarlistitem.cpp
index 7df278d887..c670a65bcc 100644
--- a/indra/newview/llavatarlistitem.cpp
+++ b/indra/newview/llavatarlistitem.cpp
@@ -311,3 +311,18 @@ void LLAvatarListItem::onNameCache(const std::string& first_name, const std::str
mAvatarName->setValue(name);
mAvatarName->setToolTip(name);
}
+
+void LLAvatarListItem::reshapeAvatarName()
+{
+ S32 width_delta = 0;
+ width_delta += mShowProfileBtn ? mProfileBtnWidth : 0;
+ width_delta += mSpeakingIndicator->getVisible() ? mSpeakingIndicatorWidth : 0;
+ width_delta += mAvatarIcon->getVisible() ? mIconWidth : 0;
+ width_delta += mShowInfoBtn ? mInfoBtnWidth : 0;
+ width_delta += mLastInteractionTime->getVisible() ? mLastInteractionTime->getRect().getWidth() : 0;
+
+ S32 height = mAvatarName->getRect().getHeight();
+ S32 width = getRect().getWidth() - width_delta;
+
+ mAvatarName->reshape(width, height);
+}