| 44 | } |
| 45 | |
| 46 | bool MemorySettingsInterface::GetUIntValue(const char* section, const char* key, u32* value) const |
| 47 | { |
| 48 | const auto sit = m_sections.find(section); |
| 49 | if (sit == m_sections.end()) |
| 50 | return false; |
| 51 | |
| 52 | const auto iter = sit->second.find(key); |
| 53 | if (iter == sit->second.end()) |
| 54 | return false; |
| 55 | |
| 56 | std::optional<u32> parsed = StringUtil::FromChars<u32>(iter->second, 10); |
| 57 | if (!parsed.has_value()) |
| 58 | return false; |
| 59 | |
| 60 | *value = parsed.value(); |
| 61 | return true; |
| 62 | } |
| 63 | |
| 64 | bool MemorySettingsInterface::GetFloatValue(const char* section, const char* key, float* value) const |
| 65 | { |