diff options
| author | Andrey Kleshchev <117672381+akleshchev@users.noreply.github.com> | 2026-05-26 21:51:59 +0300 |
|---|---|---|
| committer | Andrey Kleshchev <117672381+akleshchev@users.noreply.github.com> | 2026-05-29 01:52:15 +0300 |
| commit | 0a7b6a8e506bddc514deaf814abe611fc5600849 (patch) | |
| tree | c6d2ab6bcf3f20a80db9b675ee95a7d4efb2c40b /indra/newview/llinventorypanel.cpp | |
| parent | ec82c45f0ebae8c09691d09baacf5662c89d969d (diff) | |
#3729 Avoid storing inventory item names in UI outside of debug
Diffstat (limited to 'indra/newview/llinventorypanel.cpp')
| -rw-r--r-- | indra/newview/llinventorypanel.cpp | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/indra/newview/llinventorypanel.cpp b/indra/newview/llinventorypanel.cpp index 0a6c95f309..301a0a0cc9 100644 --- a/indra/newview/llinventorypanel.cpp +++ b/indra/newview/llinventorypanel.cpp @@ -1063,7 +1063,18 @@ LLFolderViewFolder * LLInventoryPanel::createFolderViewFolder(LLInvFVBridge * br { LLFolderViewFolder::Params params(mParams.folder); - params.name = bridge->getDisplayName(); +#ifndef LL_RELEASE_FOR_DOWNLOAD + // Only usable for debug and first call has a large + // overhead from search string construction. + // As inventory names aren't unique and can change, + // there is little we can use them for in release builds. + params.name = bridge->getName(); +#else + // We don't have a source of unique names and inventory + // items can reach millions in quantity, just use + // a short descriptor + params.name = "fld"; +#endif params.root = mFolderRoot.get(); params.listener = bridge; params.allow_drop = allow_drop; @@ -1078,7 +1089,19 @@ LLFolderViewItem * LLInventoryPanel::createFolderViewItem(LLInvFVBridge * bridge { LLFolderViewItem::Params params(mParams.item); - params.name = bridge->getDisplayName(); +#ifndef LL_RELEASE_FOR_DOWNLOAD + // Only usable for debug and first call has a large + // overhead from search string construction. + // As inventory names aren't unique, are large and can change, + // there is little we can use them for in release builds. + // Prefer shorter + params.name = bridge->getName(); +#else + // We don't have a source of unique names and inventory + // items can reach millions in quantity, just use + // a short descriptor + params.name = "itm"; +#endif params.creation_date = bridge->getCreationDate(); params.root = mFolderRoot.get(); params.listener = bridge; |
