diff options
Diffstat (limited to 'qt-ui/profilegraphics.cpp')
-rw-r--r-- | qt-ui/profilegraphics.cpp | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/qt-ui/profilegraphics.cpp b/qt-ui/profilegraphics.cpp index deef8a9d5..722cea6bd 100644 --- a/qt-ui/profilegraphics.cpp +++ b/qt-ui/profilegraphics.cpp @@ -220,14 +220,19 @@ void ProfileGraphicsView::clear() toolTip = 0; } -void ProfileGraphicsView::plot(struct dive *d) +void ProfileGraphicsView::refresh() +{ + plot(current_dive, TRUE); +} + +void ProfileGraphicsView::plot(struct dive *d, bool forceRedraw) { struct divecomputer *dc; if (d) dc = select_dc(&d->dc); - if (dive == d && (d && dc == diveDC)) + if (!forceRedraw && dive == d && (d && dc == diveDC)) return; clear(); |