MainWindow Refactor Part 1 of 5

Breaking the MainWindow 'god object' into
separate classes for Athlete and Context.

Further updates will need to;
- break MainWindow Gui elements into Toolbar and Views

- migrate from RideItem and Ridelist to ActivityCollection
  and Activity classes that are not tied into gui elements.

- introduce Application Context and AthleteCollection

Once these are done we will be in a position to decouple
most classes from mainwindow and also introduce tabbed
athletes.
This commit is contained in:
Mark Liversedge
2013-07-07 15:50:28 +01:00
parent 401957acf9
commit e407237ac0
106 changed files with 971 additions and 1091 deletions

View File

@@ -314,7 +314,7 @@ ModelDataProvider::ModelDataProvider (BasicModelPlot &plot, ModelSettings *setti
{
// get application settings
cranklength = appsettings->value(NULL, GC_CRANKLENGTH, 0.0).toDouble() / 1000.0;
useMetricUnits = plot.main->useMetricUnits;
useMetricUnits = plot.main->athlete->useMetricUnits;
// if there are no settings or incomplete settings
// create a null data plot
@@ -1006,7 +1006,7 @@ ModelPlot::ModelPlot(MainWindow *parent, ModelSettings *settings) : QFrame(paren
layout->setContentsMargins(2,2,2,2);
setLayout(layout);
connect(main, SIGNAL(configChanged()), basicModelPlot, SLOT(configChanged()));
connect(main->context, SIGNAL(configChanged()), basicModelPlot, SLOT(configChanged()));
}
void