From e2ee6d6d254285284f07b07cb60409fbda0bf7ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=20Mr=C3=A1zek?= Date: Tue, 16 Jul 2013 00:30:32 +0200 Subject: Finalize the instance settings dialog, add setting reset mechanism --- libsettings/include/setting.h | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'libsettings/include/setting.h') diff --git a/libsettings/include/setting.h b/libsettings/include/setting.h index 36709729..a161ab50 100644 --- a/libsettings/include/setting.h +++ b/libsettings/include/setting.h @@ -84,6 +84,12 @@ signals: */ void settingChanged(const Setting &setting, QVariant value); + /*! + * \brief Signal emitted when this Setting object's value resets to default. + * \param setting A reference to the Setting that changed. + */ + void settingReset(const Setting &setting); + public slots: /*! * \brief Changes the setting's value. @@ -93,6 +99,13 @@ public slots: */ virtual void set(QVariant value); + /*! + * \brief Reset the setting to default + * This is done by emitting the settingReset() signal which will then be + * handled by the SettingsObject object and cause the setting to change. + * \param value The new value. + */ + virtual void reset(); protected: QString m_id; QVariant m_defVal; -- cgit v1.2.3