mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-13 19:49:51 +01:00
Update settings library version
This commit is contained in:
parent
633c9fa68b
commit
0718277271
|
@ -1 +1 @@
|
|||
Subproject commit ad31b38866d80a17ced902476ed06da69edce3a0
|
||||
Subproject commit 94edfacf14728faf3aa1d9c058e89395c97aae14
|
|
@ -21,20 +21,9 @@ public:
|
|||
_registerSetting(this->data);
|
||||
}
|
||||
|
||||
ChatterinoSetting &operator=(const Type &newValue)
|
||||
{
|
||||
assert(this->data != nullptr);
|
||||
|
||||
this->setValue(newValue);
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
template <typename T2>
|
||||
ChatterinoSetting &operator=(const T2 &newValue)
|
||||
{
|
||||
assert(this->data != nullptr);
|
||||
|
||||
this->setValue(newValue);
|
||||
|
||||
return *this;
|
||||
|
@ -42,33 +31,15 @@ public:
|
|||
|
||||
ChatterinoSetting &operator=(Type &&newValue) noexcept
|
||||
{
|
||||
assert(this->data != nullptr);
|
||||
|
||||
this->setValue(std::move(newValue));
|
||||
pajlada::Settings::Setting<Type>::operator=(newValue);
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
bool operator==(const Type &rhs) const
|
||||
{
|
||||
assert(this->data != nullptr);
|
||||
using pajlada::Settings::Setting<Type>::operator==;
|
||||
using pajlada::Settings::Setting<Type>::operator!=;
|
||||
|
||||
return this->getValue() == rhs;
|
||||
}
|
||||
|
||||
bool operator!=(const Type &rhs) const
|
||||
{
|
||||
assert(this->data != nullptr);
|
||||
|
||||
return this->getValue() != rhs;
|
||||
}
|
||||
|
||||
operator const Type() const
|
||||
{
|
||||
assert(this->data != nullptr);
|
||||
|
||||
return this->getValue();
|
||||
}
|
||||
using pajlada::Settings::Setting<Type>::operator const Type;
|
||||
};
|
||||
|
||||
} // namespace singletons
|
||||
|
|
Loading…
Reference in a new issue