GB Core: Fix SGB border option breaking if changed while running

This commit is contained in:
Vicki Pfau 2017-09-07 22:05:11 -07:00
parent 13d3e1dfec
commit b750c76d02
1 changed files with 6 additions and 5 deletions

View File

@ -186,11 +186,7 @@ static void _GBCoreLoadConfig(struct mCore* core, const struct mCoreConfig* conf
mCoreConfigCopyValue(&core->config, config, "gb.model");
mCoreConfigCopyValue(&core->config, config, "sgb.model");
mCoreConfigCopyValue(&core->config, config, "cgb.model");
int fakeBool;
if (mCoreConfigGetIntValue(config, "sgb.borders", &fakeBool)) {
gb->video.sgbBorders = fakeBool;
}
mCoreConfigCopyValue(&core->config, config, "sgb.borders");
#if !defined(MINIMAL_CORE) || MINIMAL_CORE < 2
struct GBCore* gbcore = (struct GBCore*) core;
@ -349,6 +345,11 @@ static void _GBCoreReset(struct mCore* core) {
}
}
int fakeBool;
if (mCoreConfigGetIntValue(&core->config, "sgb.borders", &fakeBool)) {
gb->video.sgbBorders = fakeBool;
}
#if !defined(MINIMAL_CORE) || MINIMAL_CORE < 2
if (!gb->biosVf && core->opts.useBios) {
struct VFile* bios = NULL;