Skip to content
Snippets Groups Projects
Commit 1d326691 authored by andreykproductengine's avatar andreykproductengine
Browse files

MAINT-8742 Crashes at draw and getHandle

parent 1b236217
Branches
Tags
No related merge requests found
...@@ -528,10 +528,24 @@ class LLChatHistoryHeader: public LLPanel ...@@ -528,10 +528,24 @@ class LLChatHistoryHeader: public LLPanel
registrar_enable.add("ObjectIcon.Visible", boost::bind(&LLChatHistoryHeader::onObjectIconContextMenuItemVisible, this, _2)); registrar_enable.add("ObjectIcon.Visible", boost::bind(&LLChatHistoryHeader::onObjectIconContextMenuItemVisible, this, _2));
LLMenuGL* menu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>("menu_avatar_icon.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance()); LLMenuGL* menu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>("menu_avatar_icon.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance());
if (menu)
{
mPopupMenuHandleAvatar = menu->getHandle(); mPopupMenuHandleAvatar = menu->getHandle();
}
else
{
LL_WARNS() << " Failed to create menu_avatar_icon.xml" << LL_ENDL;
}
menu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>("menu_object_icon.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance()); menu = LLUICtrlFactory::getInstance()->createFromFile<LLMenuGL>("menu_object_icon.xml", gMenuHolder, LLViewerMenuHolderGL::child_registry_t::instance());
if (menu)
{
mPopupMenuHandleObject = menu->getHandle(); mPopupMenuHandleObject = menu->getHandle();
}
else
{
LL_WARNS() << " Failed to create menu_object_icon.xml" << LL_ENDL;
}
setDoubleClickCallback(boost::bind(&LLChatHistoryHeader::showInspector, this)); setDoubleClickCallback(boost::bind(&LLChatHistoryHeader::showInspector, this));
...@@ -619,7 +633,12 @@ class LLChatHistoryHeader: public LLPanel ...@@ -619,7 +633,12 @@ class LLChatHistoryHeader: public LLPanel
} }
mUserNameFont = style_params.font(); mUserNameFont = style_params.font();
LLTextBox* user_name = getChild<LLTextBox>("user_name"); if (!mUserNameTextBox)
{
mUserNameTextBox = getChild<LLTextBox>("user_name");
mTimeBoxTextBox = getChild<LLTextBox>("time_box");
}
LLTextBox* user_name = mUserNameTextBox;
user_name->setReadOnlyColor(style_params.readonly_color()); user_name->setReadOnlyColor(style_params.readonly_color());
user_name->setColor(style_params.color()); user_name->setColor(style_params.color());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment