Skip to content
Snippets Groups Projects
Commit f22e5df8 authored by Seth ProductEngine's avatar Seth ProductEngine
Browse files

CHUI-172 WIP Fixed drawing the nearby chat toast contents.

Fixed warnings when creating a nearby chat toast.
parent cd7d499e
No related branches found
No related tags found
No related merge requests found
......@@ -96,8 +96,15 @@ void LLNearbyChatToastPanel::reshape (S32 width, S32 height, BOOL called_from_p
{
LLPanel::reshape(width, height,called_from_parent);
LLUICtrl* msg_text = getChild<LLUICtrl>("msg_text", false);
LLUICtrl* icon = getChild<LLUICtrl>("avatar_icon", false);
// reshape() may be called from LLView::initFromParams() before the children are created.
// We call findChild() instead of getChild() here to avoid creating dummy controls.
LLUICtrl* msg_text = findChild<LLUICtrl>("msg_text", false);
LLUICtrl* icon = findChild<LLUICtrl>("avatar_icon", false);
if (!msg_text || !icon)
{
return;
}
LLRect msg_text_rect = msg_text->getRect();
LLRect avatar_rect = icon->getRect();
......@@ -355,6 +362,8 @@ BOOL LLNearbyChatToastPanel::handleRightMouseDown(S32 x, S32 y, MASK mask)
}
void LLNearbyChatToastPanel::draw()
{
LLPanel::draw();
if(mIsDirty)
{
LLAvatarIconCtrl* icon = getChild<LLAvatarIconCtrl>("avatar_icon", false);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment