Host: Backport translations cache
Note: You'll need a new command line for lupdate. ..\..\..\dep\msvc\qt\6.5.0\msvc2022_64\bin\lupdate.exe ../ ../../core/ ../../util/ -tr-function-alias QT_TRANSLATE_NOOP+=TRANSLATE,QT_TRANSLATE_NOOP+=TRANSLATE_SV,QT_TRANSLATE_NOOP+=TRANSLATE_STR,QT_TRANSLATE_NOOP+=TRANSLATE_FS,QT_TRANSLATE_N_NOOP3+=TRANSLATE_FMT,QT_TRANSLATE_NOOP+=TRANSLATE_NOOP -ts duckstation-qt_LANGUAGE.ts
This commit is contained in:
@ -681,13 +681,13 @@ void SaveStateSelectorUI::RefreshHotkeyLegend()
|
||||
};
|
||||
|
||||
s_load_legend = format_legend_entry(Host::GetStringSettingValue("Hotkeys", "LoadSelectedSaveState"),
|
||||
Host::TranslateStdString("SaveStateSelectorUI", "Load"));
|
||||
TRANSLATE_STR("SaveStateSelectorUI", "Load"));
|
||||
s_save_legend = format_legend_entry(Host::GetStringSettingValue("Hotkeys", "SaveSelectedSaveState"),
|
||||
Host::TranslateStdString("SaveStateSelectorUI", "Save"));
|
||||
TRANSLATE_STR("SaveStateSelectorUI", "Save"));
|
||||
s_prev_legend = format_legend_entry(Host::GetStringSettingValue("Hotkeys", "SelectPreviousSaveStateSlot"),
|
||||
Host::TranslateStdString("SaveStateSelectorUI", "Select Previous"));
|
||||
TRANSLATE_STR("SaveStateSelectorUI", "Select Previous"));
|
||||
s_next_legend = format_legend_entry(Host::GetStringSettingValue("Hotkeys", "SelectNextSaveStateSlot"),
|
||||
Host::TranslateStdString("SaveStateSelectorUI", "Select Next"));
|
||||
TRANSLATE_STR("SaveStateSelectorUI", "Select Next"));
|
||||
}
|
||||
|
||||
void SaveStateSelectorUI::SelectNextSlot()
|
||||
@ -744,7 +744,7 @@ void SaveStateSelectorUI::InitializeListEntry(ListEntry* li, ExtendedSaveStateIn
|
||||
|
||||
void SaveStateSelectorUI::InitializePlaceholderListEntry(ListEntry* li, std::string path, s32 slot, bool global)
|
||||
{
|
||||
li->title = Host::TranslateStdString("SaveStateSelectorUI", "No Save State");
|
||||
li->title = TRANSLATE_STR("SaveStateSelectorUI", "No Save State");
|
||||
std::string().swap(li->serial);
|
||||
li->path = std::move(path);
|
||||
std::string().swap(li->formatted_timestamp);
|
||||
@ -817,15 +817,15 @@ void SaveStateSelectorUI::Draw()
|
||||
|
||||
if (entry.global)
|
||||
{
|
||||
ImGui::Text(Host::TranslateString("SaveStateSelectorUI", "Global Slot %d"), entry.slot);
|
||||
ImGui::Text(TRANSLATE("SaveStateSelectorUI", "Global Slot %d"), entry.slot);
|
||||
}
|
||||
else if (entry.serial.empty())
|
||||
{
|
||||
ImGui::Text(Host::TranslateString("SaveStateSelectorUI", "Game Slot %d"), entry.slot);
|
||||
ImGui::Text(TRANSLATE("SaveStateSelectorUI", "Game Slot %d"), entry.slot);
|
||||
}
|
||||
else
|
||||
{
|
||||
ImGui::Text(Host::TranslateString("SaveStateSelectorUI", "%s Slot %d"), entry.serial.c_str(), entry.slot);
|
||||
ImGui::Text(TRANSLATE("SaveStateSelectorUI", "%s Slot %d"), entry.serial.c_str(), entry.slot);
|
||||
}
|
||||
ImGui::TextUnformatted(entry.title.c_str());
|
||||
ImGui::TextUnformatted(entry.formatted_timestamp.c_str());
|
||||
|
||||
Reference in New Issue
Block a user