mirror of
https://github.com/holub/mame
synced 2025-06-28 15:14:21 +03:00
selmenu: don't translate info box titles twice (nw)
This commit is contained in:
parent
5ead34d47b
commit
4232c067b1
@ -54,7 +54,7 @@ menu_dats_view::menu_dats_view(mame_ui_manager &mui, render_container &container
|
|||||||
{
|
{
|
||||||
std::string version;
|
std::string version;
|
||||||
mame_machine_manager::instance()->lua()->call_plugin("data_version", count, version);
|
mame_machine_manager::instance()->lua()->call_plugin("data_version", count, version);
|
||||||
m_items_list.emplace_back(_(item.c_str()), count, std::move(version));
|
m_items_list.emplace_back(item.c_str(), count, std::move(version));
|
||||||
count++;
|
count++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -86,7 +86,7 @@ menu_dats_view::menu_dats_view(mame_ui_manager &mui, render_container &container
|
|||||||
{
|
{
|
||||||
std::string version;
|
std::string version;
|
||||||
mame_machine_manager::instance()->lua()->call_plugin("data_version", count - 1, version);
|
mame_machine_manager::instance()->lua()->call_plugin("data_version", count - 1, version);
|
||||||
m_items_list.emplace_back(_(item.c_str()), count, std::move(version));
|
m_items_list.emplace_back(item.c_str(), count, std::move(version));
|
||||||
count++;
|
count++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2555,16 +2555,16 @@ void menu_select_launch::infos_render(float origx1, float origy1, float origx2,
|
|||||||
float ud_arrow_width = line_height * machine().render().ui_aspect();
|
float ud_arrow_width = line_height * machine().render().ui_aspect();
|
||||||
float oy1 = origy1 + line_height;
|
float oy1 = origy1 + line_height;
|
||||||
|
|
||||||
char const *const snaptext(m_info_view ? _(m_items_list[m_info_view - 1].c_str()) : _(first));
|
char const *const snaptext(m_info_view ? m_items_list[m_info_view - 1].c_str() : _(first));
|
||||||
|
|
||||||
// get width of widest title
|
// get width of widest title
|
||||||
float title_size(0.0f);
|
float title_size(0.0f);
|
||||||
for (std::size_t x = 0; total > x; ++x)
|
for (std::size_t x = 0; total > x; ++x)
|
||||||
{
|
{
|
||||||
char const *const name(x ? m_items_list[x - 1].c_str() : first);
|
char const *const name(x ? m_items_list[x - 1].c_str() : _(first));
|
||||||
float txt_length(0.0f);
|
float txt_length(0.0f);
|
||||||
ui().draw_text_full(
|
ui().draw_text_full(
|
||||||
container(), _(name),
|
container(), name,
|
||||||
origx1, origy1, origx2 - origx1,
|
origx1, origy1, origx2 - origx1,
|
||||||
ui::text_layout::CENTER, ui::text_layout::NEVER,
|
ui::text_layout::CENTER, ui::text_layout::NEVER,
|
||||||
mame_ui_manager::NONE, UI_TEXT_COLOR, UI_TEXT_BG_COLOR,
|
mame_ui_manager::NONE, UI_TEXT_COLOR, UI_TEXT_BG_COLOR,
|
||||||
|
Loading…
Reference in New Issue
Block a user