diff --git a/indra/newview/llpanelplaces.cpp b/indra/newview/llpanelplaces.cpp index c2cf1416f799f7944ff38ea006b0b57022919ec9..1ded690b154bcc807ec1b9e3fadd218657fcc242 100644 --- a/indra/newview/llpanelplaces.cpp +++ b/indra/newview/llpanelplaces.cpp @@ -380,6 +380,9 @@ BOOL LLPanelPlaces::postBuild() mOptionLP = getChild<LLLayoutPanel>("lp_options"); mLayoutPanel2 = getChild<LLLayoutPanel>("lp2"); + mAddBtnPanel = getChild<LLUICtrl>("add_btn_panel"); + mTrashBtnPanel = getChild<LLUICtrl>("trash_btn_panel"); + createTabs(); updateVerbs(); @@ -663,10 +666,10 @@ void LLPanelPlaces::onTabSelected() // History panel does not support deletion nor creation // Hide menus bool supports_create = mActivePanel->getCreateMenu() != NULL; - childSetVisible("add_btn_panel", supports_create); + mAddBtnPanel->setVisible(supports_create); // favorites and inventory can remove items, history can clear history - childSetVisible("trash_btn_panel", TRUE); + mTrashBtnPanel->setVisible(TRUE); if (supports_create) { @@ -1213,10 +1216,10 @@ void LLPanelPlaces::createTabs() // History panel does not support deletion nor creation // Hide menus bool supports_create = mActivePanel->getCreateMenu() != NULL; - childSetVisible("add_btn_panel", supports_create); + mAddBtnPanel->setVisible(supports_create); // favorites and inventory can remove items, history can clear history - childSetVisible("trash_btn_panel", TRUE); + mTrashBtnPanel->setVisible(TRUE); if (supports_create) { diff --git a/indra/newview/llpanelplaces.h b/indra/newview/llpanelplaces.h index e2e62819a2f1cb4be4dbc6fb3a58a7351e9b3d97..0f342cc1700e5caa6139389e0cae885fa879a58d 100644 --- a/indra/newview/llpanelplaces.h +++ b/indra/newview/llpanelplaces.h @@ -119,6 +119,8 @@ class LLPanelPlaces : public LLPanel LLPanelLandmarkInfo* mLandmarkInfo; LLLayoutPanel* mOptionLP = nullptr; LLLayoutPanel* mLayoutPanel2 = nullptr; + LLUICtrl* mAddBtnPanel = nullptr; + LLUICtrl* mTrashBtnPanel = nullptr; LLToggleableMenu* mPlaceMenu; LLToggleableMenu* mLandmarkMenu;