From 45ef87954669c765cb7b317384066c6eb88dc5d3 Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Sun, 27 Jan 2019 22:08:13 +0100 Subject: Undo: update notes field if changed by undo commands To keep the UI in a consistent state, update the notes field if it is changed by an undo command. To that purpose, add a new signal to diveListNotifier with a list of dives and a field-id as payload. Signed-off-by: Berthold Stoeger --- desktop-widgets/tab-widgets/maintab.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'desktop-widgets/tab-widgets/maintab.h') diff --git a/desktop-widgets/tab-widgets/maintab.h b/desktop-widgets/tab-widgets/maintab.h index 00b94d1a0..e8fdd0ac4 100644 --- a/desktop-widgets/tab-widgets/maintab.h +++ b/desktop-widgets/tab-widgets/maintab.h @@ -17,6 +17,7 @@ #include "qt-models/completionmodels.h" #include "qt-models/divelocationmodel.h" #include "core/dive.h" +#include "core/subsurface-qt/DiveListNotifier.h" class WeightModel; class CylindersModel; @@ -62,9 +63,11 @@ signals: void diveSiteChanged(); public slots: + void divesEdited(const QVector &dives, DiveField field); void addCylinder_clicked(); void addWeight_clicked(); void updateDiveInfo(bool clear = false); + void updateNotes(const struct dive *d); void updateDepthDuration(); void acceptChanges(); void rejectChanges(); -- cgit v1.2.3-70-g09d2