diff --git a/src/ANTChannel.cpp b/src/ANTChannel.cpp index f6c5a9979..babfa8407 100644 --- a/src/ANTChannel.cpp +++ b/src/ANTChannel.cpp @@ -400,7 +400,7 @@ void ANTChannel::broadcastEvent(unsigned char *ant_message) float cadence = 2000.0 * 60 * (antMessage.eventCount - lastMessage.eventCount) / period; float power = 3.14159 * nm_torque * cadence / 30; - // ignore the occassional spikes (reed switch) + // ignore the occasional spikes (reed switch) if (power >= 0 && power < 2501 && cadence >=0 && cadence < 256) { value2 = value = power; is_alt ? parent->setAltWatts(power) : parent->setWatts(power); @@ -768,7 +768,7 @@ void ANTChannel::attemptTransition(int message_id) //qDebug()<sendMessage(ANTMessage::assignChannel(number, CHANNEL_TYPE_RX, st->network)); // recieve channel on network 1 + parent->sendMessage(ANTMessage::assignChannel(number, CHANNEL_TYPE_RX, st->network)); // receive channel on network 1 device_id=st->device_id; setId(); @@ -794,7 +794,7 @@ void ANTChannel::attemptTransition(int message_id) case ANT_SEARCH_TIMEOUT: //qDebug()<period; parent->sendMessage(ANTMessage::setChannelPeriod(number, st->period)); } else { @@ -839,7 +839,7 @@ void ANTChannel::attemptTransition(int message_id) } // Calibrate... needs fixing in version 3.1 -// request the device on this channel calibrates itselt +// request the device on this channel calibrates itself void ANTChannel::requestCalibrate() { parent->sendMessage(ANTMessage::requestCalibrate(number)); } diff --git a/src/ANTMessage.cpp b/src/ANTMessage.cpp index 090bc967f..909ed3d62 100644 --- a/src/ANTMessage.cpp +++ b/src/ANTMessage.cpp @@ -32,7 +32,7 @@ // // ENCODING // To encode a message 8 bytes of message data are passed and a checksum -// is calculataed. +// is calculated. // // Since many of the message types do not require all data to be encoded // there are a number of static convenience methods that take the message @@ -681,31 +681,112 @@ ANTMessage ANTMessage::close(const unsigned char channel) // kickr broadcast commands, lifted largely from the Wahoo SDK example: KICKRDemo/WFAntBikePowerCodec.cs ANTMessage ANTMessage::kickrErgMode(const unsigned char channel, ushort usDeviceId, ushort usWatts, bool bSimSpeed) { - Q_UNUSED(channel); - Q_UNUSED(usDeviceId); - Q_UNUSED(usWatts); - Q_UNUSED(bSimSpeed); - //return ANTMessage(9, ANT_BROADCAST_DATA, channel, // broadcast - // KICKR_SET_ERG_MODE, seq, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), - // (unsigned char)usWatts, (unsigned char)(usWatts>>8), - // (unsigned char)(bSimSpeed) ? 1 : 0); - return ANTMessage(); // shutup compiler till we work it out + return ANTMessage(9, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_ERG_MODE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), + (unsigned char)usWatts, (unsigned char)(usWatts>>8), + (unsigned char)(bSimSpeed) ? 1 : 0); +} + +ANTMessage ANTMessage::kickrSlopeMode(const unsigned char channel, ushort usDeviceId, ushort scale) +{ + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_RESISTANCE_MODE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)scale, (unsigned char)(scale>>8)); +} + +ANTMessage ANTMessage::kickrSimMode(const unsigned char channel, ushort usDeviceId, float fWeight) +{ + // weight encoding + ushort usWeight = (ushort)(fWeight * 100.0); + + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_SIM_MODE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)usWeight, (unsigned char)(usWeight>>8)); +} + +ANTMessage ANTMessage::kickrStdMode(const unsigned char channel, ushort usDeviceId, ushort eLevel) +{ + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_STANDARD_MODE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)eLevel, (unsigned char)(eLevel>>8)); +} + +ANTMessage ANTMessage::kickrFtpMode(const unsigned char channel, ushort usDeviceId, ushort usFtp, ushort usPercent) +{ + return ANTMessage(9, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_FTP_MODE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)usFtp, (unsigned char)(usFtp>>8), + (unsigned char)usPercent, (unsigned char)(usPercent>>8)); +} + +ANTMessage ANTMessage::kickrRollingResistance(const unsigned char channel, ushort usDeviceId, float fCrr) +{ + // crr encoding + ushort usCrr = (ushort)(fCrr * 10000.0); + + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_CRR, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)usCrr, (unsigned char)(usCrr>>8)); +} + +ANTMessage ANTMessage::kickrWindResistance(const unsigned char channel, ushort usDeviceId, float fC) +{ + // wind resistance encoding + ushort usC = (ushort)(fC * 1000.0); + + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_C, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)usC, (unsigned char)(usC>>8)); } ANTMessage ANTMessage::kickrGrade(const unsigned char channel, ushort usDeviceId, float fGrade) { - Q_UNUSED(channel); - Q_UNUSED(usDeviceId); - Q_UNUSED(fGrade); - //// grade encoding - //if (fGrade > 1) fGrade = 1; - //if (fGrade < -1) fGrade = -1; - //fGrade = fGrade + 1; - //ushort usGrade = (ushort)(fGrade * 65536 / 2); + // grade encoding + if (fGrade > 1) fGrade = 1; + if (fGrade < -1) fGrade = -1; - //return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast - //KICKR_SET_GRADE, seq, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble - //(unsigned char)usGrade, (unsigned char)(usGrade>>8)); - return ANTMessage(); // shutup compiler till we work it out + fGrade = fGrade + 1; + ushort usGrade = (ushort)(fGrade * 65536 / 2); + + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_GRADE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)usGrade, (unsigned char)(usGrade>>8)); +} + +ANTMessage ANTMessage::kickrWindSpeed(const unsigned char channel, ushort usDeviceId, float mpsWindSpeed) +{ + // windspeed encoding + if (mpsWindSpeed > 32.768f) mpsWindSpeed = 32.768f; + if (mpsWindSpeed < -32.768f) mpsWindSpeed = -32.768f; + + // the wind speed is transmitted in 1/1000 mps resolution. + mpsWindSpeed = mpsWindSpeed + 32.768f; + ushort usSpeed = (ushort)(mpsWindSpeed * 1000); + + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_WIND_SPEED, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)usSpeed, (unsigned char)(usSpeed>>8)); +} + +ANTMessage ANTMessage::kickrWheelCircumference(const unsigned char channel, ushort usDeviceId, float mmCircumference) +{ + // circumference encoding + ushort usCirc = (ushort)(mmCircumference * 10.0); + + return ANTMessage(7, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_SET_WHEEL_CIRCUMFERENCE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8), // preamble + (unsigned char)usCirc, (unsigned char)(usCirc>>8)); +} + +ANTMessage ANTMessage::kickrReadMode(const unsigned char channel, ushort usDeviceId) +{ + return ANTMessage(5, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_INIT_SPINDOWN, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8)); // preamble +} + +ANTMessage ANTMessage::kickrInitSpindown(const unsigned char channel, ushort usDeviceId) +{ + return ANTMessage(5, ANT_BROADCAST_DATA, channel, // broadcast + KICKR_READ_MODE, (unsigned char)usDeviceId, (unsigned char)(usDeviceId>>8)); // preamble } diff --git a/src/ANTMessage.h b/src/ANTMessage.h index ce30cc241..29dca6e04 100644 --- a/src/ANTMessage.h +++ b/src/ANTMessage.h @@ -71,17 +71,17 @@ class ANTMessage { // kickr command channel messages all sent as broadcast data // over the command channel as type 0x4E static ANTMessage kickrErgMode(const unsigned char channel, ushort usDeviceId, ushort usWatts, bool bSimSpeed); - //static ANTMessage kickrFtpMode(const unsigned char channel, unsigned char seq, ushort usDeviceId, ushort usFtp, ushort usPercent); - //static ANTMessage kickrSlopeMode(const unsigned char channel, unsigned char seq, ushort usDeviceId, ushort scale); - //static ANTMessage kickrStdMode(const unsigned char channel, unsigned char seq, ushort usDeviceId, ushort eLevel); - //static ANTMessage kickrSimMode(const unsigned char channel, unsigned char seq, ushort usDeviceId, float fWeight); - //static ANTMessage kickrWindResistance(const unsigned char channel, unsigned char seq, ushort usDeviceId, float fC) ; - //static ANTMessage kickrRollingResistance(const unsigned char channel, unsigned char seq, ushort usDeviceId, float fCrr); + static ANTMessage kickrFtpMode(const unsigned char channel, ushort usDeviceId, ushort usFtp, ushort usPercent); + static ANTMessage kickrSlopeMode(const unsigned char channel, ushort usDeviceId, ushort scale); + static ANTMessage kickrStdMode(const unsigned char channel, ushort usDeviceId, ushort eLevel); + static ANTMessage kickrSimMode(const unsigned char channel, ushort usDeviceId, float fWeight); + static ANTMessage kickrWindResistance(const unsigned char channel, ushort usDeviceId, float fC) ; + static ANTMessage kickrRollingResistance(const unsigned char channel, ushort usDeviceId, float fCrr); static ANTMessage kickrGrade(const unsigned char channel, ushort usDeviceId, float fGrade); - //static ANTMessage kickrWindSpeed(const unsigned char channel, unsigned char seq, ushort usDeviceId, float mpsWindSpeed); - //static ANTMessage kickrWheelCircumference(const unsigned char channel, unsigned char seq, ushort usDeviceId, float mmCircumference); - //static ANTMessage kickrReadMode(const unsigned char channel, unsigned char seq, ushort usDeviceId); - //static ANTMessage kickrInitSpindown(const unsigned char channel, unsigned char seq, ushort usDeviceId); + static ANTMessage kickrWindSpeed(const unsigned char channel, ushort usDeviceId, float mpsWindSpeed); + static ANTMessage kickrWheelCircumference(const unsigned char channel, ushort usDeviceId, float mmCircumference); + static ANTMessage kickrReadMode(const unsigned char channel, ushort usDeviceId); + static ANTMessage kickrInitSpindown(const unsigned char channel, ushort usDeviceId); // convert a channel event message id to human readable string static const char * channelEventMessage(unsigned char c); diff --git a/src/Aerolab.cpp b/src/Aerolab.cpp index 773d27fb6..67eee9d40 100644 --- a/src/Aerolab.cpp +++ b/src/Aerolab.cpp @@ -390,7 +390,7 @@ Aerolab::setData(RideItem *_rideItem, bool new_zoom) { double f = 0.0; double a = 0.0; - // Use km data insteed of formula for file with a stop (gap). + // Use km data instead of formula for file with a stop (gap). //d += v * dt; //distanceArray[arrayLength] = d/1000; diff --git a/src/AllPlot.cpp b/src/AllPlot.cpp index 524b92744..20153f28c 100644 --- a/src/AllPlot.cpp +++ b/src/AllPlot.cpp @@ -467,7 +467,7 @@ AllPlotObject::setColor(QColor color) << smo2Curve << thbCurve << o2hbCurve << hhbCurve; - // work through getting progresively lighter + // work through getting progressively lighter QPen pen; pen.setWidth(1.0); int alpha = 200; @@ -1585,7 +1585,7 @@ AllPlot::recalc(AllPlotObject *objects) objects->smoothRTE.resize(rideTimeSecs + 1); objects->smoothLPS.resize(rideTimeSecs + 1); objects->smoothRPS.resize(rideTimeSecs + 1); - // do the smoothing by caculating the average of the "applysmooth" values left + // do the smoothing by calculating the average of the "applysmooth" values left // of the current data point - for points in time smaller than "applysmooth" // only the available datapoints left are used to build the average int i = 0; @@ -2137,7 +2137,7 @@ AllPlot::refreshCalibrationMarkers() scope != RideFile::NP && scope != RideFile::aPower && scope != RideFile::xPower) return; QColor color = GColor(CPOWER); - color.setAlpha(15); // almost invisble ! + color.setAlpha(15); // almost invisible ! if (rideItem && rideItem->ride()) { foreach(const RideFileCalibration &calibration, rideItem->ride()->calibrations()) { @@ -4529,7 +4529,7 @@ AllPlot::setDataFromRide(RideItem *_rideItem) // we don't have a reference plot referencePlot = NULL; - // bsically clear out + // basically clear out //standard->wattsArray.clear(); //standard->curveTitle.setLabel(QwtText(QString(""), QwtText::PlainText)); // default to no title @@ -4725,7 +4725,7 @@ AllPlot::setDataFromRideFile(RideFile *ride, AllPlotObject *here) // where 'high precision' time slice is an artefact // of double precision or slight timing anomalies // e.g. where realtime gives timestamps like - // 940.002 followed by 940.998 and were previouslt + // 940.002 followed by 940.998 and were previously // both rounded to 940s // // NOTE: this rounding mechanism is identical to that diff --git a/src/AllPlotSlopeCurve.cpp b/src/AllPlotSlopeCurve.cpp index fabafa868..01b93d764 100644 --- a/src/AllPlotSlopeCurve.cpp +++ b/src/AllPlotSlopeCurve.cpp @@ -164,7 +164,7 @@ void AllPlotSlopeCurve::drawCurve( QPainter *painter, int, points[0].ry() = refY; points[1].rx() = xi; points[1].ry() = yi; - // first point for slope/mperh calcuation + // first point for slope/mperh calculation QPointF calcPoint; calcPoint.rx() = sample.x(); calcPoint.ry() = sample.y(); @@ -182,7 +182,7 @@ void AllPlotSlopeCurve::drawCurve( QPainter *painter, int, points[3].ry() = refY; // append to list polygons.append(polygon); - // next point for slope/mperh calcuation + // next point for slope/mperh calculation QPointF calcPoint; calcPoint.rx() = sample.x(); calcPoint.ry() = sample.y(); diff --git a/src/AllPlotWindow.cpp b/src/AllPlotWindow.cpp index 908142f05..41857248c 100644 --- a/src/AllPlotWindow.cpp +++ b/src/AllPlotWindow.cpp @@ -558,7 +558,7 @@ AllPlotWindow::AllPlotWindow(Context *context) : fullPlot->setContentsMargins(0,0,0,0); // allPlotStack contains the allPlot and the stack by series - // because both want the optional fullplot at the botton + // because both want the optional fullplot at the bottom allPlotStack = new QStackedWidget(this); allPlotStack->addWidget(allStack); allPlotStack->addWidget(seriesstackFrame); @@ -855,7 +855,7 @@ AllPlotWindow::compareChanged() if (po->maxKM > maxKM) maxKM = po->maxKM; if (po->maxSECS > maxSECS) maxSECS = po->maxSECS; - // prettify / hide unneccessary guff + // prettify / hide unnecessary guff po->setColor(ci.color); po->hideUnwanted(); @@ -1094,7 +1094,7 @@ AllPlotWindow::compareChanged() rideSelected(); } - // were not stale anymore + // we're not stale anymore compareStale = false; // set the widgets straight @@ -1137,7 +1137,7 @@ AllPlotWindow::redrawAllPlot() void AllPlotWindow::redrawFullPlot() { - // always peformed sincethe data is used + // always performed since the data is used // by both the stack plots and the allplot RideItem *ride = current; @@ -2773,8 +2773,8 @@ AllPlotWindow::setSmoothing(int value) // Compare has LOTS of rides to smooth... if (context->isCompareIntervals) { - // no zero smoothin when comparing -- we need the - // arrays to be intitialised for all series + // no zero smoothing when comparing -- we need the + // arrays to be initialised for all series if (value < 1) value = 1; fullPlot->setSmoothing(value); diff --git a/src/BingMap.cpp b/src/BingMap.cpp index 9f3386afc..df26ea2fa 100644 --- a/src/BingMap.cpp +++ b/src/BingMap.cpp @@ -339,7 +339,7 @@ BingMap::drawShadedRoute() } // -// Static helper - havervine formaula for calculating the distance +// Static helper - havervine formula for calculating the distance // between 2 geo co-ordinates // static const double DEG_TO_RAD = 0.017453292519943295769236907684886; diff --git a/src/CPPlot.cpp b/src/CPPlot.cpp index 4c1620bb3..ea780cc73 100644 --- a/src/CPPlot.cpp +++ b/src/CPPlot.cpp @@ -329,7 +329,7 @@ CPPlot::initModel() } } -// Plot the dashed line model curve according to the paramters +// Plot the dashed line model curve according to the parameters // and will also plot the heat on the curve or below since it is // related to the model void diff --git a/src/CalDAV.cpp b/src/CalDAV.cpp index 7409672b2..acb7f7f0e 100644 --- a/src/CalDAV.cpp +++ b/src/CalDAV.cpp @@ -259,7 +259,7 @@ icalcomponent *createEvent(RideItem *rideItem) icalcomponent_set_description(event, rideItem->ride()->getTag("Calendar Text", "").toLatin1()); // attach ridefile - // google doesn't suport attachments yet. There is a labs option to use google docs + // google doesn't support attachments yet. There is a labs option to use google docs // but it is only available to Google Apps customers. // put the event into root diff --git a/src/Colors.cpp b/src/Colors.cpp index 91b4a5b78..40dc1ed86 100644 --- a/src/Colors.cpp +++ b/src/Colors.cpp @@ -35,7 +35,7 @@ // the standard themes, a global object static Themes allThemes; -// Number of confugurable metric colors + 1 for sentinel value +// Number of configurable metric colors + 1 for sentinel value static Colors ColorList[CNUMOFCFGCOLORS+1], DefaultColorList[CNUMOFCFGCOLORS+1]; static void copyArray(Colors source[], Colors target[]) @@ -154,7 +154,7 @@ void GCColor::setupColors() { "", "", QColor(0,0,0) }, }; - // set the defaults to system detaults + // set the defaults to system defaults init[CCALCURRENT].color = QPalette().color(QPalette::Highlight); init[CTOOLBAR].color = QPalette().color(QPalette::Window); diff --git a/src/Computrainer.cpp b/src/Computrainer.cpp index 8b7a38242..f81716b74 100644 --- a/src/Computrainer.cpp +++ b/src/Computrainer.cpp @@ -505,7 +505,7 @@ void Computrainer::run() double curPower; // current output power in Watts double curHeartRate; // current heartrate in BPM double curCadence; // current cadence in RPM - double curSpeed; // current speef in KPH + double curSpeed; // current speed in KPH double curRRC; // calibrated Rolling Resistance bool curhrconnected; // is HR sensor connected? bool curcadconnected; // is CAD sensor connected? diff --git a/src/Computrainer.h b/src/Computrainer.h index 71e426590..790f308d5 100644 --- a/src/Computrainer.h +++ b/src/Computrainer.h @@ -171,7 +171,7 @@ private: volatile double devicePower; // current output power in Watts volatile double deviceHeartRate; // current heartrate in BPM volatile double deviceCadence; // current cadence in RPM - volatile double deviceSpeed; // current speef in KPH + volatile double deviceSpeed; // current speed in KPH volatile double deviceRRC; // calibrated Rolling Resistance volatile bool deviceCalibrated; // is it calibrated? volatile uint8_t spinScan[24]; // SS values only in SS_MODE diff --git a/src/ComputrainerController.cpp b/src/ComputrainerController.cpp index 38cd38057..b54a5b810 100644 --- a/src/ComputrainerController.cpp +++ b/src/ComputrainerController.cpp @@ -95,7 +95,7 @@ ComputrainerController::getRealtimeData(RealtimeData &rtData) myComputrainer->getTelemetry(Power, HeartRate, Cadence, Speed, RRC, calibration, Buttons, ss, Status); - // Check CT if F3 has been pressed for Calibration mode FIRST befoire we do anything else + // Check CT if F3 has been pressed for Calibration mode FIRST before we do anything else if (Buttons&CT_F3) { parent->Calibrate(); } @@ -128,7 +128,7 @@ ComputrainerController::getRealtimeData(RealtimeData &rtData) // ADJUST LOAD & GRADIENT Load = myComputrainer->getLoad(); Gradient = myComputrainer->getGradient(); - // the calls to the parent will determine which mode we are on (ERG/SPIN) and adjust load/slop appropiately + // the calls to the parent will determine which mode we are on (ERG/SPIN) and adjust load/slop appropriately if ((Buttons&CT_PLUS) && !(Buttons&CT_F3)) { parent->Higher(); } diff --git a/src/CriticalPowerWindow.cpp b/src/CriticalPowerWindow.cpp index daf19b845..0fb0749f3 100644 --- a/src/CriticalPowerWindow.cpp +++ b/src/CriticalPowerWindow.cpp @@ -419,7 +419,7 @@ CriticalPowerWindow::CriticalPowerWindow(Context *context, bool rangemode) : connect(context, SIGNAL(compareDateRangesStateChanged(bool)), SLOT(forceReplot())); connect(context, SIGNAL(compareDateRangesChanged()), SLOT(forceReplot())); } else { - // when working on a ride we can selecct intervals! + // when working on a ride we can select intervals! connect(cComboSeason, SIGNAL(currentIndexChanged(int)), this, SLOT(seasonSelected(int))); connect(context, SIGNAL(intervalSelected()), this, SLOT(intervalSelected())); connect(context, SIGNAL(intervalsChanged()), this, SLOT(intervalsChanged())); @@ -550,7 +550,7 @@ void CriticalPowerWindow::modelChanged() { // we changed from/to a 2 or 3 parameter model - // so lets set some semsible defaults, these are + // so lets set some sensible defaults, these are // based on advice from our exercise physiologist friends // for best results in predicting both W' and CP and providing // a reasonable fit for durations < 2mins. diff --git a/src/DBAccess.cpp b/src/DBAccess.cpp index 2c8c89549..5990dd5bc 100644 --- a/src/DBAccess.cpp +++ b/src/DBAccess.cpp @@ -79,7 +79,7 @@ // 57 20 Jan 2014 Mark Liversedge Added W' Expenditure for total energy spent above CP // 58 23 Jan 2014 Mark Liversedge W' work rename and calculate without reference to WPrime class (speed) // 59 24 Jan 2014 Mark Liversedge Added Maximum W' exp which is same as W'bal bur expressed as used not left -// 60 05 Feb 2014 Mark Liversedge Added Critical Power as a metric -- retreives from settings for now +// 60 05 Feb 2014 Mark Liversedge Added Critical Power as a metric -- retrieves from settings for now // 61 15 Feb 2014 Mark Liversedge Fixed W' Work (for recintsecs not 1s!). // 62 06 Mar 2014 Mark Liversedge Fixed Fatigue Index to find peak then watch for decay, primarily useful in sprint intervals // 63 06 Mar 2014 Mark Liversedge Added Pacing Index AP as %age of Max Power @@ -102,7 +102,7 @@ // 80 13 Jul 2014 Mark Liversedge W' work + Below CP work = Work // 81 16 Aug 2014 Joern Rischmueller Added 'Elevation Loss' // 82 23 Aug 2014 Mark Liversedge Added W'bal Matches -// 83 05 Sep 2014 Joern Rischmueler Added 'Time Carrying' and 'Elevation Gain Carrying' +// 83 05 Sep 2014 Joern Rischmueller Added 'Time Carrying' and 'Elevation Gain Carrying' // 84 08 Sep 2014 Mark Liversedge Added HrPw Ratio // 85 09 Sep 2014 Mark Liversedge Added HrNp Ratio // 86 26 Sep 2014 Mark Liversedge Added isRun first class var diff --git a/src/DialWindow.cpp b/src/DialWindow.cpp index b2869d989..aac878c48 100644 --- a/src/DialWindow.cpp +++ b/src/DialWindow.cpp @@ -563,7 +563,7 @@ void DialWindow::seriesChanged() break; } - // ugh. we use style sheets becuase palettes don't work on labels + // ugh. we use style sheets because palettes don't work on labels background = GColor(CTRAINPLOTBACKGROUND); setProperty("color", background); QString sh = QString("QLabel { background: %1; color: %2; }") diff --git a/src/DownloadRideDialog.cpp b/src/DownloadRideDialog.cpp index 6d5544b7d..3770b3ebc 100644 --- a/src/DownloadRideDialog.cpp +++ b/src/DownloadRideDialog.cpp @@ -412,10 +412,10 @@ DownloadRideDialog::downloadClicked() continue; } - // remove the tempoary download file after successfull creation/renaming (just in case) + // remove the temporary download file after successful creation/renaming (just in case) QFile::remove(files.at(i).name); - // File sucessfully downloaded and stored with proper extension - now convert to .JSON + // File successfully downloaded and stored with proper extension - now convert to .JSON QStringList errors; QFile currentFile(filepath); QString targetFileName; diff --git a/src/ExtendedCriticalPower.cpp b/src/ExtendedCriticalPower.cpp index 28c9682f9..4c91a85a3 100644 --- a/src/ExtendedCriticalPower.cpp +++ b/src/ExtendedCriticalPower.cpp @@ -56,7 +56,7 @@ ExtendedCriticalPower::deriveExtendedCP_2_3_Parameters(RideFileCache *bests, Rid const double t7 = laeI1; const double t8 = laeI2; - // bounds of these time valus in the data + // bounds of these time values in the data int i1, i2, i3, i4, i5, i6, i7, i8; // find the indexes associated with the bounds @@ -304,7 +304,7 @@ ExtendedCriticalPower::deriveExtendedCP_4_3_Parameters(bool usebest, RideFileCac const double t7 = laeI1; const double t8 = laeI2; - // bounds of these time valus in the data + // bounds of these time values in the data int i1, i2, i3, i4, i5, i6, i7, i8; // find the indexes associated with the bounds @@ -858,7 +858,7 @@ ExtendedCriticalPower::deriveExtendedCP_5_3_Parameters(bool usebest, RideFileCac const double t7 = laeI1; const double t8 = laeI2; - // bounds of these time valus in the data + // bounds of these time values in the data int i1, i2, i3, i4, i5, i6, i7, i8; // find the indexes associated with the bounds @@ -1373,7 +1373,7 @@ ExtendedCriticalPower::deriveExtendedCP_6_3_Parameters(bool usebest, RideFileCac const double t7 = laeI1; const double t8 = laeI2; - // bounds of these time valus in the data + // bounds of these time values in the data int i1, i2, i3, i4, i5, i6, i7, i8; // find the indexes associated with the bounds @@ -1793,7 +1793,7 @@ ExtendedCriticalPower::deriveDanVeloclinicCP_Parameters(bool usebest, RideFileCa const double t7 = laeI1; const double t8 = laeI2; - // bounds of these time valus in the data + // bounds of these time values in the data int i1, i2, i3, i4, i5, i6, i7, i8; // find the indexes associated with the bounds diff --git a/src/FixHRSpikes.cpp b/src/FixHRSpikes.cpp index 8a0a1c915..9a05f8071 100644 --- a/src/FixHRSpikes.cpp +++ b/src/FixHRSpikes.cpp @@ -143,7 +143,7 @@ FixHRSpikes::postProcess(RideFile *ride, DataProcessorConfig *config=0) double deltaHR = (ride->dataPoints()[i]->hr - ride->dataPoints()[lastgood]->hr) / double(i-lastgood); for (int j=lastgood+1; jcommand->setPointValue(j, RideFile::hr, ride->dataPoints()[lastgood]->hr + round(double(j-lastgood)*deltaHR)); spikes++; } diff --git a/src/Fortius.cpp b/src/Fortius.cpp index 618d03d2e..f9cdbb8b2 100644 --- a/src/Fortius.cpp +++ b/src/Fortius.cpp @@ -34,7 +34,7 @@ // 10 Calibration Value - Lo Byte // 11 Calibration High - Hi Byte -// Encoded Calibration is 130 x Callibration Value + 1040 so calibration of zero gives 0x0410 +// Encoded Calibration is 130 x Calibration Value + 1040 so calibration of zero gives 0x0410 const static uint8_t ergo_command[12] = { // 0 1 2 3 4 5 6 7 8 9 10 11 @@ -333,7 +333,7 @@ void Fortius::run() int curButtons; // Button status int curSteering; // Angle of steering controller // UNUSED int curStatus; - uint8_t pedalSensor; // 1 when using is cycling else 0, fed back to brake although appears unecessary + uint8_t pedalSensor; // 1 when using is cycling else 0, fed back to brake although appears unnecessary // we need to average out power for the last second // since we get updates every 10ms (100hz) @@ -551,8 +551,8 @@ int Fortius::sendRunCommand(int16_t pedalSensor) } else if (mode == FT_CALIBRATE) { - // Not yet implemented, easy enough to start callibration but appears that the callibration factor needs - // to be calculated by observing the brake power and speed after callibratio starts (i.e. it's not returned + // Not yet implemented, easy enough to start calibration but appears that the calibration factor needs + // to be calculated by observing the brake power and speed after calibration starts (i.e. it's not returned // by the brake). } diff --git a/src/GcCalendarModel.h b/src/GcCalendarModel.h index 53b83babd..ce22c5fc1 100644 --- a/src/GcCalendarModel.h +++ b/src/GcCalendarModel.h @@ -215,7 +215,7 @@ public: QModelIndex mapFromSource(const QModelIndex &sourceIndex) const { - return createIndex(sourceIndex.row(), sourceIndex.column(), (void *)NULL); // accomodate virtual column + return createIndex(sourceIndex.row(), sourceIndex.column(), (void *)NULL); // accommodate virtual column } // we override the standard version to make our virtual column zero diff --git a/src/GcToolBar.cpp b/src/GcToolBar.cpp index 447111a20..c8ae88c3c 100644 --- a/src/GcToolBar.cpp +++ b/src/GcToolBar.cpp @@ -68,7 +68,7 @@ GcToolBar::paintBackground(QPaintEvent *) painter.fillRect(all, linearGradient); if (!GCColor::isFlat()) { - // paint the botton lines + // paint the bottom lines QPen black(QColor(100,100,100)); painter.setPen(black); painter.drawLine(0,height()-1, width()-1, height()-1); diff --git a/src/GcUpgrade.cpp b/src/GcUpgrade.cpp index ef2892f83..2b256ec14 100644 --- a/src/GcUpgrade.cpp +++ b/src/GcUpgrade.cpp @@ -63,7 +63,7 @@ GcUpgrade::upgrade(const QDir &home) // Upgrade processing was introduced in Version 3 -- below must be performed // for athlete directories from prior to Version 3 // and can essentially be used as a template for all major release - // upgrades as it delets old stuff and sets clean + // upgrades as it deletes old stuff and sets clean //---------------------------------------------------------------------- // 3.0 upgrade processing @@ -502,7 +502,7 @@ GcUpgrade::upgrade(const QDir &home) .arg(QString::number(ok)).arg(newHome.workouts().dirName()).arg(QString::number(fail)),2); // the conversion of all activities to .json is done in "lateUpgrade" - since the prerequisites - // on the "context" setup are not fullfilled at this early stage + // on the "context" setup are not fulfilled at this early stage } @@ -557,7 +557,7 @@ GcUpgrade::upgradeLate(Context *context) okConvert++; upgradeLog->append(tr("-> Information: Activity %1 - Successfully converted to .JSON").arg(activitiesFileName)); - // copy source file to the /imports folder (only if conversion was successfull) + // copy source file to the /imports folder (only if conversion was successful) bool success = moveFile(QString("%1/%2").arg(context->athlete->home->root().canonicalPath()).arg(activitiesFileName), QString("%1/%2").arg(context->athlete->home->imports().canonicalPath()).arg(activitiesFileName)); if (success) { @@ -640,7 +640,7 @@ GcUpgrade::moveFile(const QString &source, const QString &target) { // just log, but not critical for the upgrade since the copy worked upgradeLog->append(QString(tr("-> Information: Deletion of copied file %1 failed" )).arg(source)); } - // even if remove failed, the copy was successfull - so GC is fine + // even if remove failed, the copy was successful - so GC is fine return true; } diff --git a/src/GoogleMapControl.cpp b/src/GoogleMapControl.cpp index 9f19a037a..57e0f9009 100644 --- a/src/GoogleMapControl.cpp +++ b/src/GoogleMapControl.cpp @@ -373,7 +373,7 @@ GoogleMapControl::drawShadedRoute() } // -// Static helper - havervine formaula for calculating the distance +// Static helper - havervine formula for calculating the distance // between 2 geo co-ordinates // static const double DEG_TO_RAD = 0.017453292519943295769236907684886; diff --git a/src/GpxParser.cpp b/src/GpxParser.cpp index 43c863cba..3b3fb9d62 100644 --- a/src/GpxParser.cpp +++ b/src/GpxParser.cpp @@ -156,7 +156,7 @@ bool return true; } // we need to figure out the distance by using the lon,lat - // using teh haversine formula + // using the haversine formula double r = 6371; double dlat = toRadians(lat -lastLat); // convert to radians diff --git a/src/HistogramWindow.cpp b/src/HistogramWindow.cpp index 125b43c7b..970fc8c8d 100644 --- a/src/HistogramWindow.cpp +++ b/src/HistogramWindow.cpp @@ -937,7 +937,7 @@ HistogramWindow::updateChart() if (rangemode) { - // set the date range to the appropiate selection + // set the date range to the appropriate selection DateRange use; if (useCustom) { @@ -1036,7 +1036,7 @@ HistogramWindow::updateChart() powerHist->recalc(true); // interval changed? force recalc powerHist->replot(); - interval = false;// we force a recalc whem called coz intervals + interval = false;// we force a recalc when called coz intervals // have been selected. The recalc routine in // powerhist optimises out, but doesn't keep track // of interval selection -- simplifies the setters diff --git a/src/HomeWindow.cpp b/src/HomeWindow.cpp index 77050a0ad..60af3ecfe 100644 --- a/src/HomeWindow.cpp +++ b/src/HomeWindow.cpp @@ -417,7 +417,7 @@ HomeWindow::styleChanged(int id) void HomeWindow::dragEnterEvent(QDragEnterEvent *) { -#if 0 // drah and drop chart no longer part of the UX +#if 0 // draw and drop chart no longer part of the UX if (event->mimeData()->formats().contains("application/x-qabstractitemmodeldatalist")) { event->accept(); dropPending = true; @@ -1081,7 +1081,7 @@ void GcWindowDialog::okClicked() { // give back to owner so we can re-use // note that in reject they are not and will - // get deleted (this has been verfied with + // get deleted (this has been verified with // some debug statements in ~GcWindow). // set its title property and geometry factors @@ -1143,7 +1143,7 @@ static QString unprotect(QString buffer) // html special chars are automatically handled // NOTE: other special characters will not work // cross-platform but will work locally, so not a biggie - // i.e. if thedefault charts.xml has a special character + // i.e. if the default charts.xml has a special character // in it it should be added here return s; } @@ -1332,7 +1332,7 @@ bool ViewParser::startElement( const QString&, const QString&, const QString &na if (type == "int") chart->setProperty(name.toLatin1(), QVariant(value.toInt())); if (type == "double") chart->setProperty(name.toLatin1(), QVariant(value.toDouble())); - // deprecate dateRange asa chart propert THAT IS DSAVED IN STATE + // deprecate dateRange asa chart property THAT IS DSAVED IN STATE if (type == "QString" && name != "dateRange") chart->setProperty(name.toLatin1(), QVariant(QString(value))); if (type == "QDate") chart->setProperty(name.toLatin1(), QVariant(QDate::fromString(value))); if (type == "bool") chart->setProperty(name.toLatin1(), QVariant(value.toInt() ? true : false)); diff --git a/src/IntervalNavigator.cpp b/src/IntervalNavigator.cpp index 933d75788..881a70ec0 100644 --- a/src/IntervalNavigator.cpp +++ b/src/IntervalNavigator.cpp @@ -485,7 +485,7 @@ IntervalNavigator::eventFilter(QObject *object, QEvent *e) // not for the table? if (object != (QObject *)tableView) return false; - // what happenned? + // what happened? switch(e->type()) { case QEvent::ContextMenu: @@ -688,7 +688,7 @@ IntervalNavigator::setColumnWidth(int x, bool resized, int logicalIndex, int old x -= tableView->verticalScrollBar()->width() + 0 ; #endif - // take the margins into accopunt top + // take the margins into account top x -= mainLayout->contentsMargins().left() + mainLayout->contentsMargins().right(); // ** NOTE ** @@ -938,7 +938,7 @@ IntervalNavigator::rideTreeSelectionChanged() QTreeWidgetItem *which; if (context->athlete->rideTreeWidget()->selectedItems().count()) which = context->athlete->rideTreeWidget()->selectedItems().first(); - else // no rides slected + else // no rides selected which = NULL; if (which && which->type() == RIDE_TYPE) { @@ -1035,7 +1035,7 @@ void IntervalNavigatorCellDelegate::paint(QPainter *painter, const QStyleOptionV const RideMetric *m; QString value; - // are we a selected cell ? need to paint acordingly + // are we a selected cell ? need to paint accordingly //bool selected = false; //if (IntervalNavigator->tableView->selectionModel()->selectedIndexes().count()) { // zero if no rides in list //if (IntervalNavigator->tableView->selectionModel()->selectedIndexes().value(0).row() == index.row()) @@ -1049,7 +1049,7 @@ void IntervalNavigatorCellDelegate::paint(QPainter *painter, const QStyleOptionV double metricValue = index.model()->data(index, Qt::DisplayRole).toDouble(); if (metricValue) { - // metric / imperial converstion + // metric / imperial conversion metricValue *= (intervalNavigator->context->athlete->useMetricUnits) ? 1 : m->conversion(); metricValue += (intervalNavigator->context->athlete->useMetricUnits) ? 0 : m->conversionSum(); diff --git a/src/IntervalNavigatorProxy.h b/src/IntervalNavigatorProxy.h index c2e869925..37d964442 100644 --- a/src/IntervalNavigatorProxy.h +++ b/src/IntervalNavigatorProxy.h @@ -166,7 +166,7 @@ public: } return sourceModel()->index(groupToSourceRow.value(groups[groupNo])->at(proxyIndex.row()), - proxyIndex.column()-2, // accomodate virtual columns + proxyIndex.column()-2, // accommodate virtual columns QModelIndex()); } return QModelIndex(); @@ -183,7 +183,7 @@ public: } else { QModelIndex *p = new QModelIndex(createIndex(groupNo, 0, (void*)NULL)); if (sourceIndex.row() > 0 && sourceIndex.row() < sourceRowToGroupRow.size()) - return createIndex(sourceRowToGroupRow[sourceIndex.row()], sourceIndex.column()+2, &p); // accomodate virtual columns + return createIndex(sourceRowToGroupRow[sourceIndex.row()], sourceIndex.column()+2, &p); // accommodate virtual columns else return QModelIndex(); } @@ -395,7 +395,7 @@ public: QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole ) const { if (section>1) - return sourceModel()->headerData(section-2, orientation, role); // accomodate virtual columns + return sourceModel()->headerData(section-2, orientation, role); // accommodate virtual columns else if (section == 1) // return header for virtual column ride_time return QVariant(starttimeHeader); else @@ -404,7 +404,7 @@ public: bool setHeaderData (int section, Qt::Orientation orientation, const QVariant & value, int role = Qt::EditRole) { if (section>1) - return sourceModel()->setHeaderData(section-2, orientation, value, role); // accomodate virtual columns + return sourceModel()->setHeaderData(section-2, orientation, value, role); // accommodate virtual columns else if (section == 1) // set header for virtual column ride_time starttimeHeader = value.toString(); @@ -412,7 +412,7 @@ public: } int columnCount(const QModelIndex &/*parent*/ = QModelIndex()) const { - return sourceModel()->columnCount(QModelIndex())+2; // accomodate virtual group column and starttime + return sourceModel()->columnCount(QModelIndex())+2; // accommodate virtual group column and starttime } int rowCount(const QModelIndex &parent = QModelIndex()) const { @@ -463,7 +463,7 @@ public: void setGroupBy(int column) { // shift down - if (column >= 0) column -= 2; // accomodate virtual column + if (column >= 0) column -= 2; // accommodate virtual column groupBy = column < 0 ? -1 : column; setGroups(); @@ -562,7 +562,7 @@ public slots: beginResetModel(); clearGroups(); - setGroupBy(groupBy+2); // accomodate virtual columns + setGroupBy(groupBy+2); // accommodate virtual columns endResetModel();// we're clean diff --git a/src/IntervalSummaryWindow.cpp b/src/IntervalSummaryWindow.cpp index c5469fb52..ff6e55776 100644 --- a/src/IntervalSummaryWindow.cpp +++ b/src/IntervalSummaryWindow.cpp @@ -93,7 +93,7 @@ IntervalSummaryWindow::intervalHover(RideFileInterval x) // if we're not visible don't bother if (!isVisible()) return; - // we already have summries! + // we already have summaries! if (context->athlete->intervalWidget->selectedItems().count()) return; QString html = GCColor::css(); diff --git a/src/LTMPlot.cpp b/src/LTMPlot.cpp index c2c9313c6..4ddb95fad 100644 --- a/src/LTMPlot.cpp +++ b/src/LTMPlot.cpp @@ -2493,7 +2493,7 @@ LTMPlot::createEstimateData(Context *context, LTMSettings *settings, MetricDetai // not the one we want if (model->code() != metricDetail.model) continue; - // set the paramters previously derived + // set the parameters previously derived model->loadParameters(est.parameters); // get the model estimate for our duration @@ -2838,7 +2838,7 @@ LTMPlot::pointHover(QwtPlotCurve *curve, int index) void LTMPlot::pointClicked(QwtPlotCurve *curve, int index) { - // do nothin on a compare chart + // do nothing on a compare chart if (parent->isCompare()) return; if (index >= 0 && curve != highlighter) { diff --git a/src/LTMSettings.cpp b/src/LTMSettings.cpp index 3c1aae263..f668de8ab 100644 --- a/src/LTMSettings.cpp +++ b/src/LTMSettings.cpp @@ -160,7 +160,7 @@ QDataStream &operator<<(QDataStream &out, const LTMSettings &settings) // 4.6 - 4.9 all the same out.setVersion(QDataStream::Qt_4_6); - // all the baisc fields first + // all the basic fields first out<notifyPresetsChanged(); } else { - // oops non existant - does this ever happen? + // oops non existent - does this ever happen? QMessageBox::warning( 0, tr("Entry Error"), QString(tr("Selected file (%1) does not exist")).arg(filenames[0])); } } diff --git a/src/LTMWindow.cpp b/src/LTMWindow.cpp index 8a523eb14..df848c9a7 100644 --- a/src/LTMWindow.cpp +++ b/src/LTMWindow.cpp @@ -358,7 +358,7 @@ LTMWindow::refreshCompare() } // now lets create them all again - // based upon the current setttings + // based upon the current settings // we create a plot for each curve // but where they are stacked we put // them all in the SAME plot @@ -467,7 +467,7 @@ LTMWindow::refreshStackPlots() } // now lets create them all again - // based upon the current setttings + // based upon the current settings // we create a plot for each curve // but where they are stacked we put // them all in the SAME plot @@ -868,7 +868,7 @@ LTMWindow::groupForDate(QDate date) void LTMWindow::pointClicked(QwtPlotCurve*curve, int index) { - // initialize date and time to sensefull boundaries + // initialize date and time to senseful boundaries QDate start = QDate(1900,1,1); QDate end = QDate(2999,12,31); QTime time = QTime(0, 0, 0, 0); @@ -1058,7 +1058,7 @@ LTMWindow::dataTable(bool html) // not the one we want if (model->code() != metricDetail.model) continue; - // set the paramters previously derived + // set the parameters previously derived model->loadParameters(est.parameters); // get the model estimate for our duration diff --git a/src/LibUsb.cpp b/src/LibUsb.cpp index 184963907..309aeb466 100644 --- a/src/LibUsb.cpp +++ b/src/LibUsb.cpp @@ -1,6 +1,6 @@ /* * Copyright (c) 2011 Darren Hague & Eric Brandt - * Modified to suport Linux and OSX by Mark Liversedge + * Modified to support Linux and OSX by Mark Liversedge * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the Free @@ -170,8 +170,8 @@ int LibUsb::write(char *buf, int bytes) rc = usb_interrupt_write(device, writeEndpoint, buf, bytes, 1000); } else { // we use a non-interrupted write on Linux/Mac since the interrupt - // write block size is incorectly implemented in the version of - // libusb we build with. It is no less efficent. + // write block size is incorrectly implemented in the version of + // libusb we build with. It is no less efficient. rc = usb_bulk_write(device, writeEndpoint, buf, bytes, 125); } diff --git a/src/LibUsb.h b/src/LibUsb.h index 89d4ad1ac..a68c6c81e 100644 --- a/src/LibUsb.h +++ b/src/LibUsb.h @@ -1,6 +1,6 @@ /* * Copyright (c) 2011 Darren Hague & Eric Brandt - * Modified to suport Linux and OSX by Mark Liversedge + * Modified to support Linux and OSX by Mark Liversedge * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License as published by the Free diff --git a/src/Library.cpp b/src/Library.cpp index 04d3bd83e..f09e093ff 100644 --- a/src/Library.cpp +++ b/src/Library.cpp @@ -405,7 +405,7 @@ LibrarySearchDialog::search() LibraryParser::serialize(context->athlete->home->root()); } - // ok, we;ve completed a search without aborting + // ok, we've completed a search without aborting // so lets rebuild the database of workouts and videos // using what we found... updateDB(); @@ -702,7 +702,7 @@ WorkoutImportDialog::WorkoutImportDialog(Context *context, QStringList files) : okButton = new QPushButton(tr("OK"), this); okButton->setDefault(true); - // if importing workoouts.. + // if importing workouts.. overwrite = new QCheckBox(tr("Overwite existing files"),this); if (!workouts.count()) overwrite->hide(); diff --git a/src/MergeActivityWizard.cpp b/src/MergeActivityWizard.cpp index 09e1f2dee..bb79aeb30 100644 --- a/src/MergeActivityWizard.cpp +++ b/src/MergeActivityWizard.cpp @@ -108,7 +108,7 @@ MergeActivityWizard::setRide(RideFile **here, RideFile *with) void MergeActivityWizard::analyse() { - // looking at the paramters determine the offset + // looking at the parameters determine the offset // default to align left if all else fails ! offset1 = offset2 = 0; diff --git a/src/MetricAggregator.cpp b/src/MetricAggregator.cpp index d27d5c942..e6ff08307 100644 --- a/src/MetricAggregator.cpp +++ b/src/MetricAggregator.cpp @@ -130,7 +130,7 @@ void MetricAggregator::refreshMetrics(QDateTime forceAfterThisDate) // begin LUW -- byproduct of turning off sync (nosync) dbaccess->connection().transaction(); - // Delete statistics for non-existant ride files + // Delete statistics for non-existent ride files QHash::iterator d; for (d = dbStatus.begin(); d != dbStatus.end(); ++d) { if (QFile(context->athlete->home->activities().canonicalPath() + "/" + d.key()).exists() == false) { diff --git a/src/ModelPlot.cpp b/src/ModelPlot.cpp index eea7467c3..ef0717270 100644 --- a/src/ModelPlot.cpp +++ b/src/ModelPlot.cpp @@ -365,7 +365,7 @@ ModelDataProvider::ModelDataProvider (ModelPlot &plot, ModelSettings *settings) if (cranklength == 0.0) cranklength = 0.175; // Run through the ridefile points putting the selected - // values into the approprate bins + // values into the appropriate bins settings->colorProvider->color.clear(); settings->colorProvider->num.clear(); settings->colorProvider->zonecolor.clear(); @@ -683,7 +683,7 @@ ModelDataProvider::ModelDataProvider (ModelPlot &plot, ModelSettings *settings) setDomain(maxbinx,minbinx,minbiny,maxbiny); // max x/y vals // set the barsize to a sensible radius (20% space) - // the +settting->xbin bit is to offset the additional mx/my bug + // the +setting->xbin bit is to offset the additional mx/my bug double xr = 0.8 * (((double)settings->xbin/((double)(maxbinx-minbinx)+(settings->xbin))) / 2.0); double yr = 0.8 * (((double)settings->ybin/((double)(maxbiny-minbiny)+(settings->ybin))) / 2.0); @@ -740,7 +740,7 @@ ModelDataProvider::ModelDataProvider (ModelPlot &plot, ModelSettings *settings) plot.setOrtho(false); plot.setSmoothMesh(true); - // cordinates - labels, gridlines, tic markers etc + // coordinates - labels, gridlines, tic markers etc if (settings->gridlines == true) plot.coordinates()->setGridLines(true, true, Qwt3D::BACK | Qwt3D::LEFT | Qwt3D::FLOOR); else diff --git a/src/OAuthDialog.cpp b/src/OAuthDialog.cpp index 91f417f41..3b1ccb1c2 100644 --- a/src/OAuthDialog.cpp +++ b/src/OAuthDialog.cpp @@ -66,7 +66,7 @@ OAuthDialog::OAuthDialog(Context *context, OAuthSite site) : reply = oauth_http_get(req_url,postarg); if (reply != NULL) { - // will split reply into paramters using strdup + // will split reply into parameters using strdup rc = oauth_split_url_parameters(reply, &rv); if (rc >= 3) { diff --git a/src/PDModel.cpp b/src/PDModel.cpp index 2f829a6a2..38c8c7ae2 100644 --- a/src/PDModel.cpp +++ b/src/PDModel.cpp @@ -107,7 +107,7 @@ PDModel::deriveCPParameters(bool three) const double t3 = aeI1; const double t4 = aeI2; - // bounds of these time valus in the data + // bounds of these time values in the data int i1, i2, i3, i4; // find the indexes associated with the bounds @@ -238,7 +238,7 @@ CP2Model::CP() void CP2Model::onDataChanged() { // calc tau etc and make sure the interval is - // set corretly - i.e. 'domain of validity' + // set correctly - i.e. 'domain of validity' deriveCPParameters(); setInterval(QwtInterval(tau, PDMODEL_MAXT)); @@ -309,7 +309,7 @@ CP3Model::PMax() void CP3Model::onDataChanged() { // calc tau etc and make sure the interval is - // set corretly - i.e. 'domain of validity' + // set correctly - i.e. 'domain of validity' deriveCPParameters(true); setInterval(QwtInterval(tau, PDMODEL_MAXT)); @@ -449,10 +449,10 @@ MultiModel::PMax() void MultiModel::onDataChanged() { // calc tau etc and make sure the interval is - // set corretly - i.e. 'domain of validity' + // set correctly - i.e. 'domain of validity' deriveCPParameters(true); - // and veloclinic paramters too; + // and veloclinic parameters too; w1 = cp*tau*60; // initial estimate from classic cp model p1 = PMax() - cp; p2 = cp; @@ -561,7 +561,7 @@ void ExtendedModel::onDataChanged() { // calc tau etc and make sure the interval is - // set corretly - i.e. 'domain of validity' + // set correctly - i.e. 'domain of validity' deriveExtCPParameters(); setInterval(QwtInterval(etau, PDMODEL_MAXT)); @@ -593,7 +593,7 @@ ExtendedModel::deriveExtCPParameters() const double t7 = laeI1; const double t8 = laeI2; - // bounds of these time valus in the data + // bounds of these time values in the data int i1, i2, i3, i4, i5, i6, i7, i8; // find the indexes associated with the bounds diff --git a/src/Pages.cpp b/src/Pages.cpp index 4f1b94153..7bf66bb6e 100644 --- a/src/Pages.cpp +++ b/src/Pages.cpp @@ -2362,7 +2362,7 @@ KeywordsPage::pageSelected() // load in texts from metadata fieldChooser->clear(); - // get the current fields defiitions + // get the current fields definitions QList fromFieldsPage; parent->fieldsPage->getDefinitions(fromFieldsPage); foreach(FieldDefinition x, fromFieldsPage) { diff --git a/src/PolarRideFile.cpp b/src/PolarRideFile.cpp index 96f078dec..a486bd9bb 100644 --- a/src/PolarRideFile.cpp +++ b/src/PolarRideFile.cpp @@ -231,7 +231,7 @@ this differently if (balance) { // Power LRB + PI: The value contains : // - Left Right Balance (LRB) and - // - Pedalling Index (PI) + // - Pedaling Index (PI) // // in the following formula: // value = PI * 256 + LRB PI bits 15-8 LRB bits 7-0 diff --git a/src/PowerHist.cpp b/src/PowerHist.cpp index c8ace0b92..32ce67d3b 100644 --- a/src/PowerHist.cpp +++ b/src/PowerHist.cpp @@ -515,13 +515,13 @@ PowerHist::recalcCompare() double low = high - round(binw/delta); if (low==0 && !withz) low++; parameterValue[i] = high*delta; - totalTime[i] = 1e-9; // nonzero to accomodate log plot + totalTime[i] = 1e-9; // nonzero to accommodate log plot while (low < high && lowvalue(this, GC_FONT_CHARTLABELS, QFont().toString()).toString()); labelFont.setPointSize(appsettings->value(NULL, GC_FONT_CHARTLABELS_SIZE, 8).toInt()); - // 0.625 = golden ratio for gaps betwen group of cols + // 0.625 = golden ratio for gaps between group of cols // 0.9 = 10% space between each col in group double width = (0.625 / ncols) * 0.90f; double jump = acol * (0.625 / ncols); - // we're not binning instead we are prettyfing the columnar + // we're not binning instead we are prettyfying the columnar // display in much the same way as the weekly summary workds // Each zone column will have 4 points QVector xaxis (array->size() * 4); @@ -1085,16 +1085,16 @@ PowerHist::binData(HistData &standard, QVector&x, // x-axis for data double low = high - round(binw/delta); if (low==0 && !withz) low++; x[i] = high*delta; - y[i] = 1e-9; // nonzero to accomodate log plot - sy[i] = 1e-9; // nonzero to accomodate log plot + y[i] = 1e-9; // nonzero to accommodate log plot + sy[i] = 1e-9; // nonzero to accommodate log plot while (low < high && lowlow) sy[i] += dt * (*selectedArray)[low]; y[i] += dt * (*array)[low++]; } } - y[i] = 1e-9; // nonzero to accomodate log plot - sy[i] = 1e-9; // nonzero to accomodate log plot + y[i] = 1e-9; // nonzero to accommodate log plot + sy[i] = 1e-9; // nonzero to accommodate log plot x[i] = i * delta * binw; y[0] = 1e-9; sy[0] = 1e-9; @@ -1669,7 +1669,7 @@ PowerHist::setData(QList&results, QString totalMetric, QString d // ignore out of bounds data if ((int)(v)max) continue; - // increment value, are intitialised to zero above + // increment value, are inititialised to zero above // there will be some loss of precision due to totalising // a double in an int, but frankly that should be minimal // since most values of note are integer based anyway. @@ -1687,7 +1687,7 @@ PowerHist::setData(QList&results, QString totalMetric, QString d // metrics across rides! curveSelected->hide(); - // now set all the plot paramaters to match the data + // now set all the plot parameters to match the data source = Metric; zoned = false; rideItem = NULL; diff --git a/src/RideEditor.cpp b/src/RideEditor.cpp index ba99e6058..121e28a80 100644 --- a/src/RideEditor.cpp +++ b/src/RideEditor.cpp @@ -486,7 +486,7 @@ AnomalyDialog::check() else rideEditor->checkAct->setEnabled(false); // redraw - even if no anomalies were found since - // some may have been highlighted previouslt. This is + // some may have been highlighted previously. This is // an expensive operation, but then so is the check() // function. rideEditor->model->forceRedraw(); @@ -501,7 +501,7 @@ RideEditor::eventFilter(QObject *object, QEvent *e) // not for the table? if (object != (QObject *)table) return false; - // what happenned? + // what happened? switch(e->type()) { case QEvent::ContextMenu: @@ -893,7 +893,7 @@ RideEditor::paste() ride->ride()->command->startLUW("Paste Cells"); for (int i=0; i ride->ride()->dataPoints().count()-1) break; for(int j=0; j >&cells, QStringList &seps, QString regexpStr = "["; foreach (QString sep, seps) regexpStr += sep; regexpStr += "]"; - QRegExp sep(regexpStr); // RegExp for seperators + QRegExp sep(regexpStr); // RegExp for separators QRegExp ELine(("\n|\r|\r\n")); //RegExp for line endings @@ -2157,7 +2157,7 @@ void PasteSpecialDialog::okClicked() { // headings has the headings for each column - // with "Ignore" set if we are to igmore it + // with "Ignore" set if we are to ignore it // cells contains all the actual data from the // buffer. // We have three modes; (1) insert means add new @@ -2321,7 +2321,7 @@ PasteSpecialDialog::okClicked() if (source.columns > target.columns) { truncate = true; } - // partially fill columnss ? + // partially fill columns ? if (source.columns < target.columns) { partial = true; target.columns = source.columns; diff --git a/src/RideFile.cpp b/src/RideFile.cpp index 2673ed3db..5a3f8a0a4 100644 --- a/src/RideFile.cpp +++ b/src/RideFile.cpp @@ -1317,7 +1317,7 @@ RideFile::getHeight() return height; } - // is withings upported for height? + // is withings supported for height? // global options height = appsettings->cvalue(context->athlete->cyclist, GC_HEIGHT, height_default).toString().toDouble(); @@ -1779,7 +1779,7 @@ RideFile::resample(double newRecIntSecs, int interpolate) } } - // lets not go backwards -- or two sampls at the same time + // lets not go backwards -- or two samples at the same time if ((lp && p->secs > lp->secs) || !lp) { points << QPointF(p->secs - offset, p->value(series)); last = p->secs-offset; diff --git a/src/RideFileCache.cpp b/src/RideFileCache.cpp index 41394bd22..b184eec62 100644 --- a/src/RideFileCache.cpp +++ b/src/RideFileCache.cpp @@ -1722,7 +1722,7 @@ void RideFileCache::doubleArray(QVector &into, QVector &from, Rid return; } -// for Distribution Series the values in Long/Float are ALWAYS Seconds (therefor no decimals adjustment calcuation required) +// for Distribution Series the values in Long/Float are ALWAYS Seconds (therefore no decimals adjustment calculation required) void RideFileCache::doubleArrayForDistribution(QVector &into, QVector &from) { into.resize(from.size()); @@ -1810,12 +1810,12 @@ RideFileCache::tiz(Context *context, QString filename, RideFile::SeriesType seri // and return as an array of SummaryMetrics. // // this is to 're-use' the metric api (especially in the LTM code) for passing back multiple -// bests across multiple rides in one object. We do this so we can optimise the read/seek acroos +// bests across multiple rides in one object. We do this so we can optimise the read/seek across // the CPX files within a single call. // // We order the bests requested in the order they will appear in the CPX file so we can open // and seek forward to each value before putting into the summary metric. Since it is placed -// on the stack as a return paramater we also don't need to worry about memory allocation just +// on the stack as a return parameter we also don't need to worry about memory allocation just // like the metric code works. // // diff --git a/src/RideImportWizard.cpp b/src/RideImportWizard.cpp index ab2c1f30d..4dcd6a62c 100644 --- a/src/RideImportWizard.cpp +++ b/src/RideImportWizard.cpp @@ -337,7 +337,7 @@ RideImportWizard::process() // set progress bar limits - for each file we // will make 5 passes over the files - // 1. checking it is a file ane readable + // 1. checking if a file is readable // 2. parsing it with the RideFileReader // 3. [optional] collect date/time information from user // 4. copy file into Library diff --git a/src/RideMetadata.cpp b/src/RideMetadata.cpp index 66f44a133..d99e82f1c 100644 --- a/src/RideMetadata.cpp +++ b/src/RideMetadata.cpp @@ -985,7 +985,7 @@ static QString unprotect(QString buffer) // html special chars are automatically handled // other special characters will not work // cross-platform but will work locally, so not a biggie - // i.e. if thedefault charts.xml has a special character + // i.e. if the default charts.xml has a special character // in it it should be added here return s; } diff --git a/src/RideNavigator.cpp b/src/RideNavigator.cpp index 31028e42b..33fa3689f 100644 --- a/src/RideNavigator.cpp +++ b/src/RideNavigator.cpp @@ -401,7 +401,7 @@ RideNavigator::eventFilter(QObject *object, QEvent *e) // not for the table? if (object != (QObject *)tableView) return false; - // what happenned? + // what happnned? switch(e->type()) { case QEvent::ContextMenu: @@ -609,7 +609,7 @@ RideNavigator::setColumnWidth(int x, bool resized, int logicalIndex, int oldWidt x -= tableView->verticalScrollBar()->width() + 0 ; #endif - // take the margins into accopunt top + // take the margins into account top x -= mainLayout->contentsMargins().left() + mainLayout->contentsMargins().right(); // ** NOTE ** @@ -956,7 +956,7 @@ RideNavigator::rideTreeSelectionChanged() QTreeWidgetItem *which; if (context->athlete->rideTreeWidget()->selectedItems().count()) which = context->athlete->rideTreeWidget()->selectedItems().first(); - else // no rides slected + else // no rides selected which = NULL; if (which && which->type() == RIDE_TYPE) { @@ -1053,7 +1053,7 @@ void NavigatorCellDelegate::paint(QPainter *painter, const QStyleOptionViewItem const RideMetric *m; QString value; - // are we a selected cell ? need to paint acordingly + // are we a selected cell ? need to paint accordingly //bool selected = false; //if (rideNavigator->tableView->selectionModel()->selectedIndexes().count()) { // zero if no rides in list //if (rideNavigator->tableView->selectionModel()->selectedIndexes().value(0).row() == index.row()) @@ -1067,7 +1067,7 @@ void NavigatorCellDelegate::paint(QPainter *painter, const QStyleOptionViewItem double metricValue = index.model()->data(index, Qt::DisplayRole).toDouble(); if (metricValue) { - // metric / imperial converstion + // metric / imperial conversion metricValue *= (rideNavigator->context->athlete->useMetricUnits) ? 1 : m->conversion(); metricValue += (rideNavigator->context->athlete->useMetricUnits) ? 0 : m->conversionSum(); diff --git a/src/RideNavigatorProxy.h b/src/RideNavigatorProxy.h index 31e1b96f6..cb5119547 100644 --- a/src/RideNavigatorProxy.h +++ b/src/RideNavigatorProxy.h @@ -176,7 +176,7 @@ public: } return sourceModel()->index(groupToSourceRow.value(groups[groupNo])->at(proxyIndex.row()), - proxyIndex.column()-2, // accomodate virtual columns + proxyIndex.column()-2, // accommodate virtual columns QModelIndex()); } return QModelIndex(); @@ -193,7 +193,7 @@ public: } else { QModelIndex *p = new QModelIndex(createIndex(groupNo, 0, (void*)NULL)); if (sourceIndex.row() > 0 && sourceIndex.row() < sourceRowToGroupRow.size()) - return createIndex(sourceRowToGroupRow[sourceIndex.row()], sourceIndex.column()+2, &p); // accomodate virtual columns + return createIndex(sourceRowToGroupRow[sourceIndex.row()], sourceIndex.column()+2, &p); // accommodate virtual columns else return QModelIndex(); } @@ -402,7 +402,7 @@ public: QVariant headerData (int section, Qt::Orientation orientation, int role = Qt::DisplayRole ) const { if (section>1) - return sourceModel()->headerData(section-2, orientation, role); // accomodate virtual columns + return sourceModel()->headerData(section-2, orientation, role); // accommodate virtual columns else if (section == 1) // return header for virtual column ride_time return QVariant(starttimeHeader); else @@ -411,7 +411,7 @@ public: bool setHeaderData (int section, Qt::Orientation orientation, const QVariant & value, int role = Qt::EditRole) { if (section>1) - return sourceModel()->setHeaderData(section-2, orientation, value, role); // accomodate virtual columns + return sourceModel()->setHeaderData(section-2, orientation, value, role); // accommodate virtual columns else if (section == 1) // set header for virtual column ride_time starttimeHeader = value.toString(); @@ -419,7 +419,7 @@ public: } int columnCount(const QModelIndex &/*parent*/ = QModelIndex()) const { - return sourceModel()->columnCount(QModelIndex())+2; // accomodate virtual group column and starttime + return sourceModel()->columnCount(QModelIndex())+2; // accommodate virtual group column and starttime } int rowCount(const QModelIndex &parent = QModelIndex()) const { @@ -470,7 +470,7 @@ public: void setGroupBy(int column) { // shift down - if (column >= 0) column -= 2; // accomodate virtual column + if (column >= 0) column -= 2; // accommodate virtual column groupBy = column < 0 ? -1 : column; setGroups(); @@ -480,7 +480,7 @@ public: if (row < 0 || row >= rankedRows.count()) return (""); if (groupBy == -1) return tr("All Rides"); - else return groupFromValue(headerData(groupBy+2, // accomodate virtual column + else return groupFromValue(headerData(groupBy+2, // accommodate virtual column Qt::Horizontal).toString(), sourceModel()->data(sourceModel()->index(row,groupBy)).toString(), rankedRows[row].value, rankedRows.count()); @@ -577,7 +577,7 @@ public slots: beginResetModel(); clearGroups(); - setGroupBy(groupBy+2); // accomodate virtual columns + setGroupBy(groupBy+2); // accommodate virtual columns endResetModel();// we're clean diff --git a/src/RideSummaryWindow.cpp b/src/RideSummaryWindow.cpp index 07c88e538..798746fb5 100644 --- a/src/RideSummaryWindow.cpp +++ b/src/RideSummaryWindow.cpp @@ -1214,7 +1214,7 @@ RideSummaryWindow::htmlSummary() summary += "
"; } - // sumarise errors reading file if it was a ride summary + // summarise errors reading file if it was a ride summary if (ridesummary && !rideItem->errors().empty()) { summary += tr("

