From 2f5223035a9d43b933b0baf64823dab84b5d8cea Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Wed, 27 May 2020 09:31:26 +0200 Subject: filter: add filter preset undo commands Add undo commands to add / edit / delete filter presets. These are styled after the other undo commands: On changes, the UI is informed by DiveListNotifier signals. Editing is a simple std::swap of values. Signed-off-by: Berthold Stoeger --- core/subsurface-qt/divelistnotifier.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'core') diff --git a/core/subsurface-qt/divelistnotifier.h b/core/subsurface-qt/divelistnotifier.h index aa82a4bef..eb44d6cde 100644 --- a/core/subsurface-qt/divelistnotifier.h +++ b/core/subsurface-qt/divelistnotifier.h @@ -125,6 +125,11 @@ signals: void picturesRemoved(dive *d, QVector filenames); void picturesAdded(dive *d, QVector pics); + // Filter related signals + void filterPresetAdded(int index); + void filterPresetRemoved(int index); + void filterPresetChanged(int index); + // 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 -- cgit v1.2.3-70-g09d2