Skip to content
Snippets Groups Projects
Commit 16da0b8c authored by Igor Borovkov's avatar Igor Borovkov
Browse files

EXT-7205 FIXED reversed displaying order of clothing items of the same type in panel outfit edit

- reversed iterating order
- switched up/down buttons' callbacks

Reviewed by Vadim Savchuk at https://codereview.productengine.com/secondlife/r/359/

--HG--
branch : product-engine
parent 561151b1
No related branches found
No related tags found
No related merge requests found
...@@ -199,8 +199,8 @@ LLPanelClothingListItem* LLCOFWearables::buildClothingListItem(LLViewerInventory ...@@ -199,8 +199,8 @@ LLPanelClothingListItem* LLCOFWearables::buildClothingListItem(LLViewerInventory
//setting callbacks //setting callbacks
//*TODO move that item panel's inner structure disclosing stuff into the panels //*TODO move that item panel's inner structure disclosing stuff into the panels
item_panel->childSetAction("btn_delete", mCOFCallbacks.mDeleteWearable); item_panel->childSetAction("btn_delete", mCOFCallbacks.mDeleteWearable);
item_panel->childSetAction("btn_move_up", mCOFCallbacks.mMoveWearableCloser); item_panel->childSetAction("btn_move_up", mCOFCallbacks.mMoveWearableFurther);
item_panel->childSetAction("btn_move_down", mCOFCallbacks.mMoveWearableFurther); item_panel->childSetAction("btn_move_down", mCOFCallbacks.mMoveWearableCloser);
item_panel->childSetAction("btn_edit", mCOFCallbacks.mEditWearable); 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 //turning on gray separator line for the last item in the items group of the same wearable type
...@@ -243,11 +243,12 @@ void LLCOFWearables::populateClothingList(LLAppearanceMgr::wearables_by_type_t& ...@@ -243,11 +243,12 @@ void LLCOFWearables::populateClothingList(LLAppearanceMgr::wearables_by_type_t&
LLAppearanceMgr::sortItemsByActualDescription(clothing_by_type[type]); LLAppearanceMgr::sortItemsByActualDescription(clothing_by_type[type]);
for (U32 i = 0; i < size; i++) //clothing items are displayed in reverse order, from furthest ones to closest ones (relatively to the body)
for (U32 i = size; i != 0; --i)
{ {
LLViewerInventoryItem* item = clothing_by_type[type][i]; LLViewerInventoryItem* item = clothing_by_type[type][i-1];
LLPanelClothingListItem* item_panel = buildClothingListItem(item, i == 0, i == size - 1); LLPanelClothingListItem* item_panel = buildClothingListItem(item, i == size, i == 1);
if (!item_panel) continue; if (!item_panel) continue;
mClothing->addItem(item_panel, item->getUUID(), ADD_BOTTOM, false); mClothing->addItem(item_panel, item->getUUID(), ADD_BOTTOM, false);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment