break out enums from Config.cs

This commit is contained in:
adelikat 2020-01-21 08:05:56 -06:00
parent 679efd91c4
commit 3d833af617
15 changed files with 116 additions and 110 deletions

View File

@ -16,8 +16,8 @@ namespace BizHawk.Client.Common
// the old method of text savestate save is now gone. // the old method of text savestate save is now gone.
// a text savestate is just like a binary savestate, but with a different core lump // a text savestate is just like a binary savestate, but with a different core lump
using var bs = new BinaryStateSaver(filename); using var bs = new BinaryStateSaver(filename);
if (Global.Config.SaveStateType == Config.SaveStateTypeE.Text if (Global.Config.SaveStateType == SaveStateTypeE.Text
|| (Global.Config.SaveStateType == Config.SaveStateTypeE.Default && !core.BinarySaveStatesPreferred)) || (Global.Config.SaveStateType == SaveStateTypeE.Default && !core.BinarySaveStatesPreferred))
{ {
// text savestate format // text savestate format
using (new SimpleTime("Save Core")) using (new SimpleTime("Save Core"))

View File

@ -122,55 +122,13 @@ namespace BizHawk.Client.Common
/// </summary> /// </summary>
public int FlushSaveRamFrames; public int FlushSaveRamFrames;
public enum ELuaEngine
{
/// <remarks>Don't change this member's ordinal (don't reorder) without changing <c>BizHawk.Client.EmuHawk.Program.CurrentDomain_AssemblyResolve</c></remarks>
LuaPlusLuaInterface,
NLuaPlusKopiLua
}
/// <remarks>Don't rename this without changing <c>BizHawk.Client.EmuHawk.Program.CurrentDomain_AssemblyResolve</c></remarks> /// <remarks>Don't rename this without changing <c>BizHawk.Client.EmuHawk.Program.CurrentDomain_AssemblyResolve</c></remarks>
public ELuaEngine LuaEngine = ELuaEngine.LuaPlusLuaInterface; public ELuaEngine LuaEngine = ELuaEngine.LuaPlusLuaInterface;
public bool TurboSeek { get; set; } public bool TurboSeek { get; set; }
public enum EDispMethod
{
OpenGL, GdiPlus, SlimDX9
}
public enum ESoundOutputMethod
{
DirectSound, XAudio2, OpenAL, Dummy
}
public enum EDispManagerAR
{
None,
System,
// actually, custom SIZE (fixme on major release)
Custom,
CustomRatio
}
public enum SaveStateTypeE
{
Default, Binary, Text
}
public MovieEndAction MovieEndAction = MovieEndAction.Finish; public MovieEndAction MovieEndAction = MovieEndAction.Finish;
public enum ClientProfile
{
Unknown = 0,
Casual = 1,
Longplay = 2,
Tas = 3,
N64Tas = 4,
Custom = 99
}
public ClientProfile SelectedProfile = ClientProfile.Unknown; public ClientProfile SelectedProfile = ClientProfile.Unknown;
// N64 // N64

View File

@ -0,0 +1,44 @@
namespace BizHawk.Client.Common
{
public enum ELuaEngine
{
/// <remarks>Don't change this member's ordinal (don't reorder) without changing <c>BizHawk.Client.EmuHawk.Program.CurrentDomain_AssemblyResolve</c></remarks>
LuaPlusLuaInterface,
NLuaPlusKopiLua
}
public enum EDispMethod
{
OpenGL, GdiPlus, SlimDX9
}
public enum ESoundOutputMethod
{
DirectSound, XAudio2, OpenAL, Dummy
}
public enum EDispManagerAR
{
None,
System,
// actually, custom SIZE (fixme on major release)
Custom,
CustomRatio
}
public enum SaveStateTypeE
{
Default, Binary, Text
}
public enum ClientProfile
{
Unknown = 0,
Casual = 1,
Longplay = 2,
Tas = 3,
N64Tas = 4,
Custom = 99
}
}

View File

@ -515,9 +515,9 @@ namespace BizHawk.Client.EmuHawk
public Size CalculateClientSize(IVideoProvider videoProvider, int zoom) public Size CalculateClientSize(IVideoProvider videoProvider, int zoom)
{ {
bool arActive = Global.Config.DispFixAspectRatio; bool arActive = Global.Config.DispFixAspectRatio;
bool arSystem = Global.Config.DispManagerAR == Config.EDispManagerAR.System; bool arSystem = Global.Config.DispManagerAR == EDispManagerAR.System;
bool arCustom = Global.Config.DispManagerAR == Config.EDispManagerAR.Custom; bool arCustom = Global.Config.DispManagerAR == EDispManagerAR.Custom;
bool arCustomRatio = Global.Config.DispManagerAR == Config.EDispManagerAR.CustomRatio; bool arCustomRatio = Global.Config.DispManagerAR == EDispManagerAR.CustomRatio;
bool arCorrect = arSystem || arCustom || arCustomRatio; bool arCorrect = arSystem || arCustom || arCustomRatio;
bool arInteger = Global.Config.DispFixScaleInteger; bool arInteger = Global.Config.DispFixScaleInteger;
@ -706,17 +706,17 @@ namespace BizHawk.Client.EmuHawk
if (Global.Config.DispFixAspectRatio) if (Global.Config.DispFixAspectRatio)
{ {
if (Global.Config.DispManagerAR == Config.EDispManagerAR.System) if (Global.Config.DispManagerAR == EDispManagerAR.System)
{ {
vw = videoProvider.VirtualWidth; vw = videoProvider.VirtualWidth;
vh = videoProvider.VirtualHeight; vh = videoProvider.VirtualHeight;
} }
if (Global.Config.DispManagerAR == Config.EDispManagerAR.Custom) if (Global.Config.DispManagerAR == EDispManagerAR.Custom)
{ {
vw = Global.Config.DispCustomUserARWidth; vw = Global.Config.DispCustomUserARWidth;
vh = Global.Config.DispCustomUserARHeight; vh = Global.Config.DispCustomUserARHeight;
} }
if (Global.Config.DispManagerAR == Config.EDispManagerAR.CustomRatio) if (Global.Config.DispManagerAR == EDispManagerAR.CustomRatio)
{ {
FixRatio(Global.Config.DispCustomUserARX, Global.Config.DispCustomUserARY, videoProvider.BufferWidth, videoProvider.BufferHeight, out vw, out vh); FixRatio(Global.Config.DispCustomUserARX, Global.Config.DispCustomUserARY, videoProvider.BufferWidth, videoProvider.BufferHeight, out vw, out vh);
} }

View File

@ -3148,13 +3148,13 @@ namespace BizHawk.Client.EmuHawk
SavestateTextContextMenuItem.Checked = false; SavestateTextContextMenuItem.Checked = false;
switch (Config.SaveStateType) switch (Config.SaveStateType)
{ {
case Config.SaveStateTypeE.Binary: case SaveStateTypeE.Binary:
SavestateBinaryContextMenuItem.Checked = true; SavestateBinaryContextMenuItem.Checked = true;
break; break;
case Config.SaveStateTypeE.Text: case SaveStateTypeE.Text:
SavestateTextContextMenuItem.Checked = true; SavestateTextContextMenuItem.Checked = true;
break; break;
case Config.SaveStateTypeE.Default: case SaveStateTypeE.Default:
SavestateTypeDefaultContextMenuItem.Checked = true; SavestateTypeDefaultContextMenuItem.Checked = true;
break; break;
} }

View File

@ -339,14 +339,14 @@ namespace BizHawk.Client.EmuHawk
catch catch
{ {
string message = "Couldn't initialize sound device! Try changing the output method in Sound config."; string message = "Couldn't initialize sound device! Try changing the output method in Sound config.";
if (Config.SoundOutputMethod == Config.ESoundOutputMethod.DirectSound) if (Config.SoundOutputMethod == ESoundOutputMethod.DirectSound)
{ {
message = "Couldn't initialize DirectSound! Things may go poorly for you. Try changing your sound driver to 44.1khz instead of 48khz in mmsys.cpl."; message = "Couldn't initialize DirectSound! Things may go poorly for you. Try changing your sound driver to 44.1khz instead of 48khz in mmsys.cpl.";
} }
MessageBox.Show(message, "Initialization Error", MessageBoxButtons.OK, MessageBoxIcon.Error); MessageBox.Show(message, "Initialization Error", MessageBoxButtons.OK, MessageBoxIcon.Error);
Config.SoundOutputMethod = Config.ESoundOutputMethod.Dummy; Config.SoundOutputMethod = ESoundOutputMethod.Dummy;
GlobalWin.Sound = new Sound(Handle); GlobalWin.Sound = new Sound(Handle);
} }
@ -1190,7 +1190,7 @@ namespace BizHawk.Client.EmuHawk
// Please note: It is important to do this before resizing things, otherwise momentarily a GL control without WS_BORDER will be at the magic dimensions and cause the flakeout // Please note: It is important to do this before resizing things, otherwise momentarily a GL control without WS_BORDER will be at the magic dimensions and cause the flakeout
if (!OSTailoredCode.IsUnixHost if (!OSTailoredCode.IsUnixHost
&& Config.DispFullscreenHacks && Config.DispFullscreenHacks
&& Config.DispMethod == Config.EDispMethod.OpenGL) && Config.DispMethod == EDispMethod.OpenGL)
{ {
// ATTENTION: this causes the StatusBar to not work well, since the backcolor is now set to black instead of SystemColors.Control. // ATTENTION: this causes the StatusBar to not work well, since the backcolor is now set to black instead of SystemColors.Control.
// It seems that some StatusBar elements composite with the backcolor. // It seems that some StatusBar elements composite with the backcolor.

View File

@ -126,7 +126,7 @@ namespace BizHawk.Client.EmuHawk
// super hacky! this needs to be done first. still not worth the trouble to make this system fully proper // super hacky! this needs to be done first. still not worth the trouble to make this system fully proper
if (Array.Exists(args, arg => arg.StartsWith("--gdi", StringComparison.InvariantCultureIgnoreCase))) if (Array.Exists(args, arg => arg.StartsWith("--gdi", StringComparison.InvariantCultureIgnoreCase)))
{ {
Global.Config.DispMethod = Config.EDispMethod.GdiPlus; Global.Config.DispMethod = EDispMethod.GdiPlus;
} }
// create IGL context. we do this whether or not the user has selected OpenGL, so that we can run opengl-based emulator cores // create IGL context. we do this whether or not the user has selected OpenGL, so that we can run opengl-based emulator cores
@ -138,11 +138,11 @@ namespace BizHawk.Client.EmuHawk
//now create the "GL" context for the display method. we can reuse the IGL_TK context if opengl display method is chosen //now create the "GL" context for the display method. we can reuse the IGL_TK context if opengl display method is chosen
REDO_DISPMETHOD: REDO_DISPMETHOD:
if (Global.Config.DispMethod == Config.EDispMethod.GdiPlus) if (Global.Config.DispMethod == EDispMethod.GdiPlus)
{ {
GlobalWin.GL = new Bizware.BizwareGL.Drivers.GdiPlus.IGL_GdiPlus(); GlobalWin.GL = new Bizware.BizwareGL.Drivers.GdiPlus.IGL_GdiPlus();
} }
else if (Global.Config.DispMethod == Config.EDispMethod.SlimDX9) else if (Global.Config.DispMethod == EDispMethod.SlimDX9)
{ {
try try
{ {
@ -153,7 +153,7 @@ namespace BizHawk.Client.EmuHawk
new ExceptionBox(new Exception("Initialization of Direct3d 9 Display Method failed; falling back to GDI+", ex)).ShowDialog(); new ExceptionBox(new Exception("Initialization of Direct3d 9 Display Method failed; falling back to GDI+", ex)).ShowDialog();
// fallback // fallback
Global.Config.DispMethod = Config.EDispMethod.GdiPlus; Global.Config.DispMethod = EDispMethod.GdiPlus;
goto REDO_DISPMETHOD; goto REDO_DISPMETHOD;
} }
} }
@ -165,7 +165,7 @@ namespace BizHawk.Client.EmuHawk
if (GlobalWin.IGL_GL.Version < 200) if (GlobalWin.IGL_GL.Version < 200)
{ {
// fallback // fallback
Global.Config.DispMethod = Config.EDispMethod.GdiPlus; Global.Config.DispMethod = EDispMethod.GdiPlus;
goto REDO_DISPMETHOD; goto REDO_DISPMETHOD;
} }
} }
@ -180,7 +180,7 @@ namespace BizHawk.Client.EmuHawk
new ExceptionBox(new Exception("Initialization of Display Method failed; falling back to GDI+", ex)).ShowDialog(); new ExceptionBox(new Exception("Initialization of Display Method failed; falling back to GDI+", ex)).ShowDialog();
//fallback //fallback
Global.Config.DispMethod = Config.EDispMethod.GdiPlus; Global.Config.DispMethod = EDispMethod.GdiPlus;
goto REDO_DISPMETHOD; goto REDO_DISPMETHOD;
} }

View File

@ -30,11 +30,11 @@ namespace BizHawk.Client.EmuHawk
} }
else else
{ {
if (Global.Config.SoundOutputMethod == Config.ESoundOutputMethod.OpenAL) if (Global.Config.SoundOutputMethod == ESoundOutputMethod.OpenAL)
_outputDevice = new OpenALSoundOutput(this); _outputDevice = new OpenALSoundOutput(this);
if (Global.Config.SoundOutputMethod == Config.ESoundOutputMethod.DirectSound) if (Global.Config.SoundOutputMethod == ESoundOutputMethod.DirectSound)
_outputDevice = new DirectSoundSoundOutput(this, mainWindowHandle, Global.Config.SoundDevice); _outputDevice = new DirectSoundSoundOutput(this, mainWindowHandle, Global.Config.SoundDevice);
if (Global.Config.SoundOutputMethod == Config.ESoundOutputMethod.XAudio2) if (Global.Config.SoundOutputMethod == ESoundOutputMethod.XAudio2)
_outputDevice = new XAudio2SoundOutput(this); _outputDevice = new XAudio2SoundOutput(this);
} }

View File

@ -43,9 +43,9 @@ namespace BizHawk.Client.EmuHawk
if (_config.DispSpeedupFeatures == 1) rbDisplayMinimal.Checked = true; if (_config.DispSpeedupFeatures == 1) rbDisplayMinimal.Checked = true;
if (_config.DispSpeedupFeatures == 0) rbDisplayAbsoluteZero.Checked = true; if (_config.DispSpeedupFeatures == 0) rbDisplayAbsoluteZero.Checked = true;
rbOpenGL.Checked = _config.DispMethod == Config.EDispMethod.OpenGL; rbOpenGL.Checked = _config.DispMethod == EDispMethod.OpenGL;
rbGDIPlus.Checked = _config.DispMethod == Config.EDispMethod.GdiPlus; rbGDIPlus.Checked = _config.DispMethod == EDispMethod.GdiPlus;
rbD3D9.Checked = _config.DispMethod == Config.EDispMethod.SlimDX9; rbD3D9.Checked = _config.DispMethod == EDispMethod.SlimDX9;
cbStatusBarWindowed.Checked = _config.DispChrome_StatusBarWindowed; cbStatusBarWindowed.Checked = _config.DispChrome_StatusBarWindowed;
cbCaptionWindowed.Checked = _config.DispChrome_CaptionWindowed; cbCaptionWindowed.Checked = _config.DispChrome_CaptionWindowed;
@ -60,13 +60,13 @@ namespace BizHawk.Client.EmuHawk
nudPrescale.Value = _config.DispPrescale; nudPrescale.Value = _config.DispPrescale;
if (_config.DispManagerAR == Config.EDispManagerAR.None) if (_config.DispManagerAR == EDispManagerAR.None)
rbUseRaw.Checked = true; rbUseRaw.Checked = true;
else if (_config.DispManagerAR == Config.EDispManagerAR.System) else if (_config.DispManagerAR == EDispManagerAR.System)
rbUseSystem.Checked = true; rbUseSystem.Checked = true;
else if (_config.DispManagerAR == Config.EDispManagerAR.Custom) else if (_config.DispManagerAR == EDispManagerAR.Custom)
rbUseCustom.Checked = true; rbUseCustom.Checked = true;
else if (_config.DispManagerAR == Config.EDispManagerAR.CustomRatio) else if (_config.DispManagerAR == EDispManagerAR.CustomRatio)
rbUseCustomRatio.Checked = true; rbUseCustomRatio.Checked = true;
if(_config.DispCustomUserARWidth != -1) if(_config.DispCustomUserARWidth != -1)
@ -138,13 +138,13 @@ namespace BizHawk.Client.EmuHawk
if (rbDisplayAbsoluteZero.Checked) _config.DispSpeedupFeatures = 0; if (rbDisplayAbsoluteZero.Checked) _config.DispSpeedupFeatures = 0;
if (rbUseRaw.Checked) if (rbUseRaw.Checked)
_config.DispManagerAR = Config.EDispManagerAR.None; _config.DispManagerAR = EDispManagerAR.None;
else if (rbUseSystem.Checked) else if (rbUseSystem.Checked)
_config.DispManagerAR = Config.EDispManagerAR.System; _config.DispManagerAR = EDispManagerAR.System;
else if (rbUseCustom.Checked) else if (rbUseCustom.Checked)
_config.DispManagerAR = Config.EDispManagerAR.Custom; _config.DispManagerAR = EDispManagerAR.Custom;
else if (rbUseCustomRatio.Checked) else if (rbUseCustomRatio.Checked)
_config.DispManagerAR = Config.EDispManagerAR.CustomRatio; _config.DispManagerAR = EDispManagerAR.CustomRatio;
if (txtCustomARWidth.Text != "") if (txtCustomARWidth.Text != "")
int.TryParse(txtCustomARWidth.Text, out _config.DispCustomUserARWidth); int.TryParse(txtCustomARWidth.Text, out _config.DispCustomUserARWidth);
@ -161,11 +161,11 @@ namespace BizHawk.Client.EmuHawk
var oldDisplayMethod = _config.DispMethod; var oldDisplayMethod = _config.DispMethod;
if(rbOpenGL.Checked) if(rbOpenGL.Checked)
_config.DispMethod = Config.EDispMethod.OpenGL; _config.DispMethod = EDispMethod.OpenGL;
if(rbGDIPlus.Checked) if(rbGDIPlus.Checked)
_config.DispMethod = Config.EDispMethod.GdiPlus; _config.DispMethod = EDispMethod.GdiPlus;
if(rbD3D9.Checked) if(rbD3D9.Checked)
_config.DispMethod = Config.EDispMethod.SlimDX9; _config.DispMethod = EDispMethod.SlimDX9;
int.TryParse(txtCropLeft.Text, out _config.DispCropLeft); int.TryParse(txtCropLeft.Text, out _config.DispCropLeft);
int.TryParse(txtCropTop.Text, out _config.DispCropTop); int.TryParse(txtCropTop.Text, out _config.DispCropTop);

View File

@ -69,10 +69,10 @@ namespace BizHawk.Client.EmuHawk
switch (_config.LuaEngine) switch (_config.LuaEngine)
{ {
case Config.ELuaEngine.LuaPlusLuaInterface: case ELuaEngine.LuaPlusLuaInterface:
LuaInterfaceRadio.Checked = true; LuaInterfaceRadio.Checked = true;
break; break;
case Config.ELuaEngine.NLuaPlusKopiLua: case ELuaEngine.NLuaPlusKopiLua:
NLuaRadio.Checked = true; NLuaRadio.Checked = true;
break; break;
default: default:
@ -105,8 +105,8 @@ namespace BizHawk.Client.EmuHawk
_config.MoviesInAWE = cbMoviesInAWE.Checked; _config.MoviesInAWE = cbMoviesInAWE.Checked;
var prevLuaEngine = _config.LuaEngine; var prevLuaEngine = _config.LuaEngine;
if (LuaInterfaceRadio.Checked) _config.LuaEngine = Config.ELuaEngine.LuaPlusLuaInterface; if (LuaInterfaceRadio.Checked) _config.LuaEngine = ELuaEngine.LuaPlusLuaInterface;
else if (NLuaRadio.Checked) _config.LuaEngine = Config.ELuaEngine.NLuaPlusKopiLua; else if (NLuaRadio.Checked) _config.LuaEngine = ELuaEngine.NLuaPlusKopiLua;
Close(); Close();
DialogResult = DialogResult.OK; DialogResult = DialogResult.OK;

View File

@ -117,7 +117,7 @@ namespace BizHawk.Client.EmuHawk
{ {
if (_dispSettingsSet) if (_dispSettingsSet)
{ {
_config.DispManagerAR = Config.EDispManagerAR.System; _config.DispManagerAR = EDispManagerAR.System;
_config.DispFixAspectRatio = true; _config.DispFixAspectRatio = true;
_config.DispFixScaleInteger = false; _config.DispFixScaleInteger = false;
_config.DispFinalFilter = 1; // bilinear, I hope _config.DispFinalFilter = 1; // bilinear, I hope

View File

@ -40,17 +40,17 @@ namespace BizHawk.Client.EmuHawk
switch (_config.SelectedProfile) switch (_config.SelectedProfile)
{ {
default: default:
case Config.ClientProfile.Custom: // For now case ClientProfile.Custom: // For now
case Config.ClientProfile.Casual: case ClientProfile.Casual:
ProfileSelectComboBox.SelectedItem = "Casual Gaming"; ProfileSelectComboBox.SelectedItem = "Casual Gaming";
break; break;
case Config.ClientProfile.Longplay: case ClientProfile.Longplay:
ProfileSelectComboBox.SelectedItem = "Longplays"; ProfileSelectComboBox.SelectedItem = "Longplays";
break; break;
case Config.ClientProfile.Tas: case ClientProfile.Tas:
ProfileSelectComboBox.SelectedItem = "Tool-assisted Speedruns"; ProfileSelectComboBox.SelectedItem = "Tool-assisted Speedruns";
break; break;
case Config.ClientProfile.N64Tas: case ClientProfile.N64Tas:
ProfileSelectComboBox.SelectedItem = "N64 Tool-assisted Speedruns"; ProfileSelectComboBox.SelectedItem = "N64 Tool-assisted Speedruns";
break; break;
} }
@ -65,20 +65,20 @@ namespace BizHawk.Client.EmuHawk
default: default:
case "Custom Profile": // For now case "Custom Profile": // For now
case "Casual Gaming": case "Casual Gaming":
_config.SelectedProfile = Config.ClientProfile.Casual; _config.SelectedProfile = ClientProfile.Casual;
break; break;
case "Longplays": case "Longplays":
_config.SelectedProfile = Config.ClientProfile.Longplay; _config.SelectedProfile = ClientProfile.Longplay;
break; break;
case "Tool-assisted Speedruns": case "Tool-assisted Speedruns":
_config.SelectedProfile = Config.ClientProfile.Tas; _config.SelectedProfile = ClientProfile.Tas;
break; break;
case "N64 Tool-assisted Speedruns": case "N64 Tool-assisted Speedruns":
_config.SelectedProfile = Config.ClientProfile.N64Tas; _config.SelectedProfile = ClientProfile.N64Tas;
break; break;
} }
if (_config.SelectedProfile == Config.ClientProfile.Casual) if (_config.SelectedProfile == ClientProfile.Casual)
{ {
DisplayProfileSettingBoxes(false); DisplayProfileSettingBoxes(false);
_config.NoLowResLargeScreenshotWithStates = false; _config.NoLowResLargeScreenshotWithStates = false;
@ -127,7 +127,7 @@ namespace BizHawk.Client.EmuHawk
// NES // NES
_config.NES_InQuickNES = true; _config.NES_InQuickNES = true;
} }
else if (_config.SelectedProfile == Config.ClientProfile.Longplay) else if (_config.SelectedProfile == ClientProfile.Longplay)
{ {
DisplayProfileSettingBoxes(false); DisplayProfileSettingBoxes(false);
_config.NoLowResLargeScreenshotWithStates = false; _config.NoLowResLargeScreenshotWithStates = false;
@ -175,7 +175,7 @@ namespace BizHawk.Client.EmuHawk
// NES // NES
_config.NES_InQuickNES = true; _config.NES_InQuickNES = true;
} }
else if (_config.SelectedProfile == Config.ClientProfile.Tas) else if (_config.SelectedProfile == ClientProfile.Tas)
{ {
DisplayProfileSettingBoxes(false); DisplayProfileSettingBoxes(false);
@ -226,7 +226,7 @@ namespace BizHawk.Client.EmuHawk
// NES // NES
_config.NES_InQuickNES = true; _config.NES_InQuickNES = true;
} }
else if (_config.SelectedProfile == Config.ClientProfile.N64Tas) else if (_config.SelectedProfile == ClientProfile.N64Tas)
{ {
DisplayProfileSettingBoxes(false); DisplayProfileSettingBoxes(false);
@ -278,7 +278,7 @@ namespace BizHawk.Client.EmuHawk
// NES // NES
_config.NES_InQuickNES = true; _config.NES_InQuickNES = true;
} }
else if (_config.SelectedProfile == Config.ClientProfile.Custom) else if (_config.SelectedProfile == ClientProfile.Custom)
{ {
// Disabled for now // Disabled for now
////DisplayProfileSettingBoxes(true); ////DisplayProfileSettingBoxes(true);

View File

@ -74,9 +74,9 @@ namespace BizHawk.Client.EmuHawk
nudCompression.Value = _config.SaveStateCompressionLevelNormal; nudCompression.Value = _config.SaveStateCompressionLevelNormal;
rbStatesDefault.Checked = _config.SaveStateType == Config.SaveStateTypeE.Default; rbStatesDefault.Checked = _config.SaveStateType == SaveStateTypeE.Default;
rbStatesBinary.Checked = _config.SaveStateType == Config.SaveStateTypeE.Binary; rbStatesBinary.Checked = _config.SaveStateType == SaveStateTypeE.Binary;
rbStatesText.Checked = _config.SaveStateType == Config.SaveStateTypeE.Text; rbStatesText.Checked = _config.SaveStateType == SaveStateTypeE.Text;
BackupSavestatesCheckbox.Checked = _config.BackupSavestates; BackupSavestatesCheckbox.Checked = _config.BackupSavestates;
ScreenshotInStatesCheckbox.Checked = _config.SaveScreenshotWithStates; ScreenshotInStatesCheckbox.Checked = _config.SaveScreenshotWithStates;
@ -183,9 +183,9 @@ namespace BizHawk.Client.EmuHawk
// These settings are not used by DoRewindSettings // These settings are not used by DoRewindSettings
_config.RewindSpeedMultiplier = (int)RewindSpeedNumeric.Value; _config.RewindSpeedMultiplier = (int)RewindSpeedNumeric.Value;
_config.SaveStateCompressionLevelNormal = (int)nudCompression.Value; _config.SaveStateCompressionLevelNormal = (int)nudCompression.Value;
if (rbStatesDefault.Checked) _config.SaveStateType = Config.SaveStateTypeE.Default; if (rbStatesDefault.Checked) _config.SaveStateType = SaveStateTypeE.Default;
if (rbStatesBinary.Checked) _config.SaveStateType = Config.SaveStateTypeE.Binary; if (rbStatesBinary.Checked) _config.SaveStateType = SaveStateTypeE.Binary;
if (rbStatesText.Checked) _config.SaveStateType = Config.SaveStateTypeE.Text; if (rbStatesText.Checked) _config.SaveStateType = SaveStateTypeE.Text;
_config.BackupSavestates = BackupSavestatesCheckbox.Checked; _config.BackupSavestates = BackupSavestatesCheckbox.Checked;
_config.SaveScreenshotWithStates = ScreenshotInStatesCheckbox.Checked; _config.SaveScreenshotWithStates = ScreenshotInStatesCheckbox.Checked;
_config.NoLowResLargeScreenshotWithStates = !LowResLargeScreenshotsCheckbox.Checked; _config.NoLowResLargeScreenshotWithStates = !LowResLargeScreenshotsCheckbox.Checked;

View File

@ -35,9 +35,9 @@ namespace BizHawk.Client.EmuHawk
rbOutputMethodXAudio2.Enabled = false; rbOutputMethodXAudio2.Enabled = false;
} }
rbOutputMethodDirectSound.Checked = _config.SoundOutputMethod == Config.ESoundOutputMethod.DirectSound; rbOutputMethodDirectSound.Checked = _config.SoundOutputMethod == ESoundOutputMethod.DirectSound;
rbOutputMethodXAudio2.Checked = _config.SoundOutputMethod == Config.ESoundOutputMethod.XAudio2; rbOutputMethodXAudio2.Checked = _config.SoundOutputMethod == ESoundOutputMethod.XAudio2;
rbOutputMethodOpenAL.Checked = _config.SoundOutputMethod == Config.ESoundOutputMethod.OpenAL; rbOutputMethodOpenAL.Checked = _config.SoundOutputMethod == ESoundOutputMethod.OpenAL;
BufferSizeNumeric.Value = _config.SoundBufferSizeMs; BufferSizeNumeric.Value = _config.SoundBufferSizeMs;
tbNormal.Value = _config.SoundVolume; tbNormal.Value = _config.SoundVolume;
nudNormal.Value = _config.SoundVolume; nudNormal.Value = _config.SoundVolume;
@ -61,9 +61,9 @@ namespace BizHawk.Client.EmuHawk
_config.SoundEnabledNormal = cbEnableNormal.Checked; _config.SoundEnabledNormal = cbEnableNormal.Checked;
_config.SoundEnabledRWFF = cbEnableRWFF.Checked; _config.SoundEnabledRWFF = cbEnableRWFF.Checked;
_config.MuteFrameAdvance = cbMuteFrameAdvance.Checked; _config.MuteFrameAdvance = cbMuteFrameAdvance.Checked;
if (rbOutputMethodDirectSound.Checked) _config.SoundOutputMethod = Config.ESoundOutputMethod.DirectSound; if (rbOutputMethodDirectSound.Checked) _config.SoundOutputMethod = ESoundOutputMethod.DirectSound;
if (rbOutputMethodXAudio2.Checked) _config.SoundOutputMethod = Config.ESoundOutputMethod.XAudio2; if (rbOutputMethodXAudio2.Checked) _config.SoundOutputMethod = ESoundOutputMethod.XAudio2;
if (rbOutputMethodOpenAL.Checked) _config.SoundOutputMethod = Config.ESoundOutputMethod.OpenAL; if (rbOutputMethodOpenAL.Checked) _config.SoundOutputMethod = ESoundOutputMethod.OpenAL;
_config.SoundBufferSizeMs = (int)BufferSizeNumeric.Value; _config.SoundBufferSizeMs = (int)BufferSizeNumeric.Value;
_config.SoundVolume = tbNormal.Value; _config.SoundVolume = tbNormal.Value;
_config.SoundVolumeRWFF = tbRWFF.Value; _config.SoundVolumeRWFF = tbRWFF.Value;

View File

@ -66,7 +66,9 @@
<s:Boolean x:Key="/Default/CodeStyle/CSharpUsing/AddImportsToDeepestScope/@EntryValue">False</s:Boolean> <s:Boolean x:Key="/Default/CodeStyle/CSharpUsing/AddImportsToDeepestScope/@EntryValue">False</s:Boolean>
<s:Boolean x:Key="/Default/CodeStyle/CSharpUsing/PreferQualifiedReference/@EntryValue">False</s:Boolean> <s:Boolean x:Key="/Default/CodeStyle/CSharpUsing/PreferQualifiedReference/@EntryValue">False</s:Boolean>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AF/@EntryIndexedValue">AF</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AF/@EntryIndexedValue">AF</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AL/@EntryIndexedValue">AL</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AP/@EntryIndexedValue">API</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AP/@EntryIndexedValue">API</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AR/@EntryIndexedValue">AR</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=ARGB/@EntryIndexedValue">ARGB</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=ARGB/@EntryIndexedValue">ARGB</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AV/@EntryIndexedValue">AV</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=AV/@EntryIndexedValue">AV</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=BG/@EntryIndexedValue">BG</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=BG/@EntryIndexedValue">BG</s:String>
@ -78,6 +80,7 @@
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=DC/@EntryIndexedValue">DC</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=DC/@EntryIndexedValue">DC</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=DGB/@EntryIndexedValue">DGB</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=DGB/@EntryIndexedValue">DGB</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=DMG/@EntryIndexedValue">DMG</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=DMG/@EntryIndexedValue">DMG</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=DX/@EntryIndexedValue">DX</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=GB/@EntryIndexedValue">GB</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=GB/@EntryIndexedValue">GB</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=GBA/@EntryIndexedValue">GBA</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=GBA/@EntryIndexedValue">GBA</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=GBC/@EntryIndexedValue">GBC</s:String> <s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=GBC/@EntryIndexedValue">GBC</s:String>
@ -286,6 +289,7 @@
<s:Boolean x:Key="/Default/UserDictionary/Words/=Justifier/@EntryIndexedValue">True</s:Boolean> <s:Boolean x:Key="/Default/UserDictionary/Words/=Justifier/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=keepalives/@EntryIndexedValue">True</s:Boolean> <s:Boolean x:Key="/Default/UserDictionary/Words/=keepalives/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=KEYMENU/@EntryIndexedValue">True</s:Boolean> <s:Boolean x:Key="/Default/UserDictionary/Words/=KEYMENU/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Kopi/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Letterboxing/@EntryIndexedValue">True</s:Boolean> <s:Boolean x:Key="/Default/UserDictionary/Words/=Letterboxing/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Libretro/@EntryIndexedValue">True</s:Boolean> <s:Boolean x:Key="/Default/UserDictionary/Words/=Libretro/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Libsnes/@EntryIndexedValue">True</s:Boolean> <s:Boolean x:Key="/Default/UserDictionary/Words/=Libsnes/@EntryIndexedValue">True</s:Boolean>