summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorMerov Linden <merov@lindenlab.com>2014-02-07 11:31:04 -0800
committerMerov Linden <merov@lindenlab.com>2014-02-07 11:31:04 -0800
commitd7f5afdc5dbbc5f2b9da031322d9e24669978c46 (patch)
tree1e22684513fde152c6f0564357d1a5b36b8e8f7a /indra
parent36c1775828fb69fa5e5c3abb9c3eaeedbe15c847 (diff)
ACME-1312 : Show the filter name without the Missing string prefix for filters that are not localized
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llimagefiltersmanager.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/indra/newview/llimagefiltersmanager.cpp b/indra/newview/llimagefiltersmanager.cpp
index 0633dcaefc..ee6b39efac 100644
--- a/indra/newview/llimagefiltersmanager.cpp
+++ b/indra/newview/llimagefiltersmanager.cpp
@@ -74,10 +74,14 @@ void LLImageFiltersManager::loadFiltersFromDir(const std::string& dir)
}
// Get the ".xml" out of the file name to get the filter name. That's the one known in strings.xml
- std::string filter_name = file_name.substr(0,file_name.length()-4);
+ std::string filter_name_untranslated = file_name.substr(0,file_name.length()-4);
+
// Get the localized name for the filter
- filter_name = LLTrans::getString(filter_name);
+ std::string filter_name_translated;
+ bool translated = LLTrans::findString(filter_name_translated, filter_name_untranslated);
+ std::string filter_name = (translated ? filter_name_translated: filter_name_untranslated);
+ // Store the filter in the list with its associated file name
mFiltersList[filter_name] = file_name;
}
}