mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Dive site rewrite: add the taxonomy labels for the dive sites
This doesn't work yet because we don't get the taxonomy from the geo referencing services yet - but it's ready to be populated. Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
e28af7c639
commit
3435d13509
2 changed files with 20 additions and 6 deletions
|
@ -566,6 +566,7 @@ void MainTab::updateDiveInfo(bool clear)
|
||||||
ui.waterTemperatureText->setText(get_temperature_string(displayed_dive.watertemp, true));
|
ui.waterTemperatureText->setText(get_temperature_string(displayed_dive.watertemp, true));
|
||||||
ui.airTemperatureText->setText(get_temperature_string(displayed_dive.airtemp, true));
|
ui.airTemperatureText->setText(get_temperature_string(displayed_dive.airtemp, true));
|
||||||
ui.DiveType->setCurrentIndex(get_dive_dc(&displayed_dive, dc_number)->divemode);
|
ui.DiveType->setCurrentIndex(get_dive_dc(&displayed_dive, dc_number)->divemode);
|
||||||
|
|
||||||
volume_t gases[MAX_CYLINDERS] = {};
|
volume_t gases[MAX_CYLINDERS] = {};
|
||||||
get_gas_used(&displayed_dive, gases);
|
get_gas_used(&displayed_dive, gases);
|
||||||
QString volumes;
|
QString volumes;
|
||||||
|
@ -690,6 +691,12 @@ void MainTab::updateDiveInfo(bool clear)
|
||||||
gasUsedString.append(QString("O2: %2\n").arg(get_volume_string(o2_tot, true)));
|
gasUsedString.append(QString("O2: %2\n").arg(get_volume_string(o2_tot, true)));
|
||||||
}
|
}
|
||||||
ui.gasConsumption->setText(gasUsedString);
|
ui.gasConsumption->setText(gasUsedString);
|
||||||
|
ui.locationTags->setText(ds->description); // TODO: This should be three tags following davide's explanation.
|
||||||
|
if(ui.locationTags->text().isEmpty())
|
||||||
|
ui.locationTags->hide();
|
||||||
|
else
|
||||||
|
ui.locationTags->show();
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
/* clear the fields */
|
/* clear the fields */
|
||||||
clearInfo();
|
clearInfo();
|
||||||
|
|
|
@ -180,6 +180,13 @@
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="locationTags">
|
||||||
|
<property name="text">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
|
@ -532,8 +539,8 @@
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>100</width>
|
<width>449</width>
|
||||||
<height>30</height>
|
<height>743</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="equipmentTabScrollAreaLayout">
|
<layout class="QGridLayout" name="equipmentTabScrollAreaLayout">
|
||||||
|
@ -627,8 +634,8 @@
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>389</width>
|
<width>449</width>
|
||||||
<height>430</height>
|
<height>743</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="diveInfoScrollAreaLayout">
|
<layout class="QGridLayout" name="diveInfoScrollAreaLayout">
|
||||||
|
@ -968,8 +975,8 @@
|
||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>408</width>
|
<width>449</width>
|
||||||
<height>253</height>
|
<height>743</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue