summaryrefslogtreecommitdiff
path: root/indra/newview/llinventoryfunctions.cpp
diff options
context:
space:
mode:
authorMaxim Nikolenko <maximnproductengine@lindenlab.com>2023-03-30 14:09:50 +0300
committerMaxim Nikolenko <maximnproductengine@lindenlab.com>2023-03-30 14:09:50 +0300
commit198cd4df09d4d6aa9c5bbb6be9c4395d134f9f13 (patch)
treed4b87f39ab6353138594ca153ddadd5b217def00 /indra/newview/llinventoryfunctions.cpp
parente161b128c7eac6df63b6d9210f3bca6c3cbc77ea (diff)
parentc7053a6928fd5eafdc935453742e92951ae4e0c1 (diff)
Merge branch 'main' into DRTVWR-567
# Conflicts: # indra/newview/llinventoryfunctions.cpp # indra/newview/llpanelmaininventory.h # indra/newview/skins/default/xui/en/floater_inventory_item_properties.xml # indra/newview/skins/default/xui/en/sidepanel_item_info.xml
Diffstat (limited to 'indra/newview/llinventoryfunctions.cpp')
-rw-r--r--indra/newview/llinventoryfunctions.cpp16
1 files changed, 13 insertions, 3 deletions
diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp
index 548d3243e5..f24c2de714 100644
--- a/indra/newview/llinventoryfunctions.cpp
+++ b/indra/newview/llinventoryfunctions.cpp
@@ -533,6 +533,11 @@ BOOL get_is_item_worn(const LLUUID& id)
if (!item)
return FALSE;
+ if (item->getIsLinkType() && !gInventory.getItem(item->getLinkedUUID()))
+ {
+ return FALSE;
+ }
+
// Consider the item as worn if it has links in COF.
if (LLAppearanceMgr::instance().isLinkedInCOF(id))
{
@@ -813,7 +818,7 @@ void show_item_original(const LLUUID& item_uuid)
{
main_inventory->toggleViewMode();
}
- main_inventory->resetFilters();
+ main_inventory->resetAllItemsFilters();
}
reset_inventory_filter();
@@ -3003,7 +3008,12 @@ void LLInventoryAction::doToSelected(LLInventoryModel* model, LLFolderView* root
}
else
{
- std::copy(selected_uuid_set.begin(), selected_uuid_set.end(), std::back_inserter(ids));
+ for (std::set<LLFolderViewItem*>::iterator it = selected_items.begin(), end_it = selected_items.end();
+ it != end_it;
+ ++it)
+ {
+ ids.push_back(static_cast<LLFolderViewModelItemInventory*>((*it)->getViewModelItem())->getUUID());
+ }
}
// Check for actions that get handled in bulk
@@ -3064,7 +3074,7 @@ void LLInventoryAction::doToSelected(LLInventoryModel* model, LLFolderView* root
}
else if ("ungroup_folder_items" == action)
{
- if (selected_uuid_set.size() == 1)
+ if (ids.size() == 1)
{
ungroup_folder_items(*ids.begin());
}