Fix addchart crash on empty homewindow

Silly bounds error when there are zero charts on
the homewindow.

Fixes #232.
This commit is contained in:
Mark Liversedge
2011-01-09 21:01:50 +00:00
parent 6fdffb5a4d
commit 63bc06d33f

View File

@@ -899,7 +899,7 @@ HomeWindow::drawCursor()
// lets draw at to the right of the
// last chart...
if (chartCursor == -1) {
if (chartCursor == -1 && charts.count()) {
// background light gray for now?
QRect line(charts[charts.count()-1]->geometry().x() + charts[charts.count()-1]->width() + 8,