mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
core: use C++ structures for tanksystem info
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
3bfbf12b9a
commit
5f36c8ccde
13 changed files with 77 additions and 106 deletions
|
@ -1319,8 +1319,9 @@ EditCylinder::EditCylinder(int index, cylinder_t cylIn, EditCylinderType typeIn,
|
|||
void EditCylinder::redo()
|
||||
{
|
||||
for (size_t i = 0; i < dives.size(); ++i) {
|
||||
set_tank_info_size(&tank_info_table, cyl[i].type.description, cyl[i].type.size);
|
||||
set_tank_info_workingpressure(&tank_info_table, cyl[i].type.description, cyl[i].type.workingpressure);
|
||||
std::string name = cyl[i].type.description;
|
||||
set_tank_info_size(tank_info_table, name, cyl[i].type.size);
|
||||
set_tank_info_workingpressure(tank_info_table, name, cyl[i].type.workingpressure);
|
||||
std::swap(*get_cylinder(dives[i], indexes[i]), cyl[i]);
|
||||
update_cylinder_related_info(dives[i]);
|
||||
emit diveListNotifier.cylinderEdited(dives[i], indexes[i]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue