mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 06:39:46 -06:00
i18n: Add comments and improve source strings
This commit is contained in:
@ -53,10 +53,12 @@ SkylanderModifyDialog::SkylanderModifyDialog(QWidget* parent, u8 slot)
|
||||
{
|
||||
// Should never be able to happen. Still good to have
|
||||
name =
|
||||
// i18n: "Var" is short for "variant"
|
||||
tr("Unknown (Id:%1 Var:%2)").arg(m_figure_data.figure_id).arg(m_figure_data.variant_id);
|
||||
}
|
||||
}
|
||||
|
||||
// i18n: %1 is a name
|
||||
auto* label_name = new QLabel(tr("Modifying Skylander: %1").arg(name));
|
||||
|
||||
hbox_name->addWidget(label_name);
|
||||
@ -136,11 +138,13 @@ void SkylanderModifyDialog::PopulateSkylanderOptions(QVBoxLayout* layout)
|
||||
reinterpret_cast<char16_t*>(m_figure_data.skylander_data.nickname.data())));
|
||||
|
||||
auto* hbox_playtime = new QHBoxLayout();
|
||||
// i18n: The total amount of time the Skylander has been used for
|
||||
auto* label_playtime = new QLabel(tr("Playtime:"));
|
||||
auto* edit_playtime =
|
||||
new QLineEdit(QStringLiteral("%1").arg(m_figure_data.skylander_data.playtime));
|
||||
|
||||
auto* hbox_last_reset = new QHBoxLayout();
|
||||
// i18n: A timestamp for when the Skylander was most recently reset
|
||||
auto* label_last_reset = new QLabel(tr("Last reset:"));
|
||||
auto* edit_last_reset =
|
||||
new QDateTimeEdit(QDateTime(QDate(m_figure_data.skylander_data.last_reset.year,
|
||||
@ -150,6 +154,7 @@ void SkylanderModifyDialog::PopulateSkylanderOptions(QVBoxLayout* layout)
|
||||
m_figure_data.skylander_data.last_reset.minute)));
|
||||
|
||||
auto* hbox_last_placed = new QHBoxLayout();
|
||||
// i18n: A timestamp for when the Skylander was most recently used
|
||||
auto* label_last_placed = new QLabel(tr("Last placed:"));
|
||||
auto* edit_last_placed =
|
||||
new QDateTimeEdit(QDateTime(QDate(m_figure_data.skylander_data.last_placed.year,
|
||||
@ -167,10 +172,10 @@ void SkylanderModifyDialog::PopulateSkylanderOptions(QVBoxLayout* layout)
|
||||
edit_last_placed->setDisplayFormat(QStringLiteral("dd/MM/yyyy hh:mm"));
|
||||
|
||||
edit_toy_code->setToolTip(tr("The toy code for this figure. Only available for real figures."));
|
||||
edit_money->setToolTip(tr("The amount of money this skylander should have. Between 0 and 65000"));
|
||||
edit_hero->setToolTip(tr("The hero level of this skylander. Only seen in Skylanders: Spyro's "
|
||||
edit_money->setToolTip(tr("The amount of money this Skylander has. Between 0 and 65000"));
|
||||
edit_hero->setToolTip(tr("The hero level of this Skylander. Only seen in Skylanders: Spyro's "
|
||||
"Adventures. Between 0 and 100"));
|
||||
edit_nick->setToolTip(tr("The nickname for this skylander. Limited to 15 characters"));
|
||||
edit_nick->setToolTip(tr("The nickname for this Skylander. Limited to 15 characters"));
|
||||
edit_playtime->setToolTip(
|
||||
tr("The total time this figure has been used inside a game in seconds"));
|
||||
edit_last_reset->setToolTip(tr("The last time the figure has been reset. If the figure has never "
|
||||
@ -309,6 +314,8 @@ bool SkylanderModifyDialog::PopulateTrophyOptions(QVBoxLayout* layout)
|
||||
edit_villains[i] = new QCheckBox();
|
||||
edit_villains[i]->setChecked(static_cast<bool>(m_figure_data.trophy_data.unlocked_villains &
|
||||
(0b1 << shift_distances[i])));
|
||||
// i18n: "Captured" is a participle here. This string is used when listing villains, not when a
|
||||
// villain was just captured
|
||||
auto* const label = new QLabel(tr("Captured villain %1:").arg(i + 1));
|
||||
auto* const hbox = new QHBoxLayout();
|
||||
hbox->addWidget(label);
|
||||
|
@ -546,6 +546,7 @@ void SkylanderPortalWindow::LoadSelected()
|
||||
}
|
||||
else
|
||||
{
|
||||
// i18n: This is used to create a file name. The string must end in ".sky".
|
||||
const QString str = tr("Unknown(%1 %2).sky");
|
||||
predef_name += str.arg(m_sky_id, m_sky_var);
|
||||
}
|
||||
@ -629,6 +630,7 @@ void SkylanderPortalWindow::CreateSkylanderAdvanced()
|
||||
}
|
||||
else
|
||||
{
|
||||
// i18n: This is used to create a file name. The string must end in ".sky".
|
||||
QString str = tr("Unknown(%1 %2).sky");
|
||||
predef_name += str.arg(m_sky_id, m_sky_var);
|
||||
}
|
||||
@ -673,7 +675,7 @@ void SkylanderPortalWindow::ClearSlot(u8 slot)
|
||||
if (!system.GetSkylanderPortal().RemoveSkylander(slot_infos->portal_slot))
|
||||
{
|
||||
QMessageBox::warning(this, tr("Failed to clear Skylander!"),
|
||||
tr("Failed to clear the Skylander from slot(%1)!").arg(slot),
|
||||
tr("Failed to clear the Skylander from slot %1!").arg(slot),
|
||||
QMessageBox::Ok);
|
||||
return;
|
||||
}
|
||||
@ -795,7 +797,7 @@ void SkylanderPortalWindow::CreateSkyfile(const QString& path, bool load_after)
|
||||
{
|
||||
QMessageBox::warning(
|
||||
this, tr("Failed to create Skylander file!"),
|
||||
tr("Failed to create Skylander file:\n%1\n(Skylander may already be on the portal)")
|
||||
tr("Failed to create Skylander file:\n%1\n\nThe Skylander may already be on the portal.")
|
||||
.arg(path),
|
||||
QMessageBox::Ok);
|
||||
return;
|
||||
@ -813,11 +815,11 @@ void SkylanderPortalWindow::LoadSkyfilePath(u8 slot, const QString& path)
|
||||
File::IOFile sky_file(path.toStdString(), "r+b");
|
||||
if (!sky_file)
|
||||
{
|
||||
QMessageBox::warning(
|
||||
this, tr("Failed to open the Skylander file!"),
|
||||
tr("Failed to open the Skylander file(%1)!\nFile may already be in use on the portal.")
|
||||
.arg(path),
|
||||
QMessageBox::Ok);
|
||||
QMessageBox::warning(this, tr("Failed to open the Skylander file!"),
|
||||
tr("Failed to open the Skylander file:\n%1\n\nThe file may already be in "
|
||||
"use on the portal.")
|
||||
.arg(path),
|
||||
QMessageBox::Ok);
|
||||
return;
|
||||
}
|
||||
std::array<u8, 0x40 * 0x10> file_data;
|
||||
@ -825,7 +827,7 @@ void SkylanderPortalWindow::LoadSkyfilePath(u8 slot, const QString& path)
|
||||
{
|
||||
QMessageBox::warning(
|
||||
this, tr("Failed to read the Skylander file!"),
|
||||
tr("Failed to read the Skylander file(%1)!\nFile was too small.").arg(path),
|
||||
tr("Failed to read the Skylander file:\n%1\n\nThe file was too small.").arg(path),
|
||||
QMessageBox::Ok);
|
||||
return;
|
||||
}
|
||||
@ -839,7 +841,7 @@ void SkylanderPortalWindow::LoadSkyfilePath(u8 slot, const QString& path)
|
||||
if (portal_slot == 0xFF)
|
||||
{
|
||||
QMessageBox::warning(this, tr("Failed to load the Skylander file!"),
|
||||
tr("Failed to load the Skylander file(%1)!\n").arg(path), QMessageBox::Ok);
|
||||
tr("Failed to load the Skylander file:\n%1").arg(path), QMessageBox::Ok);
|
||||
return;
|
||||
}
|
||||
m_sky_slots[slot] = {portal_slot, id_var.first, id_var.second};
|
||||
@ -862,6 +864,7 @@ void SkylanderPortalWindow::UpdateSlotNames()
|
||||
}
|
||||
else
|
||||
{
|
||||
// i18n: "Var" is short for "variant"
|
||||
display_string = tr("Unknown (Id:%1 Var:%2)").arg(sd->m_sky_id).arg(sd->m_sky_var);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user