mirror of https://github.com/mgba-emu/mgba.git
GBA Config: Add GBAConfigGetValue
This commit is contained in:
parent
37212c1f23
commit
19346dff87
|
@ -100,6 +100,10 @@ bool GBAConfigSave(const struct GBAConfig* config) {
|
||||||
return ConfigurationWrite(&config->configTable, BINARY_NAME ".ini");
|
return ConfigurationWrite(&config->configTable, BINARY_NAME ".ini");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const char* GBAConfigGetValue(const struct GBAConfig* config, const char* key) {
|
||||||
|
return _lookupValue(config, key);
|
||||||
|
}
|
||||||
|
|
||||||
void GBAConfigSetValue(struct GBAConfig* config, const char* key, const char* value) {
|
void GBAConfigSetValue(struct GBAConfig* config, const char* key, const char* value) {
|
||||||
ConfigurationSetValue(&config->configTable, config->port, key, value);
|
ConfigurationSetValue(&config->configTable, config->port, key, value);
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,6 +34,8 @@ void GBAConfigDeinit(struct GBAConfig*);
|
||||||
bool GBAConfigLoad(struct GBAConfig*);
|
bool GBAConfigLoad(struct GBAConfig*);
|
||||||
bool GBAConfigSave(const struct GBAConfig*);
|
bool GBAConfigSave(const struct GBAConfig*);
|
||||||
|
|
||||||
|
const char* GBAConfigGetValue(const struct GBAConfig*, const char* key);
|
||||||
|
|
||||||
void GBAConfigSetValue(struct GBAConfig*, const char* key, const char* value);
|
void GBAConfigSetValue(struct GBAConfig*, const char* key, const char* value);
|
||||||
void GBAConfigSetIntValue(struct GBAConfig*, const char* key, int value);
|
void GBAConfigSetIntValue(struct GBAConfig*, const char* key, int value);
|
||||||
void GBAConfigSetUIntValue(struct GBAConfig*, const char* key, unsigned value);
|
void GBAConfigSetUIntValue(struct GBAConfig*, const char* key, unsigned value);
|
||||||
|
|
Loading…
Reference in New Issue