Support Magellan GPX extensions

.. using the GPX format they add extensions to record
   power, heartrate and cadence using element names
   power, heartrate and cadence ! (way to simple!)

.. thanks to Wenqi Zhang for the sample.
This commit is contained in:
Mark Liversedge
2014-12-26 09:22:52 +00:00
parent 33be087c2f
commit 9fe930dca5

View File

@@ -123,7 +123,7 @@ bool
{
alt = buffer.toDouble(); // metric
}
else if (qName == "gpxtpx:hr")
else if (qName == "gpxtpx:hr" || qName == "heartrate")
{
hr = buffer.toInt();
}
@@ -135,7 +135,7 @@ bool
{
temp = buffer.toDouble();
}
else if ((qName == "gpxdata:cadence") || (qName == "gpxtpx:cad"))
else if ((qName == "gpxdata:cadence") || (qName == "gpxtpx:cad") || qName == "cadence")
{
cad = buffer.toDouble();
}