From 1e9554145ef6b4d019ffb199dca1b37972d83066 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?kleines=20Filmr=C3=B6llchen?= Date: Sun, 21 Nov 2021 00:57:07 +0100 Subject: LibGUI: Add a cancel button callback to settings window tabs Some settings tabs, like the ones on the upcoming terminal settings, need to know when the cancel button is pressed to clean up things like temporary live updates. Therefore, the SettingsWindow::Tab now features a cancel_settings callback which does not need to be implemented. --- Userland/Libraries/LibGUI/SettingsWindow.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Userland/Libraries/LibGUI/SettingsWindow.h') diff --git a/Userland/Libraries/LibGUI/SettingsWindow.h b/Userland/Libraries/LibGUI/SettingsWindow.h index 96e897ac2c..f68d0922c7 100644 --- a/Userland/Libraries/LibGUI/SettingsWindow.h +++ b/Userland/Libraries/LibGUI/SettingsWindow.h @@ -20,7 +20,8 @@ public: class Tab : public GUI::Widget { public: virtual void apply_settings() = 0; - virtual void reset_default_values() {}; + virtual void cancel_settings() { } + virtual void reset_default_values() { } }; enum class ShowDefaultsButton { -- cgit v1.2.3