From 24c915e97c4607a000c2df82ac412286854c7c2c Mon Sep 17 00:00:00 2001 From: Stefan Fuchs Date: Fri, 13 Jul 2018 17:42:03 +0200 Subject: In planner notes don't show dive mode for first data point Signed-off-by: Stefan Fuchs --- core/plannernotes.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core') diff --git a/core/plannernotes.c b/core/plannernotes.c index 49ab647af..c7d443324 100644 --- a/core/plannernotes.c +++ b/core/plannernotes.c @@ -312,7 +312,7 @@ void add_plan_to_notes(struct diveplan *diveplan, struct dive *dive, bool show_d free(temp); } else { put_format(&buf, "%s %s", - gasname(&newgasmix), lastdivemode == dp->divemode ? "" : translate("gettextFromC", divemode_text_ui[dp->divemode])); + gasname(&newgasmix), lastdivemode == UNDEF_COMP_TYPE || lastdivemode == dp->divemode ? "" : translate("gettextFromC", divemode_text_ui[dp->divemode])); if (isascent && (get_he(&lastprintgasmix) > 0)) { // For a trimix gas change on ascent, save ICD info if previous cylinder had helium if (isobaric_counterdiffusion(&lastprintgasmix, &newgasmix, &icdvalues)) // Do icd calulations icdwarning = true; @@ -334,7 +334,7 @@ void add_plan_to_notes(struct diveplan *diveplan, struct dive *dive, bool show_d free(temp); } else { put_format(&buf, "%s %s", gasname(&gasmix), - lastdivemode == dp->divemode ? "" : translate("gettextFromC", divemode_text_ui[dp->divemode])); + lastdivemode == UNDEF_COMP_TYPE || lastdivemode == dp->divemode ? "" : translate("gettextFromC", divemode_text_ui[dp->divemode])); if (get_he(&lastprintgasmix) > 0) { // For a trimix gas change, save ICD info if previous cylinder had helium if (isobaric_counterdiffusion(&lastprintgasmix, &gasmix, &icdvalues)) // Do icd calculations icdwarning = true; -- cgit v1.2.3-70-g09d2