summaryrefslogtreecommitdiffstats
path: root/core/subsurface-qt/divelistnotifier.h
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2020-03-03 22:42:51 +0100
committerGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2020-04-07 00:13:35 +0200
commit7018783f64f664af97032da4ba4d357c05b52aaf (patch)
tree7b9d8b3e6156be1fe63b9bbbf66c382071fe73ab /core/subsurface-qt/divelistnotifier.h
parent30c7499a3c656784cc45825b4b1b2fca61081308 (diff)
downloadsubsurface-7018783f64f664af97032da4ba4d357c05b52aaf.tar.gz
undo: replot profile if event changed
Add a DiveListNotifer::eventsChanged signal, which is emitted when the events changed. This is very coarse, at it doesn't differentiate between signal addition / editing / deletion. We might want to be finer in the future. Catch the signal in the profile-widget to replot the dive if this is the currently displayed dive. Reuse the cylindersChanged() slot, but rename it to the now more appropriate profileChanged(). Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'core/subsurface-qt/divelistnotifier.h')
-rw-r--r--core/subsurface-qt/divelistnotifier.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/core/subsurface-qt/divelistnotifier.h b/core/subsurface-qt/divelistnotifier.h
index 2a72cdf49..63355fbcc 100644
--- a/core/subsurface-qt/divelistnotifier.h
+++ b/core/subsurface-qt/divelistnotifier.h
@@ -113,6 +113,9 @@ signals:
void numShownChanged();
void filterReset();
+ // Event-related signals. Currently, we're very blunt: only one signal for any changes to the events.
+ void eventsChanged(dive *d);
+
// This signal is emited every time a command is executed.
// This is used to hide an old multi-dives-edited warning message.
// This is necessary, so that the user can't click on the "undo" button and undo