From fcb3b6917c852779a846673bd8b35cdc2fda6bb7 Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Tue, 19 Jul 2022 18:56:59 +0300 Subject: SL-17670 Simplify outfit snapshot floater --- indra/newview/llfloatersnapshot.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'indra/newview/llfloatersnapshot.cpp') diff --git a/indra/newview/llfloatersnapshot.cpp b/indra/newview/llfloatersnapshot.cpp index 83212230e5..6b9d4580dc 100644 --- a/indra/newview/llfloatersnapshot.cpp +++ b/indra/newview/llfloatersnapshot.cpp @@ -176,16 +176,20 @@ void LLFloaterSnapshotBase::ImplBase::updateLayout(LLFloaterSnapshotBase* floate LLUICtrl* thumbnail_placeholder = floaterp->getChild("thumbnail_placeholder"); thumbnail_placeholder->setVisible(mAdvanced); - thumbnail_placeholder->reshape(panel_width, thumbnail_placeholder->getRect().getHeight()); + floaterp->getChild("image_res_text")->setVisible(mAdvanced); floaterp->getChild("file_size_label")->setVisible(mAdvanced); if (floaterp->hasChild("360_label", TRUE)) { floaterp->getChild("360_label")->setVisible(mAdvanced); } - if(!floaterp->isMinimized()) + if (!mSkipReshaping) { - floaterp->reshape(floater_width, floaterp->getRect().getHeight()); + thumbnail_placeholder->reshape(panel_width, thumbnail_placeholder->getRect().getHeight()); + if (!floaterp->isMinimized()) + { + floaterp->reshape(floater_width, floaterp->getRect().getHeight()); + } } bool use_freeze_frame = floaterp->getChild("freeze_frame_check")->getValue().asBoolean(); @@ -1193,7 +1197,7 @@ S32 LLFloaterSnapshotBase::notify(const LLSD& info) // The refresh button is initially hidden. We show it after the first update, // i.e. when preview appears. - if (!mRefreshBtn->getVisible()) + if (mRefreshBtn && !mRefreshBtn->getVisible()) { mRefreshBtn->setVisible(true); } -- cgit v1.2.3