mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
core: convert weightsystem_t and weightsystem_table to C++
As for cylinders, this had to be done simultaneously, Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
28520da655
commit
640ecb345b
28 changed files with 137 additions and 247 deletions
|
@ -356,12 +356,9 @@ void DiveComponentSelection::buttonClicked(QAbstractButton *button)
|
|||
}
|
||||
}
|
||||
if (what->weights) {
|
||||
int w;
|
||||
text << tr("Weights:\n");
|
||||
for (w = 0; w < current_dive->weightsystems.nr; w++) {
|
||||
weightsystem_t ws = current_dive->weightsystems.weightsystems[w];
|
||||
text << ws.description << ws.weight.grams / 1000 << "kg\n";
|
||||
}
|
||||
for (auto &ws: current_dive->weightsystems)
|
||||
text << QString::fromStdString(ws.description) << ws.weight.grams / 1000 << "kg\n";
|
||||
}
|
||||
if (what->number)
|
||||
text << tr("Dive number: ") << current_dive->number << "\n";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue