Show translator name in credits page
This commit is contained in:
parent
7dc0e2b859
commit
d6810e36b6
@ -98,6 +98,7 @@
|
||||
"WeatherIDText": "Sets weather by IDs (0-255). Don't touch unless you know what you're doing!"
|
||||
},
|
||||
"Main": {
|
||||
"Translator" : "Translator",
|
||||
"TranslationLanguage": "English",
|
||||
"TranslationLanguageDisclaimer": "Translated to English by Grinch_",
|
||||
"TranslatorName": "Grinch_"
|
||||
|
@ -2,7 +2,7 @@
|
||||
#include "locale.h"
|
||||
#include <filesystem>
|
||||
|
||||
Locale::eReturnCodes Locale::Init(const char* path, const char* def, const char* callback)
|
||||
Locale::eReturnCodes Locale::Init(const char* path, const char* def, const char* fallback)
|
||||
{
|
||||
std::string localePath = path;
|
||||
if (localePath.back() != '/')
|
||||
@ -42,7 +42,7 @@ Locale::eReturnCodes Locale::Init(const char* path, const char* def, const char*
|
||||
#endif
|
||||
m_locales.push_back(fileName);
|
||||
|
||||
if (!strcmp(callback, fileName.c_str()))
|
||||
if (!strcmp(fallback, fileName.c_str()))
|
||||
{
|
||||
std::string localePath = m_path + fileName + ".json";
|
||||
|
||||
|
@ -36,7 +36,7 @@ public:
|
||||
Loads json files from the locale directory
|
||||
Calling it multiple times will unload previous data
|
||||
*/
|
||||
static eReturnCodes Init(const char* path, const char* def = "English", const char* callback = "");
|
||||
static eReturnCodes Init(const char* path, const char* def = "English", const char* fallback = "");
|
||||
|
||||
// Returns a vector of available languages
|
||||
static std::vector<std::string>& GetLocaleList();
|
||||
|
@ -672,6 +672,12 @@ void Menu::ShowPage()
|
||||
ImGui::TableNextColumn();
|
||||
ImGui::Text("MinHook");
|
||||
|
||||
ImGui::TableNextRow();
|
||||
ImGui::TableNextColumn();
|
||||
ImGui::Text(TEXT("Menu.TranslatorName"));
|
||||
ImGui::TableNextColumn();
|
||||
ImGui::Text(TEXT("Menu.Translator"));
|
||||
|
||||
ImGui::EndTable();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user