Errors reading file:

    "); @@ -1596,7 +1596,7 @@ RideSummaryWindow::htmlCompareSummary() const } summary += ""; - // now the sumamry + // now the summary int counter = 0; int rows = 0; foreach (SummaryMetrics metrics, intervalMetrics) { @@ -1668,7 +1668,7 @@ RideSummaryWindow::htmlCompareSummary() const } summary += ""; - // now the sumamry + // now the summary int counter = 0; int rows = 0; foreach (SummaryMetrics metrics, intervalMetrics) { @@ -1864,7 +1864,7 @@ RideSummaryWindow::htmlCompareSummary() const } summary += ""; - // now the sumamry + // now the summary int counter = 0; foreach (CompareDateRange dr, context->compareDateRanges) { @@ -1936,7 +1936,7 @@ RideSummaryWindow::htmlCompareSummary() const } summary += ""; - // now the sumamry + // now the summary int counter = 0; foreach (CompareDateRange dr, context->compareDateRanges) { diff --git a/src/Route.cpp b/src/Route.cpp index ceee7a1dd..6b2c08872 100644 --- a/src/Route.cpp +++ b/src/Route.cpp @@ -157,7 +157,7 @@ RouteSegment::searchRouteInRide(RideFile* ride, bool freememory, QTextStream* ou // Valid GPS value if (start == -1) { diverge = 0; - // Calcul distance to route point + // Calculate distance to route point double _dist = distance(routepoint.lat, routepoint.lon, point->lat, point->lon) ; minimumdistance = _dist; @@ -242,7 +242,7 @@ RouteSegment::searchRouteInRide(RideFile* ride, bool freememory, QTextStream* ou } else { if (n == this->getPoints().count()-1){ // OK - //Add the interval and continu search + //Add the interval and continue search *out << " >>> Route identified in ride: " << name << " start: " << start << " stop: " << stop << " (distance " << precision << "km)\r\n"; this->addRideForRideFile(ride, start, stop, precision); candidate = true; diff --git a/src/RouteWindow.cpp b/src/RouteWindow.cpp index 8ca9be994..23d550bfc 100644 --- a/src/RouteWindow.cpp +++ b/src/RouteWindow.cpp @@ -93,7 +93,7 @@ RouteWindow::RouteWindow(Context *context) : - // now we're up and runnning lets connect the signals + // now we're up and running lets connect the signals connect(view, SIGNAL(loadStarted()), this, SLOT(loadStarted())); //connect(view, SIGNAL(loadFinished(bool)), this, SLOT(loadFinished(bool))); diff --git a/src/Serial.cpp b/src/Serial.cpp index d59ed21ad..1df83832d 100644 --- a/src/Serial.cpp +++ b/src/Serial.cpp @@ -389,7 +389,7 @@ find_devices(char *result[], int capacity) // /dev/ttyU[0-9] - Open BSD usb serial devices // /dev/ttyUSB[0-9] - Standard USB/Serial device on Linux/Mac // /dev/ttyS[0-2] - Serial TTY, 0-2 is restrictive, but noone has complained yet! - // /dev/ttyACM* - ACM converter, admittidly used largely for Mobiles + // /dev/ttyACM* - ACM converter, admittedly used largely for Mobiles // /dev/ttyMI* - MOXA PCI cards // /dev/rfcomm* - Bluetooth devices if (regcomp(®, diff --git a/src/Settings.cpp b/src/Settings.cpp index 989d55ed1..a5913cf80 100644 --- a/src/Settings.cpp +++ b/src/Settings.cpp @@ -40,5 +40,5 @@ GSettings::value(const QObject * /*me*/, const QString key, const QVariant def) // initialise with no cyclist -// as soon as a cyclist is opened it will be intialised via mainwindow +// as soon as a cyclist is opened it will be initialised via mainwindow GSettings *appsettings = GetApplicationSettings(); diff --git a/src/ShareDialog.cpp b/src/ShareDialog.cpp index b57beb6ac..bb4b98ff4 100644 --- a/src/ShareDialog.cpp +++ b/src/ShareDialog.cpp @@ -27,7 +27,7 @@ #include "VeloHeroUploader.h" #include "TrainingstagebuchUploader.h" -// acccess to metrics +// access to metrics #include "MetricAggregator.h" #include "RideMetric.h" #include "DBAccess.h" @@ -547,8 +547,8 @@ StravaUploader::requestUploadStravaFinished(QNetworkReply *reply) QString response = reply->readLine(); //qDebug() << response; - // use a lightweigth json parser to do this - QString uploadError="invalid reponse or parser error"; + // use a lightweight json parser to do this + QString uploadError="invalid response or parser error"; try { // parse ! diff --git a/src/SplitActivityWizard.cpp b/src/SplitActivityWizard.cpp index c903ac2d0..963372a32 100644 --- a/src/SplitActivityWizard.cpp +++ b/src/SplitActivityWizard.cpp @@ -54,7 +54,7 @@ SplitActivityWizard::SplitActivityWizard(Context *context) : QWizard(context->ma usedMinimumSegmentSize = usedMinimumGap = -1; // set initial intervals list, will be adjusted - // if the user modifies the default paramters + // if the user modifies the default parameters intervals = new QTreeWidget; intervals->headerItem()->setText(0, tr("")); intervals->headerItem()->setText(1, tr("Start")); @@ -503,7 +503,7 @@ SplitKeep::SplitKeep(SplitActivityWizard *parent) : QWizardPage(parent), wizard( connect(keepOriginal, SIGNAL(stateChanged(int)), this, SLOT(keepOriginalChanged())); } -// paramters +// parameters SplitParameters::SplitParameters(SplitActivityWizard *parent) : QWizardPage(parent), wizard(parent) { setTitle(tr("Split Parameters")); diff --git a/src/SummaryMetrics.cpp b/src/SummaryMetrics.cpp index ef031fdac..fdb825c48 100644 --- a/src/SummaryMetrics.cpp +++ b/src/SummaryMetrics.cpp @@ -73,7 +73,7 @@ SummaryMetrics::getForSymbol(QString symbol, bool metric) const QString SummaryMetrics::getStringForSymbol(QString symbol, bool UseMetric) const { - // get the value honoouring metric/imperial and with the right + // get the value honouring metric/imperial and with the right // number of decimal places. const RideMetric *m = metricForSymbol(symbol); diff --git a/src/TPDownload.cpp b/src/TPDownload.cpp index fd8baa8b9..56cdaf77f 100644 --- a/src/TPDownload.cpp +++ b/src/TPDownload.cpp @@ -76,7 +76,7 @@ void TPAthlete::getResponse(const QtSoapMessage &message) // lets take look at the payload as a DomDocument // I tried to use the QtSoapType routines to walk - // through the reponse tree but couldn't get them + // through the response tree but couldn't get them // to work. This code could be simplified if we // use the QtSoap routines instead. QDomDocument doc; @@ -151,7 +151,7 @@ void TPWorkout::getResponse(const QtSoapMessage &message) // lets take look at the payload as a DomDocument // I tried to use the QtSoapType routines to walk - // through the reponse tree but couldn't get them + // through the response tree but couldn't get them // to work. This code could be simplified if we // use the QtSoap routines instead. QDomDocument doc; diff --git a/src/TRIMPPoints.cpp b/src/TRIMPPoints.cpp index faa311432..4f46a927f 100644 --- a/src/TRIMPPoints.cpp +++ b/src/TRIMPPoints.cpp @@ -296,8 +296,8 @@ public: }; -// RPE is the rate of percieved exercion (borg scale). -// Is a numerical value the riders give in "average" fatigue of the training session he percieved. +// RPE is the rate of perceived exercion (borg scale). +// Is a numerical value the riders give in "average" fatigue of the training session he perceived. // // Calculate the session RPE that is the product of RPE * time (minutes) of training/race ride. I // We have 3 different "training load" parameters: diff --git a/src/TrainingstagebuchUploader.cpp b/src/TrainingstagebuchUploader.cpp index a80d1c6df..b9aa041b4 100644 --- a/src/TrainingstagebuchUploader.cpp +++ b/src/TrainingstagebuchUploader.cpp @@ -25,7 +25,7 @@ #include -// acccess to metrics +// access to metrics #include "PwxRideFile.h" /* diff --git a/src/TwitterDialog.h b/src/TwitterDialog.h index 0a31897b1..9dec0365e 100644 --- a/src/TwitterDialog.h +++ b/src/TwitterDialog.h @@ -32,7 +32,7 @@ #include "MainWindow.h" #include "RideItem.h" -// acccess to metrics +// access to metrics #include "RideMetric.h" #include "MetricAggregator.h" #include "DBAccess.h" diff --git a/src/TxtRideFile.cpp b/src/TxtRideFile.cpp index 716af7ea6..3e209fb3f 100644 --- a/src/TxtRideFile.cpp +++ b/src/TxtRideFile.cpp @@ -246,7 +246,7 @@ RideFile *TxtFileReader::openRideFile(QFile &file, QStringList &errors, QList -// acccess to metrics +// access to metrics #include "PwxRideFile.h" /* diff --git a/src/VideoWindow.cpp b/src/VideoWindow.cpp index 263a94990..43ee2475a 100644 --- a/src/VideoWindow.cpp +++ b/src/VideoWindow.cpp @@ -38,7 +38,7 @@ VideoWindow::VideoWindow(Context *context) : #warning "WARNING: Please ensure the VLC QT4 plugin (gui/libqt4_plugin) is NOT available as it will cause GC to crash." #endif - // config paramaters to libvlc + // config parameters to libvlc const char * const vlc_args[] = { "-I", "dummy", /* Don't use any interface */ "--ignore-config", /* Don't use VLC's config */ diff --git a/src/WPrime.cpp b/src/WPrime.cpp index 216e2ea7b..e62afd9d9 100644 --- a/src/WPrime.cpp +++ b/src/WPrime.cpp @@ -36,7 +36,7 @@ // into the future -- but crucially, no need to bother if power above CP is 0. // This typically reduces the cpu cycles by a factor of 4 // -// 2. Because the decay is calculated forward at time u we can do these in paralle; +// 2. Because the decay is calculated forward at time u we can do these in parallel; // i.e. run multiple threads for t=0 through t=time/nthreads. This reduced the // elapsed time by a factor of about 2/3rds on a dual core processor. // @@ -131,7 +131,7 @@ WPrime::setRide(RideFile *input) pointsd << QPointF(t-offset, p->km * convert); // not zero !!!! this is a map from secs -> km not a series } - // lets not go backwards -- or two sampls at the same time + // lets not go backwards -- or two samples at the same time if ((lp && p->secs > lp->secs) || !lp) { points << QPointF(p->secs - offset, p->watts); pointsd << QPointF(p->secs - offset, p->km * convert); @@ -252,7 +252,7 @@ WPrime::setRide(RideFile *input) } if (minY < -30000) minY = 0; // the data is definitely out of bounds! - // so lets not excacerbate the problem - truncate + // so lets not exacerbate the problem - truncate //qDebug()<<"compute W'bal curve took"<getWeight(); double ap = deps.value("average_power")->value(true); - // calclate watts per kilo + // calculate watts per kilo setCount(secs); setValue((secs && ap && weight) ? ap/weight : 0); }