From 9f7cfe5c5cc9476ad4cda842121fc3cb7fe8741c Mon Sep 17 00:00:00 2001 From: Rye Mutt <rye@alchemyviewer.org> Date: Sun, 7 Nov 2021 10:56:24 -0500 Subject: [PATCH] Fix inventory translation string hotspot --- indra/newview/llpanelmaininventory.cpp | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/indra/newview/llpanelmaininventory.cpp b/indra/newview/llpanelmaininventory.cpp index 3435205aaf7..4e821126eef 100644 --- a/indra/newview/llpanelmaininventory.cpp +++ b/indra/newview/llpanelmaininventory.cpp @@ -750,17 +750,23 @@ void LLPanelMainInventory::updateItemcountText() std::string text = ""; - if (LLInventoryModelBackgroundFetch::instance().folderFetchActive()) + if (LLInventoryModelBackgroundFetch::instanceFast().folderFetchActive()) { - text = getString("ItemcountFetching", string_args); + static LLUIString itemcount_fetching_str = getString("ItemcountFetching"); + itemcount_fetching_str.setArgList(string_args); + text = itemcount_fetching_str.getString(); } - else if (LLInventoryModelBackgroundFetch::instance().isEverythingFetched()) + else if (LLInventoryModelBackgroundFetch::instanceFast().isEverythingFetched()) { - text = getString("ItemcountCompleted", string_args); + static LLUIString itemcount_completed_str = getString("ItemcountCompleted"); + itemcount_completed_str.setArgList(string_args); + text = itemcount_completed_str.getString(); } else { - text = getString("ItemcountUnknown", string_args); + static LLUIString itemcount_unknown_str = getString("ItemcountUnknown"); + itemcount_unknown_str.setArgList(string_args); + text = itemcount_unknown_str.getString(); } mCounterCtrl->setValue(text); -- GitLab