diff --git a/src/CsvRideFile.cpp b/src/CsvRideFile.cpp index 0d116ce26..67a0040a6 100644 --- a/src/CsvRideFile.cpp +++ b/src/CsvRideFile.cpp @@ -153,6 +153,7 @@ RideFile *CsvFileReader::openRideFile(QFile &file, QStringList &errors) const if (!metric) { km *= KM_PER_MILE; kph *= KM_PER_MILE; + alt *= METERS_PER_FOOT; } } else if (iBike) { @@ -174,6 +175,7 @@ RideFile *CsvFileReader::openRideFile(QFile &file, QStringList &errors) const if (!metric) { km *= KM_PER_MILE; kph *= KM_PER_MILE; + alt *= METERS_PER_FOOT; } } else { @@ -204,6 +206,7 @@ RideFile *CsvFileReader::openRideFile(QFile &file, QStringList &errors) const if (!metric) { km *= KM_PER_MILE; kph *= KM_PER_MILE; + alt *= METERS_PER_FOOT; } } diff --git a/src/Units.h b/src/Units.h index 0ddee9b81..b06d4edae 100644 --- a/src/Units.h +++ b/src/Units.h @@ -22,6 +22,7 @@ #define KM_PER_MILE 1.609344 #define MILES_PER_KM 0.62137119 #define FEET_PER_METER 3.2808399 +#define METERS_PER_FOOT 0.3047999 #endif // _GC_Units_h