fix 3d plot performance issues

Scrolling up and down the ride files is painfully slow when
3d is compiled in. This patch uses a setActive mechanism in
the same fashion as the pfpv and performance manager tabs.

Additionally, a recent patch to support user preferences for
units added a settings lookup that was called for every point.
This is also fixed.

fixes #16
This commit is contained in:
Mark Liversedge
2010-01-13 18:58:21 +00:00
committed by Sean Rhea
parent 195937f186
commit 4d1783276c
4 changed files with 29 additions and 19 deletions

View File

@@ -1185,6 +1185,9 @@ MainWindow::tabChanged(int index)
{
criticalPowerWindow->setActive(index == 2);
performanceManagerWindow->setActive(tabWidget->widget(index) == performanceManagerWindow);
#ifdef GC_HAVE_QWTPLOT3D
modelWindow->setActive(tabWidget->widget(index) == modelWindow);
#endif
}
void