Warp back to 5578. Sorry for the lost changes, please re-apply. Reason: 5579 is a complete disaster.

Not only does it change tons of files to switch to a new and non-working (it doesn't parse my ini files, at least) ini parser, it also reshuffles a lot of code and removes a plugin. The latter part is fine, but doing these two major switches in one revision, one of which is broken, is completely unacceptable. I said to merge tiny changes, not massive reworkings.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@5589 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
hrydgard
2010-06-03 18:05:08 +00:00
parent 3236aa9e73
commit a3c96ac42c
118 changed files with 8868 additions and 2530 deletions

View File

@ -20,30 +20,28 @@ AudioCommonConfig ac_Config;
// Load from given file
void AudioCommonConfig::Load(IniFile &file) {
Section& config = file["Config"];
config.Get("EnableDTKMusic", &m_EnableDTKMusic, true);
config.Get("EnableThrottle", &m_EnableThrottle, true);
config.Get("EnableJIT", &m_EnableJIT, true);
config.Get("Volume", &m_Volume, 75);
file.Get("Config", "EnableDTKMusic", &m_EnableDTKMusic, true);
file.Get("Config", "EnableThrottle", &m_EnableThrottle, true);
file.Get("Config", "EnableJIT", &m_EnableJIT, true);
file.Get("Config", "Volume", &m_Volume, 75);
#ifdef _WIN32
config.Get("Backend", &sBackend, BACKEND_DIRECTSOUND);
file.Get("Config", "Backend", &sBackend, BACKEND_DIRECTSOUND);
#elif defined(__APPLE__)
std::string temp;
config.Get("Backend", &temp, BACKEND_COREAUDIO);
file.Get("Config", "Backend", &temp, BACKEND_COREAUDIO);
strncpy(sBackend, temp.c_str(), 128);
#else // linux
config.Get("Backend", &sBackend, BACKEND_ALSA);
file.Get("Config", "Backend", &sBackend, BACKEND_ALSA);
#endif
}
// Set the values for the file
void AudioCommonConfig::Set(IniFile &file) {
Section& config = file["Config"];
config.Set("EnableDTKMusic", m_EnableDTKMusic);
config.Set("EnableThrottle", m_EnableThrottle);
config.Set("EnableJIT", m_EnableJIT);
config.Set("Backend", sBackend);
config.Set("Volume", m_Volume);
file.Set("Config", "EnableDTKMusic", m_EnableDTKMusic);
file.Set("Config", "EnableThrottle", m_EnableThrottle);
file.Set("Config", "EnableJIT", m_EnableJIT);
file.Set("Config", "Backend", sBackend);
file.Set("Config", "Volume", m_Volume);
}
// Update according to the values (stream/mixer)