Add RideItem ::color, ::isRun and ::present

.. as primary fields, and also load/save to cache.
This commit is contained in:
Mark Liversedge
2014-12-12 14:08:11 +00:00
parent f4ad330a5f
commit e97045703a
9 changed files with 36 additions and 17 deletions

View File

@@ -5839,7 +5839,7 @@ AllPlot::pointHover(QwtPlotCurve *curve, int index)
// for speed curve add pace with units according to settings
// only when the activity is a run.
QString paceStr;
if (curve->title() == tr("Speed") && rideItem && rideItem->isRun()) {
if (curve->title() == tr("Speed") && rideItem && rideItem->isRun) {
bool metricPace = appsettings->value(this, GC_PACE, true).toBool();
QString paceunit = metricPace ? tr("min/km") : tr("min/mile");
paceStr = tr("\n%1 %2").arg(context->athlete->useMetricUnits ? kphToPace(yvalue, metricPace) : mphToPace(yvalue, metricPace)).arg(paceunit);