mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
desktop: fix translation implementation
We need to always call the tr() function of the base class. This will have consequences for our translations. See: #3068 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
51d0cb7aba
commit
8e3f7f9565
2 changed files with 11 additions and 11 deletions
|
@ -1030,9 +1030,9 @@ AddCylinder::AddCylinder(bool currentDiveOnly) :
|
|||
if (dives.empty())
|
||||
return;
|
||||
else if (dives.size() == 1)
|
||||
setText(tr("Add cylinder"));
|
||||
setText(Command::Base::tr("Add cylinder"));
|
||||
else
|
||||
setText(tr("Add cylinder (%n dive(s))", "", dives.size()));
|
||||
setText(Command::Base::tr("Add cylinder (%n dive(s))", "", dives.size()));
|
||||
cyl = create_new_cylinder(dives[0]);
|
||||
}
|
||||
|
||||
|
@ -1151,9 +1151,9 @@ RemoveCylinder::RemoveCylinder(int index, bool currentDiveOnly) :
|
|||
EditCylinderBase(index, currentDiveOnly, true, SAME_TYPE | SAME_PRESS | SAME_GAS)
|
||||
{
|
||||
if (dives.size() == 1)
|
||||
setText(tr("Remove cylinder"));
|
||||
setText(Command::Base::tr("Remove cylinder"));
|
||||
else
|
||||
setText(tr("Remove cylinder (%n dive(s))", "", dives.size()));
|
||||
setText(Command::Base::tr("Remove cylinder (%n dive(s))", "", dives.size()));
|
||||
}
|
||||
|
||||
void RemoveCylinder::undo()
|
||||
|
@ -1201,9 +1201,9 @@ EditCylinder::EditCylinder(int index, cylinder_t cylIn, EditCylinderType typeIn,
|
|||
return;
|
||||
|
||||
if (dives.size() == 1)
|
||||
setText(tr("Edit cylinder"));
|
||||
setText(Command::Base::tr("Edit cylinder"));
|
||||
else
|
||||
setText(tr("Edit cylinder (%n dive(s))", "", dives.size()));
|
||||
setText(Command::Base::tr("Edit cylinder (%n dive(s))", "", dives.size()));
|
||||
|
||||
// Try to untranslate the cylinder type
|
||||
QString description = cylIn.type.description;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue