mirror of
https://git.suyu.dev/suyu/suyu.git
synced 2024-11-29 23:06:23 -05:00
settings_setting: Silence shadowing warnings
This commit is contained in:
parent
926f3e3d3e
commit
54d58130a0
1 changed files with 18 additions and 17 deletions
|
@ -35,12 +35,12 @@ public:
|
||||||
* @param category_ Category of the setting AKA INI group
|
* @param category_ Category of the setting AKA INI group
|
||||||
*/
|
*/
|
||||||
explicit Setting(Linkage& linkage, const Type& default_val, const std::string& name,
|
explicit Setting(Linkage& linkage, const Type& default_val, const std::string& name,
|
||||||
enum Category category_, u32 specialization = Specialization::Default,
|
enum Category category_, u32 specialization_ = Specialization::Default,
|
||||||
bool save_ = true, bool runtime_modifiable_ = false,
|
bool save_ = true, bool runtime_modifiable_ = false,
|
||||||
BasicSetting* other_setting = nullptr)
|
BasicSetting* other_setting_ = nullptr)
|
||||||
requires(!ranged)
|
requires(!ranged)
|
||||||
: BasicSetting(linkage, name, category_, save_, runtime_modifiable_, specialization,
|
: BasicSetting(linkage, name, category_, save_, runtime_modifiable_, specialization_,
|
||||||
other_setting),
|
other_setting_),
|
||||||
value{default_val}, default_value{default_val} {}
|
value{default_val}, default_value{default_val} {}
|
||||||
virtual ~Setting() = default;
|
virtual ~Setting() = default;
|
||||||
|
|
||||||
|
@ -56,11 +56,11 @@ public:
|
||||||
*/
|
*/
|
||||||
explicit Setting(Linkage& linkage, const Type& default_val, const Type& min_val,
|
explicit Setting(Linkage& linkage, const Type& default_val, const Type& min_val,
|
||||||
const Type& max_val, const std::string& name, enum Category category_,
|
const Type& max_val, const std::string& name, enum Category category_,
|
||||||
u32 specialization = Specialization::Default, bool save_ = true,
|
u32 specialization_ = Specialization::Default, bool save_ = true,
|
||||||
bool runtime_modifiable_ = false, BasicSetting* other_setting = nullptr)
|
bool runtime_modifiable_ = false, BasicSetting* other_setting_ = nullptr)
|
||||||
requires(ranged)
|
requires(ranged)
|
||||||
: BasicSetting(linkage, name, category_, save_, runtime_modifiable_, specialization,
|
: BasicSetting(linkage, name, category_, save_, runtime_modifiable_, specialization_,
|
||||||
other_setting),
|
other_setting_),
|
||||||
value{default_val}, default_value{default_val}, maximum{max_val}, minimum{min_val} {}
|
value{default_val}, default_value{default_val}, maximum{max_val}, minimum{min_val} {}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -235,13 +235,13 @@ public:
|
||||||
* @param category_ Category of the setting AKA INI group
|
* @param category_ Category of the setting AKA INI group
|
||||||
*/
|
*/
|
||||||
explicit SwitchableSetting(Linkage& linkage, const Type& default_val, const std::string& name,
|
explicit SwitchableSetting(Linkage& linkage, const Type& default_val, const std::string& name,
|
||||||
Category category_, u32 specialization = Specialization::Default,
|
Category category_, u32 specialization_ = Specialization::Default,
|
||||||
bool save_ = true, bool runtime_modifiable_ = false,
|
bool save_ = true, bool runtime_modifiable_ = false,
|
||||||
BasicSetting* other_setting = nullptr)
|
BasicSetting* other_setting_ = nullptr)
|
||||||
requires(!ranged)
|
requires(!ranged)
|
||||||
: Setting<Type, false>{
|
: Setting<Type, false>{
|
||||||
linkage, default_val, name, category_, specialization,
|
linkage, default_val, name, category_, specialization_,
|
||||||
save_, runtime_modifiable_, other_setting} {
|
save_, runtime_modifiable_, other_setting_} {
|
||||||
linkage.restore_functions.emplace_back([this]() { this->SetGlobal(true); });
|
linkage.restore_functions.emplace_back([this]() { this->SetGlobal(true); });
|
||||||
}
|
}
|
||||||
virtual ~SwitchableSetting() = default;
|
virtual ~SwitchableSetting() = default;
|
||||||
|
@ -258,13 +258,14 @@ public:
|
||||||
*/
|
*/
|
||||||
explicit SwitchableSetting(Linkage& linkage, const Type& default_val, const Type& min_val,
|
explicit SwitchableSetting(Linkage& linkage, const Type& default_val, const Type& min_val,
|
||||||
const Type& max_val, const std::string& name, Category category_,
|
const Type& max_val, const std::string& name, Category category_,
|
||||||
u32 specialization = Specialization::Default, bool save_ = true,
|
u32 specialization_ = Specialization::Default, bool save_ = true,
|
||||||
bool runtime_modifiable_ = false,
|
bool runtime_modifiable_ = false,
|
||||||
BasicSetting* other_setting = nullptr)
|
BasicSetting* other_setting_ = nullptr)
|
||||||
requires(ranged)
|
requires(ranged)
|
||||||
: Setting<Type, true>{
|
: Setting<Type, true>{linkage, default_val, min_val,
|
||||||
linkage, default_val, min_val, max_val, name, category_, specialization,
|
max_val, name, category_,
|
||||||
save_, runtime_modifiable_, other_setting} {
|
specialization_, save_, runtime_modifiable_,
|
||||||
|
other_setting_} {
|
||||||
linkage.restore_functions.emplace_back([this]() { this->SetGlobal(true); });
|
linkage.restore_functions.emplace_back([this]() { this->SetGlobal(true); });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue