aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/notifications_interface.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/kernel/notifications_interface.h')
-rw-r--r--src/kernel/notifications_interface.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/kernel/notifications_interface.h b/src/kernel/notifications_interface.h
index 7283a88e86..8e090dd7db 100644
--- a/src/kernel/notifications_interface.h
+++ b/src/kernel/notifications_interface.h
@@ -16,6 +16,8 @@ namespace kernel {
//! Result type for use with std::variant to indicate that an operation should be interrupted.
struct Interrupted{};
+enum class Warning;
+
//! Simple result type for functions that need to propagate an interrupt status and don't have other return values.
using InterruptResult = std::variant<std::monostate, Interrupted>;
@@ -38,7 +40,8 @@ public:
[[nodiscard]] virtual InterruptResult blockTip(SynchronizationState state, CBlockIndex& index) { return {}; }
virtual void headerTip(SynchronizationState state, int64_t height, int64_t timestamp, bool presync) {}
virtual void progress(const bilingual_str& title, int progress_percent, bool resume_possible) {}
- virtual void warning(const bilingual_str& warning) {}
+ virtual void warningSet(Warning id, const bilingual_str& message) {}
+ virtual void warningUnset(Warning id) {}
//! The flush error notification is sent to notify the user that an error
//! occurred while flushing block data to disk. Kernel code may ignore flush