summaryrefslogtreecommitdiff
path: root/indra/newview/llcofwearables.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview/llcofwearables.cpp')
-rw-r--r--indra/newview/llcofwearables.cpp28
1 files changed, 5 insertions, 23 deletions
diff --git a/indra/newview/llcofwearables.cpp b/indra/newview/llcofwearables.cpp
index 86d9121213..4c0f51056d 100644
--- a/indra/newview/llcofwearables.cpp
+++ b/indra/newview/llcofwearables.cpp
@@ -283,8 +283,7 @@ LLCOFWearables::LLCOFWearables() : LLPanel(),
mClothingTab(NULL),
mAttachmentsTab(NULL),
mBodyPartsTab(NULL),
- mLastSelectedTab(NULL),
- mCOFVersion(-1)
+ mLastSelectedTab(NULL)
{
mClothingMenu = new CofClothingContextMenu(this);
mAttachmentMenu = new CofAttachmentContextMenu(this);
@@ -379,23 +378,6 @@ void LLCOFWearables::onAccordionTabStateChanged(LLUICtrl* ctrl, const LLSD& expa
void LLCOFWearables::refresh()
{
- const LLUUID cof_id = LLAppearanceMgr::instance().getCOF();
- if (cof_id.isNull())
- {
- llwarns << "COF ID cannot be NULL" << llendl;
- return;
- }
-
- LLViewerInventoryCategory* catp = gInventory.getCategory(cof_id);
- if (!catp)
- {
- llwarns << "COF category cannot be NULL" << llendl;
- return;
- }
-
- if (mCOFVersion == catp->getVersion()) return;
- mCOFVersion = catp->getVersion();
-
typedef std::vector<LLSD> values_vector_t;
typedef std::map<LLFlatListView*, values_vector_t> selection_map_t;
@@ -411,7 +393,7 @@ void LLCOFWearables::refresh()
LLInventoryModel::cat_array_t cats;
LLInventoryModel::item_array_t cof_items;
- gInventory.collectDescendents(cof_id, cats, cof_items, LLInventoryModel::EXCLUDE_TRASH);
+ gInventory.collectDescendents(LLAppearanceMgr::getInstance()->getCOF(), cats, cof_items, LLInventoryModel::EXCLUDE_TRASH);
populateAttachmentsAndBodypartsLists(cof_items);
@@ -519,7 +501,7 @@ LLPanelClothingListItem* LLCOFWearables::buildClothingListItem(LLViewerInventory
item_panel->childSetAction("btn_edit", mCOFCallbacks.mEditWearable);
//turning on gray separator line for the last item in the items group of the same wearable type
- item_panel->setSeparatorVisible(last);
+ item_panel->childSetVisible("wearable_type_separator_icon", last);
return item_panel;
}
@@ -655,10 +637,10 @@ LLAssetType::EType LLCOFWearables::getExpandedAccordionAssetType()
const LLAccordionCtrlTab* expanded_tab = accordion_ctrl->getExpandedTab();
return get_if_there(mTab2AssetType, expanded_tab, LLAssetType::AT_NONE);
- }
+}
LLAssetType::EType LLCOFWearables::getSelectedAccordionAssetType()
- {
+{
static LLAccordionCtrl* accordion_ctrl = getChild<LLAccordionCtrl>("cof_wearables_accordion");
const LLAccordionCtrlTab* selected_tab = accordion_ctrl->getSelectedTab();