diff options
| author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2024-04-12 15:43:34 +0300 |
|---|---|---|
| committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2024-04-12 15:43:34 +0300 |
| commit | eab5beb54cacc2b0dc2cddad4a78634e7468a298 (patch) | |
| tree | 51f17910f529af57819bcd77f1a7dd9e92f6291e /indra/newview/llinventoryfunctions.cpp | |
| parent | 00e09ddcad8ec2c33ecbcdd0da09bd7819bc3509 (diff) | |
| parent | cc8fdf341dbbe6ab940d7b24bcf81cbed252cb69 (diff) | |
Merge branch 'main' into marchcat/x-merge
# Conflicts:
# indra/llimage/llimageworker.cpp
# indra/llimage/llimageworker.h
# indra/newview/llcontrolavatar.cpp
# indra/newview/llfloaterprofiletexture.cpp
# indra/newview/lloutfitslist.cpp
# indra/newview/lloutfitslist.h
# indra/newview/lltexturefetch.cpp
Diffstat (limited to 'indra/newview/llinventoryfunctions.cpp')
| -rw-r--r-- | indra/newview/llinventoryfunctions.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/indra/newview/llinventoryfunctions.cpp b/indra/newview/llinventoryfunctions.cpp index 4e22dd4b77..8a15281e78 100644 --- a/indra/newview/llinventoryfunctions.cpp +++ b/indra/newview/llinventoryfunctions.cpp @@ -2233,6 +2233,24 @@ void move_items_to_new_subfolder(const uuid_vec_t& selected_uuids, const std::st gInventory.createNewCategory(first_item->getParentUUID(), LLFolderType::FT_NONE, folder_name, func); } +std::string get_category_path(LLUUID cat_id) +{ + LLViewerInventoryCategory *cat = gInventory.getCategory(cat_id); + std::string localized_cat_name; + if (!LLTrans::findString(localized_cat_name, "InvFolder " + cat->getName())) + { + localized_cat_name = cat->getName(); + } + + if (cat->getParentUUID().notNull()) + { + return get_category_path(cat->getParentUUID()) + " > " + localized_cat_name; + } + else + { + return localized_cat_name; + } +} // Returns true if the item can be moved to Current Outfit or any outfit folder. bool can_move_to_outfit(LLInventoryItem* inv_item, BOOL move_is_into_current_outfit) { |
