summaryrefslogtreecommitdiffhomepage
path: root/options/base-value.hpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2018-10-25 18:01:20 +0200
committerStanislaw Halik <sthalik@misaki.pl>2018-10-25 18:27:42 +0200
commitc5db801886b22c3963689ee325ed7114ab94730d (patch)
tree55119b016fbebc2efe3d6b99bafafce1c78fa491 /options/base-value.hpp
parent83867b413c449101bbe14615ff857a7785432ede (diff)
options/value-traits: fix bool storage
Using int as `stored_type' for bool made Qt signals not work. Evident when ticking the "asymmetric mapping" checkboxes in the mapping window. Remove some std::decay_t usage, there's no need for either decay or remove_cvref. In `value<t>::get()', `bundle::get_variant' of an undefined key will fall back to `return def' so remove the duplicate logic.
Diffstat (limited to 'options/base-value.hpp')
-rw-r--r--options/base-value.hpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/options/base-value.hpp b/options/base-value.hpp
index 6a4709ee..14eaeb10 100644
--- a/options/base-value.hpp
+++ b/options/base-value.hpp
@@ -43,8 +43,6 @@ public:
return static_cast<signal_sig<t>>(&value_::valueChanged);
}
- void notify() const;
-
signals:
OTR_OPTIONS_SIGNAL(double);
OTR_OPTIONS_SIGNAL(float);
@@ -96,6 +94,8 @@ public slots:
virtual void bundle_value_changed() const = 0;
virtual void set_to_default() = 0;
+ void notify() const;
+
friend void ::options::detail::set_value_to_default(value_* val);
};