summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorpavelkproductengine <pavelkproductengine@lindenlab.com>2017-04-20 16:55:14 +0300
committerpavelkproductengine <pavelkproductengine@lindenlab.com>2017-04-20 16:55:14 +0300
commit0d5b8358401bc62feae5cbfad002dd4378bfe4a6 (patch)
tree69a2839daca4a062a2c7ef3364e24b1318ca6733 /indra/newview
parentc995dcdbf301bd3de5d8166fbb76b9835c46bbb3 (diff)
MAINT-6477 VOB - Click on an outfit folder from Outfit Gallery tab does not open folder or enlarge image
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/lloutfitgallery.cpp30
-rw-r--r--indra/newview/lloutfitgallery.h3
-rw-r--r--indra/newview/lloutfitslist.cpp2
3 files changed, 34 insertions, 1 deletions
diff --git a/indra/newview/lloutfitgallery.cpp b/indra/newview/lloutfitgallery.cpp
index eeeb7e5c25..31e89c0ed0 100644
--- a/indra/newview/lloutfitgallery.cpp
+++ b/indra/newview/lloutfitgallery.cpp
@@ -34,6 +34,7 @@
#include "llcommonutils.h"
#include "llvfile.h"
+#include "llaccordionctrltab.h"
#include "llappearancemgr.h"
#include "lleconomy.h"
#include "llerror.h"
@@ -46,6 +47,8 @@
#include "llinventorymodel.h"
#include "lllocalbitmaps.h"
#include "llnotificationsutil.h"
+#include "llpaneloutfitsinventory.h"
+#include "lltabcontainer.h"
#include "lltexturectrl.h"
#include "lltrans.h"
#include "llviewercontrol.h"
@@ -742,6 +745,33 @@ BOOL LLOutfitGalleryItem::handleRightMouseDown(S32 x, S32 y, MASK mask)
return LLUICtrl::handleRightMouseDown(x, y, mask);
}
+BOOL LLOutfitGallery::handleDoubleClick(S32 x, S32 y, MASK mask)
+{
+ LLTabContainer* appearence_tabs = LLPanelOutfitsInventory::findInstance()->getChild<LLTabContainer>("appearance_tabs");
+ LLPanel* panel = NULL;
+ LLAccordionCtrl* accordion = NULL;
+ if (appearence_tabs != NULL)
+ {
+ appearence_tabs->selectTabByName("outfitslist_tab");
+ panel = appearence_tabs->getCurrentPanel();
+ if (panel != NULL)
+ {
+ accordion = panel->getChild<LLAccordionCtrl>("outfits_accordion");
+ LLOutfitsList* outfit_list = dynamic_cast<LLOutfitsList*>(panel);
+ if (accordion != NULL && outfit_list != NULL)
+ {
+ LLUUID item_id = getSelectedOutfitUUID();
+ outfit_list->setSelectedOutfitByUUID(item_id);
+ LLAccordionCtrlTab* tab = accordion->getSelectedTab();
+ tab->showAndFocusHeader();
+ return TRUE;
+ }
+ }
+ }
+
+ return LLUICtrl::handleDoubleClick(x, y, mask);
+}
+
void LLOutfitGalleryItem::setImageAssetId(LLUUID image_asset_id)
{
mImageAssetId = image_asset_id;
diff --git a/indra/newview/lloutfitgallery.h b/indra/newview/lloutfitgallery.h
index b9fc10f015..37e75f1109 100644
--- a/indra/newview/lloutfitgallery.h
+++ b/indra/newview/lloutfitgallery.h
@@ -114,6 +114,9 @@ public:
void onTexturePickerUpdateImageStats(LLPointer<LLViewerTexture> texture);
void onBeforeOutfitSnapshotSave();
void onAfterOutfitSnapshotSave();
+
+ /*virtual*/ BOOL handleDoubleClick(S32 x, S32 y, MASK mask);
+
protected:
/*virtual*/ void onHighlightBaseOutfit(LLUUID base_id, LLUUID prev_id);
/*virtual*/ void onSetSelectedOutfitByUUID(const LLUUID& outfit_uuid);
diff --git a/indra/newview/lloutfitslist.cpp b/indra/newview/lloutfitslist.cpp
index e1f51e62e3..f87ce8aa52 100644
--- a/indra/newview/lloutfitslist.cpp
+++ b/indra/newview/lloutfitslist.cpp
@@ -311,7 +311,7 @@ void LLOutfitsList::onSetSelectedOutfitByUUID(const LLUUID& outfit_uuid)
tab->setFocus(TRUE);
ChangeOutfitSelection(list, outfit_uuid);
- tab->setDisplayChildren(true);
+ tab->changeOpenClose(false);
}
}
}