summaryrefslogtreecommitdiffstats
path: root/profile.c
diff options
context:
space:
mode:
authorGravatar Robert C. Helling <helling@atdotde.de>2014-03-31 12:52:46 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-03-31 09:48:16 -0700
commit61d60f6b1af27c18c5024637210de04e0808072d (patch)
tree0e7e891cee8d1c598e4623eed20ce5916650cdf6 /profile.c
parent907459291d505e55e63ab02018056f70f471bef9 (diff)
downloadsubsurface-61d60f6b1af27c18c5024637210de04e0808072d.tar.gz
Exchange EAD and END to align our language with the rest of the world
This needs to be tracked in the documentation as well. Signed-off-by: Robert C. Helling <helling@atdotde.de> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'profile.c')
-rw-r--r--profile.c17
1 files changed, 10 insertions, 7 deletions
diff --git a/profile.c b/profile.c
index 3d46c3179..5db3c3d11 100644
--- a/profile.c
+++ b/profile.c
@@ -1151,11 +1151,11 @@ static void calculate_gas_information_new(struct dive *dive, struct plot_info *p
/* Calculate MOD, EAD, END and EADD based on partial pressures calculated before
* so there is no difference in calculating between OC and CC
- * EAD takes O2 + N2 (air) into account
- * END just uses N2 */
+ * END takes O2 + N2 (air) into account ("Narcotic" for trimix dives)
+ * EAD just uses N2 ("Air" for nitrox dives) */
entry->mod = (prefs.mod_ppO2 / fo2 * 1000 - 1) * 10000;
- entry->ead = (entry->depth + 10000) * (1000 - fhe) / 1000.0 - 10000;
- entry->end = (entry->depth + 10000) * (1000 - fo2 - fhe) / (double)N2_IN_AIR - 10000;
+ entry->end = (entry->depth + 10000) * (1000 - fhe) / 1000.0 - 10000;
+ entry->ead = (entry->depth + 10000) * (1000 - fo2 - fhe) / (double)N2_IN_AIR - 10000;
entry->eadd = (entry->depth + 10000) *
(entry->po2 / amb_pressure * O2_DENSITY + entry->pn2 / amb_pressure *
N2_DENSITY +
@@ -1256,12 +1256,15 @@ static void plot_string(struct plot_info *pi, struct plot_data *entry, struct me
if (prefs.ead) {
switch (pi->dive_type) {
case NITROX:
+ ead = (int)get_depth_units(entry->ead, NULL, &depth_unit);
+ put_format(b, translate("gettextFromC", "EAD: %d%s\nEADD: %d%s\n"), ead, depth_unit, eadd, depth_unit);
+ break;
+ case TRIMIX:
end = (int)get_depth_units(entry->end, NULL, &depth_unit);
put_format(b, translate("gettextFromC", "END: %d%s\nEADD: %d%s\n"), end, depth_unit, eadd, depth_unit);
break;
- case TRIMIX:
- ead = (int)get_depth_units(entry->ead, NULL, &depth_unit);
- put_format(b, translate("gettextFromC", "EAD: %d%s\nEADD: %d%s\n"), ead, depth_unit, eadd, depth_unit);
+ case AIR:
+ /* nothing */
break;
}
}