diff --git a/indra/newview/llinventorybridge.cpp b/indra/newview/llinventorybridge.cpp index d108d9ce00ca036cfe9ff16e94013cc3ee4d1b56..c2d7a0b350d27f0910c00f8bfb3dadeee8b6ade6 100644 --- a/indra/newview/llinventorybridge.cpp +++ b/indra/newview/llinventorybridge.cpp @@ -7269,13 +7269,14 @@ void LLObjectBridge::buildContextMenu(LLMenuGL& menu, U32 flags) LLViewerJointAttachment* attachment = attach_pair.second; LLMenuItemCallGL::Params p; std::string submenu_name = attachment->getName(); - if (LLTrans::getString(submenu_name) != "") + std::string translated_submenu_name; + if (LLTrans::findString(translated_submenu_name, submenu_name)) { - p.name = (" ")+LLTrans::getString(submenu_name)+" "; + p.name = attachment->getIsHUDAttachment() ? translated_submenu_name : fmt::format(FMT_STRING("{} ({})"), translated_submenu_name, attach_pair.first); } else { - p.name = submenu_name; + p.name = attachment->getIsHUDAttachment() ? submenu_name : fmt::format(FMT_STRING("{} ({})"), submenu_name, attach_pair.first); } LLSD cbparams; cbparams["index"] = attach_pair.first; diff --git a/indra/newview/llviewerattachmenu.cpp b/indra/newview/llviewerattachmenu.cpp index 261232cecdc460ace450b5f3361863ce634d5334..9946d2706ea2d0a0b4ec39cf74975c2f0d4cdc27 100644 --- a/indra/newview/llviewerattachmenu.cpp +++ b/indra/newview/llviewerattachmenu.cpp @@ -67,11 +67,11 @@ void LLViewerAttachMenu::populateMenus(const std::string& attach_to_menu_name, c if (LLTrans::findString(translated_submenu_name, submenu_name)) { - p.name = (" ") + translated_submenu_name + " "; + p.name = attachment->getIsHUDAttachment() ? translated_submenu_name : fmt::format(FMT_STRING("{} ({})"), translated_submenu_name, attach_pair.first); } else { - p.name = submenu_name; + p.name = attachment->getIsHUDAttachment() ? submenu_name : fmt::format(FMT_STRING("{} ({})"), submenu_name, attach_pair.first); } LLSD cbparams;