diff options
| author | richard <none@none> | 2009-12-08 14:08:58 -0800 |
|---|---|---|
| committer | richard <none@none> | 2009-12-08 14:08:58 -0800 |
| commit | 9aa12417cba81ee1dd0bdc63041abb98091a7a95 (patch) | |
| tree | 22586cdb98633d489f78808b4dbd647115d0e3c3 /indra/llui/lltextbase.cpp | |
| parent | 00b9219367281eeec1060d4b749ddc64cb5ab343 (diff) | |
ext-3087 - avatar icon is truncated badly
reviewed by James
Diffstat (limited to 'indra/llui/lltextbase.cpp')
| -rw-r--r-- | indra/llui/lltextbase.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp index e0750968ae..f7e64aaf85 100644 --- a/indra/llui/lltextbase.cpp +++ b/indra/llui/lltextbase.cpp @@ -2207,6 +2207,12 @@ LLNormalTextSegment::LLNormalTextSegment( const LLStyleSP& style, S32 start, S32 mEditor(editor) { mFontHeight = llceil(mStyle->getFont()->getLineHeight()); + + LLUIImagePtr image = mStyle->getImage(); + if (image.notNull()) + { + mImageLoadedConnection = image->addLoadedCallback(boost::bind(&LLTextBase::needsReflow, &mEditor)); + } } LLNormalTextSegment::LLNormalTextSegment( const LLColor4& color, S32 start, S32 end, LLTextBase& editor, BOOL is_visible) @@ -2219,6 +2225,12 @@ LLNormalTextSegment::LLNormalTextSegment( const LLColor4& color, S32 start, S32 mFontHeight = llceil(mStyle->getFont()->getLineHeight()); } +LLNormalTextSegment::~LLNormalTextSegment() +{ + mImageLoadedConnection.disconnect(); +} + + F32 LLNormalTextSegment::draw(S32 start, S32 end, S32 selection_start, S32 selection_end, const LLRect& draw_rect) { if( end - start > 0 ) |
