aboutsummaryrefslogtreecommitdiff
path: root/src/common/settings_setting.h
diff options
context:
space:
mode:
authort895 <clombardo169@gmail.com>2023-12-10 20:10:36 -0500
committert895 <clombardo169@gmail.com>2023-12-12 17:25:36 -0500
commit10eee4c0c3e33835a33561484a605755f6ef4fc5 (patch)
tree19fa4ccec7477ca8b963885633004d76aaa00a52 /src/common/settings_setting.h
parentdf9e902105a36d4e6d7e964a45a5843dabc1a933 (diff)
android: Refactor settings to expose more options
In AbstractSetting, this removes the category, androidDefault, and valueAsString properties as they are no longer needed and have replacements. isSwitchable, global, and getValueAsString are all exposed and give better options for working with global/per-game settings.
Diffstat (limited to 'src/common/settings_setting.h')
-rw-r--r--src/common/settings_setting.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/common/settings_setting.h b/src/common/settings_setting.h
index 3175ab07d1..0b18ca5ecc 100644
--- a/src/common/settings_setting.h
+++ b/src/common/settings_setting.h
@@ -81,6 +81,9 @@ public:
[[nodiscard]] virtual const Type& GetValue() const {
return value;
}
+ [[nodiscard]] virtual const Type& GetValue(bool need_global) const {
+ return value;
+ }
/**
* Sets the setting to the given value.
@@ -353,7 +356,7 @@ public:
}
return custom;
}
- [[nodiscard]] const Type& GetValue(bool need_global) const {
+ [[nodiscard]] const Type& GetValue(bool need_global) const override final {
if (use_global || need_global) {
return this->value;
}