From 5bee6f1e5e5ec9d25283ecf1815b57e5921f2c47 Mon Sep 17 00:00:00 2001 From: Mnikolenko Productengine Date: Wed, 18 May 2016 15:02:15 +0300 Subject: MAINT-6421 Inappropriate menu items are presented in gear menu when no outfit is selected in Visual Outfit Browser --- indra/newview/lloutfitgallery.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'indra/newview') diff --git a/indra/newview/lloutfitgallery.cpp b/indra/newview/lloutfitgallery.cpp index a36728e6ac..e6c41b612f 100644 --- a/indra/newview/lloutfitgallery.cpp +++ b/indra/newview/lloutfitgallery.cpp @@ -735,11 +735,12 @@ LLOutfitGalleryGearMenu::LLOutfitGalleryGearMenu(LLOutfitListBase* olist) void LLOutfitGalleryGearMenu::onUpdateItemsVisibility() { if (!mMenu) return; + bool have_selection = getSelectedOutfitID().notNull(); mMenu->setItemVisible("expand", FALSE); mMenu->setItemVisible("collapse", FALSE); - mMenu->setItemVisible("upload_photo", TRUE); - mMenu->setItemVisible("select_photo", TRUE); - mMenu->setItemVisible("take_snapshot", TRUE); + mMenu->setItemVisible("upload_photo", have_selection); + mMenu->setItemVisible("select_photo", have_selection); + mMenu->setItemVisible("take_snapshot", have_selection); LLOutfitListGearMenuBase::onUpdateItemsVisibility(); } -- cgit v1.2.3