diff options
author | Sergei Litovchuk <slitovchuk@productengine.com> | 2010-04-29 20:11:58 +0300 |
---|---|---|
committer | Sergei Litovchuk <slitovchuk@productengine.com> | 2010-04-29 20:11:58 +0300 |
commit | 20d95dd5235117593766a9e5b9ab84ee7b2c0abc (patch) | |
tree | b6f7b9a56248e7b327c3716adb5de527c483b6f4 /indra/newview/llpaneloutfitsinventory.cpp | |
parent | 02d6922727bd674025759a95df15a1f764b784fd (diff) |
(EXT-6722) Create modified inventory view for "my outfits" tab in top-level appearance sidebar (tier 2)
llui:
- Added accordion tab title setter.
- Added setters for accordion tab focus changes callbacks.
newview:
- Fixed observer used for outfit items collecting. Added checking number of fetched items.
- Added outfit selection and enabled "replace outfit" and "add to outfit" commands for selected outfit.
Reviewed by Mike Antipov https://codereview.productengine.com/secondlife/r/332/
--HG--
branch : product-engine
Diffstat (limited to 'indra/newview/llpaneloutfitsinventory.cpp')
-rw-r--r-- | indra/newview/llpaneloutfitsinventory.cpp | 30 |
1 files changed, 24 insertions, 6 deletions
diff --git a/indra/newview/llpaneloutfitsinventory.cpp b/indra/newview/llpaneloutfitsinventory.cpp index 789e85b46f..80964938f5 100644 --- a/indra/newview/llpaneloutfitsinventory.cpp +++ b/indra/newview/llpaneloutfitsinventory.cpp @@ -188,19 +188,37 @@ void LLPanelOutfitsInventory::onSearchEdit(const std::string& string) void LLPanelOutfitsInventory::onWearButtonClick() { - LLFolderViewEventListener* listenerp = getCorrectListenerForAction(); - if (listenerp) + // TODO: Remove if/else, add common interface + // for "My Outfits" and "Wearing" tabs. + if (!isCOFPanelActive()) + { + mMyOutfitsPanel->performAction("replaceoutfit"); + } + else { - listenerp->performAction(NULL, "replaceoutfit"); + LLFolderViewEventListener* listenerp = getCorrectListenerForAction(); + if (listenerp) + { + listenerp->performAction(NULL, "replaceoutfit"); + } } } void LLPanelOutfitsInventory::onAdd() { - LLFolderViewEventListener* listenerp = getCorrectListenerForAction(); - if (listenerp) + // TODO: Remove if/else, add common interface + // for "My Outfits" and "Wearing" tabs. + if (!isCOFPanelActive()) + { + mMyOutfitsPanel->performAction("addtooutfit"); + } + else { - listenerp->performAction(NULL, "addtooutfit"); + LLFolderViewEventListener* listenerp = getCorrectListenerForAction(); + if (listenerp) + { + listenerp->performAction(NULL, "addtooutfit"); + } } } |