mirror of
https://github.com/subsurface/subsurface.git
synced 2024-11-27 20:58:47 +00:00
Desktop: Fix time format in dive planner.
Make the time edit respect the configured time format. Also make the date and time format change when the preferences are changed. Fixes #3849. Signed-off-by: Michael Keller <github@ike.ch>
This commit is contained in:
parent
f05ec222ff
commit
468c1d8d61
1 changed files with 3 additions and 1 deletions
|
@ -28,7 +28,6 @@ DivePlannerWidget::DivePlannerWidget(QWidget *parent) : QWidget(parent, QFlag(0)
|
|||
CylindersModel *cylinders = DivePlannerPointsModel::instance()->cylindersModel();
|
||||
|
||||
ui.setupUi(this);
|
||||
ui.dateEdit->setDisplayFormat(prefs.date_format);
|
||||
ui.tableWidget->setTitle(tr("Dive planner points"));
|
||||
ui.tableWidget->setModel(plannerModel);
|
||||
connect(ui.tableWidget, &TableView::itemClicked, plannerModel, &DivePlannerPointsModel::remove);
|
||||
|
@ -158,6 +157,9 @@ void DivePlannerWidget::settingsChanged()
|
|||
ui.atmHeight->blockSignals(true);
|
||||
ui.atmHeight->setValue((int) get_depth_units((int) pressure_to_altitude(DivePlannerPointsModel::instance()->getSurfacePressure()), NULL,NULL));
|
||||
ui.atmHeight->blockSignals(false);
|
||||
|
||||
ui.dateEdit->setDisplayFormat(prefs.date_format);
|
||||
ui.startTime->setDisplayFormat(prefs.time_format);
|
||||
}
|
||||
|
||||
void DivePlannerWidget::atmPressureChanged(const int pressure)
|
||||
|
|
Loading…
Reference in a new issue