summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Linden <none@none>2011-04-01 18:15:07 -0700
committerRichard Linden <none@none>2011-04-01 18:15:07 -0700
commit81ae3c5fc984a5175f1bd0fc277f8493dc895d94 (patch)
treed006b6327f9545f2deb71a811e20edcb2adf64cf
parent88c5554a288d1785aa391dc5ff7b7897a7a724a9 (diff)
SOCIAL-822 FIX UI and Sizing issues with hints in Basic and Advanced modes
fixed crash for advanced mode
-rw-r--r--indra/newview/llhints.cpp11
1 files changed, 6 insertions, 5 deletions
diff --git a/indra/newview/llhints.cpp b/indra/newview/llhints.cpp
index b5e676e626..e15862e2a4 100644
--- a/indra/newview/llhints.cpp
+++ b/indra/newview/llhints.cpp
@@ -217,14 +217,15 @@ void LLHintPopup::draw()
if (hint_icon)
{
- LLUIImagePtr hint_image = hint_icon.getImage();
+ LLUIImagePtr hint_image = hint_icon->getImage();
S32 image_height = hint_image.isNull() ? 0 : hint_image->getHeight();
S32 image_width = hint_image.isNull() ? 0 : hint_image->getWidth();
- S32 delta_height = image_height - hint_icon.getParent()->getParent()->getRect().getHeight();
- hint_icon.getParent()->reshape(image_width, hint_icon.getParent()->getRect().getHeight());
- hint_icon.getParent()->getParent()->reshape(hint_icon.getParent()->getParent()->getRect().getWidth(), image_height);
- hint_icon.getParent()->getParent()->translate(0, -delta_height);
+ LLView* layout_stack = hint_icon->getParent()->getParent();
+ S32 delta_height = image_height - layout_stack->getRect().getHeight();
+ hint_icon->getParent()->reshape(image_width, hint_icon->getParent()->getRect().getHeight());
+ layout_stack->reshape(layout_stack->getRect().getWidth(), image_height);
+ layout_stack->translate(0, -delta_height);
LLRect hint_rect = getLocalRect();
reshape(hint_rect.getWidth(), hint_rect.getHeight() + delta_height);