mirror of
https://github.com/libretro/scummvm.git
synced 2025-02-04 01:46:42 +00:00
WINTERMUTE: Use ConfMan instead of registry.
This commit is contained in:
parent
da0ba41903
commit
1f5288d8c1
@ -38,6 +38,7 @@
|
||||
#include "common/system.h"
|
||||
#include "engines/wintermute/graphics/transparent_surface.h"
|
||||
#include "common/queue.h"
|
||||
#include "common/config-manager.h"
|
||||
|
||||
namespace WinterMute {
|
||||
|
||||
@ -153,7 +154,7 @@ bool BaseRenderOSystem::initRenderer(int width, int height, bool windowed) {
|
||||
_ratioX = (float)(_realWidth - _borderLeft - _borderRight) / (float)_width;
|
||||
_ratioY = (float)(_realHeight - _borderTop - _borderBottom) / (float)_height;
|
||||
|
||||
//_windowed = BaseEngine::instance().getRegistry()->readBool("Video", "Windowed", true); TODO
|
||||
_windowed = !ConfMan.getBool("fullscreen");
|
||||
|
||||
Graphics::PixelFormat format(4, 8, 8, 8, 8, 24, 16, 8, 0);
|
||||
g_system->beginGFXTransaction();
|
||||
|
@ -72,7 +72,7 @@ bool BaseSoundMgr::cleanup() {
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
void BaseSoundMgr::saveSettings() {
|
||||
if (_soundAvailable) {
|
||||
BaseEngine::instance().getRegistry()->writeInt("Audio", "MasterVolume", _volumeMaster);
|
||||
ConfMan.setInt("master_volume", _volumeMaster);
|
||||
}
|
||||
}
|
||||
|
||||
@ -83,7 +83,7 @@ bool BaseSoundMgr::initialize() {
|
||||
if (!g_system->getMixer()->isReady()) {
|
||||
return STATUS_FAILED;
|
||||
}
|
||||
_volumeMaster = BaseEngine::instance().getRegistry()->readInt("Audio", "MasterVolume", 255);
|
||||
_volumeMaster = (ConfMan.hasKey("master_volume") ? ConfMan.getInt("master_volume") : 255);
|
||||
_soundAvailable = true;
|
||||
|
||||
return STATUS_OK;
|
||||
|
Loading…
x
Reference in New Issue
Block a user