From 2d7be7a0e366b562fdff914e92219ab1852cd3c8 Mon Sep 17 00:00:00 2001 From: Berthold Stoeger Date: Tue, 24 Nov 2020 12:50:52 +0100 Subject: preferences: create global settingsChanged signal So far, the PreferencesDialog emitted a settingsChanged signal. This meant that models that listened to that signal had to conditionally compile out the code for mobile or the connection had to be made in MainWindow. Instead, introduce a global signal that does this and move the connects to the listeners to remove inter-dependencies. Signed-off-by: Berthold Stoeger --- core/subsurface-qt/divelistnotifier.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'core') diff --git a/core/subsurface-qt/divelistnotifier.h b/core/subsurface-qt/divelistnotifier.h index 2cd6eefcb..033458915 100644 --- a/core/subsurface-qt/divelistnotifier.h +++ b/core/subsurface-qt/divelistnotifier.h @@ -83,6 +83,9 @@ signals: // The core structures were completely reset. Repopulate all models. void dataReset(); + // The settings changed. Repopulate / rerender unit-dependent data, etc. + void settingsChanged(); + // Note that there are no signals for trips being added and created // because these events never happen without a dive being added, removed or moved. // The dives are always sorted according to the dives_less_than() function of the core. -- cgit v1.2.3-70-g09d2