summaryrefslogtreecommitdiff
path: root/src/common/settings_common.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/common/settings_common.h')
-rw-r--r--src/common/settings_common.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/common/settings_common.h b/src/common/settings_common.h
index 2efb329b0..1800ab10d 100644
--- a/src/common/settings_common.h
+++ b/src/common/settings_common.h
@@ -12,6 +12,7 @@
12namespace Settings { 12namespace Settings {
13 13
14enum class Category : u32 { 14enum class Category : u32 {
15 Android,
15 Audio, 16 Audio,
16 Core, 17 Core,
17 Cpu, 18 Cpu,
@@ -56,6 +57,7 @@ enum Specialization : u8 {
56 Scalar = 5, // Values are continuous 57 Scalar = 5, // Values are continuous
57 Countable = 6, // Can be stepped through 58 Countable = 6, // Can be stepped through
58 Paired = 7, // Another setting is associated with this setting 59 Paired = 7, // Another setting is associated with this setting
60 Radio = 8, // Setting should be presented in a radio group
59 61
60 Percentage = (1 << SpecializationAttributeOffset), // Should be represented as a percentage 62 Percentage = (1 << SpecializationAttributeOffset), // Should be represented as a percentage
61}; 63};
@@ -67,6 +69,7 @@ public:
67 explicit Linkage(u32 initial_count = 0); 69 explicit Linkage(u32 initial_count = 0);
68 ~Linkage(); 70 ~Linkage();
69 std::map<Category, std::vector<BasicSetting*>> by_category{}; 71 std::map<Category, std::vector<BasicSetting*>> by_category{};
72 std::map<std::string, Settings::BasicSetting*> by_key{};
70 std::vector<std::function<void()>> restore_functions{}; 73 std::vector<std::function<void()>> restore_functions{};
71 u32 count; 74 u32 count;
72}; 75};
@@ -222,6 +225,16 @@ public:
222 */ 225 */
223 [[nodiscard]] virtual constexpr u32 EnumIndex() const = 0; 226 [[nodiscard]] virtual constexpr u32 EnumIndex() const = 0;
224 227
228 /**
229 * @returns True if the underlying type is a floating point storage
230 */
231 [[nodiscard]] virtual constexpr bool IsFloatingPoint() const = 0;
232
233 /**
234 * @returns True if the underlying type is an integer storage
235 */
236 [[nodiscard]] virtual constexpr bool IsIntegral() const = 0;
237
225 /* 238 /*
226 * Switchable settings 239 * Switchable settings
227 */ 240 */