From 41f87f3e770761096d4f9f921b00b448d01d2eae Mon Sep 17 00:00:00 2001 From: "Robert C. Helling" Date: Thu, 13 May 2021 15:33:07 +0200 Subject: [PATCH] Translate header strings for APD We are matching translated header names. Thus, when composing a header line for APD, make sure it contains translations. This mechanism is quite brittle. Our German translations had two different translations for "Sample time" and this already broke it. This is why this patch also includes a fix for a translation string (should be fixed in transiflex as well of course). Fixes #3246 Signed-off-by: Robert C. Helling --- desktop-widgets/divelogimportdialog.cpp | 2 +- translations/subsurface_de_DE.ts | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/desktop-widgets/divelogimportdialog.cpp b/desktop-widgets/divelogimportdialog.cpp index 9876c3550..cd1df5bc7 100644 --- a/desktop-widgets/divelogimportdialog.cpp +++ b/desktop-widgets/divelogimportdialog.cpp @@ -573,7 +573,7 @@ void DiveLogImportDialog::loadFileContents(int value, whatChanged triggeredBy) apd=true; - firstLine = "Sample time" + apdseparator + "Sample depth" + apdseparator + "Sample setpoint" + apdseparator + "Sample sensor1 pO₂" + apdseparator + "Sample sensor2 pO₂" + apdseparator + "Sample sensor3 pO₂" + apdseparator + "Sample pO₂" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "Sample temperature" + apdseparator + "" + apdseparator + "Sample CNS" + apdseparator + "Sample stopdepth"; + firstLine = tr("Sample time") + apdseparator + tr("Sample depth") + apdseparator + tr("Sample setpoint") + apdseparator + tr("Sample sensor1 pO₂") + apdseparator + tr("Sample sensor2 pO₂") + apdseparator + tr("Sample sensor3 pO₂") + apdseparator + tr("Sample pO₂") + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + "" + apdseparator + tr("Sample temperature") + apdseparator + "" + apdseparator + tr("Sample CNS") + apdseparator + tr("Sample stopdepth"); blockSignals(true); ui->CSVSeparator->setCurrentText(apdseparator); if (triggeredBy == INITIAL && fileNames.first().contains(".apd", Qt::CaseInsensitive)) diff --git a/translations/subsurface_de_DE.ts b/translations/subsurface_de_DE.ts index beb7e96cd..ab4d76103 100644 --- a/translations/subsurface_de_DE.ts +++ b/translations/subsurface_de_DE.ts @@ -4013,7 +4013,7 @@ Position verwenden Sample time - Segment Dauer + Segment Zeit