diff options
author | Max Horn | 2003-10-17 15:35:46 +0000 |
---|---|---|
committer | Max Horn | 2003-10-17 15:35:46 +0000 |
commit | a70460833e498620122bd60a1e6708d2a263626a (patch) | |
tree | 5f01fea8d1ea7409f584a25ac2e6329322ebbc93 /scumm | |
parent | 4fe33a1dae09704835ea29608cdfcdf46eabcd7c (diff) | |
download | scummvm-rg350-a70460833e498620122bd60a1e6708d2a263626a.tar.gz scummvm-rg350-a70460833e498620122bd60a1e6708d2a263626a.tar.bz2 scummvm-rg350-a70460833e498620122bd60a1e6708d2a263626a.zip |
moved platform/language constants to common/util.*
svn-id: r10862
Diffstat (limited to 'scumm')
-rw-r--r-- | scumm/charset.cpp | 9 | ||||
-rw-r--r-- | scumm/scummvm.cpp | 20 |
2 files changed, 15 insertions, 14 deletions
diff --git a/scumm/charset.cpp b/scumm/charset.cpp index 0cf0ad8f27..6461775a1a 100644 --- a/scumm/charset.cpp +++ b/scumm/charset.cpp @@ -22,7 +22,6 @@ #include "scumm/charset.h" #include "scumm/scumm.h" #include "scumm/nut_renderer.h" -#include "base/gameDetector.h" namespace Scumm { @@ -868,16 +867,16 @@ static byte spanishCharsetDataV2[] = { void CharsetRendererV2::setCurID(byte id) { switch (_vm->_language) { - case DE_DEU: + case Common::DE_DEU: _fontPtr = germanCharsetDataV2; break; - case FR_FRA: + case Common::FR_FRA: _fontPtr = frenchCharsetDataV2; break; - case IT_ITA: + case Common::IT_ITA: _fontPtr = italianCharsetDataV2; break; - case ES_ESP: + case Common::ES_ESP: _fontPtr = spanishCharsetDataV2; break; default: diff --git a/scumm/scummvm.cpp b/scumm/scummvm.cpp index 4050f144a3..682389c2c2 100644 --- a/scumm/scummvm.cpp +++ b/scumm/scummvm.cpp @@ -609,7 +609,9 @@ ScummEngine::ScummEngine(GameDetector *detector, OSystem *syst) _confirmExit = ConfMan.getBool("confirm_exit"); _defaultTalkDelay = ConfMan.getInt("talkspeed"); _native_mt32 = ConfMan.getBool("native_mt32"); - _language = GameDetector::parseLanguage(ConfMan.get("language")); + // TODO: We shouldn't rely on the global Language values matching those COMI etc. expect. + // Rather we should explicitly translate them. + _language = Common::parseLanguage(ConfMan.get("language")); memset(&res, 0, sizeof(res)); _hexdumpScripts = false; _showStack = false; @@ -707,19 +709,19 @@ ScummEngine::ScummEngine(GameDetector *detector, OSystem *syst) // Load CJK font _CJKMode = false; - if ((_gameId == GID_DIG || _gameId == GID_CMI) && (_language == KO_KOR || _language == JA_JPN || _language == ZH_TWN)) { + if ((_gameId == GID_DIG || _gameId == GID_CMI) && (_language == Common::KO_KOR || _language == Common::JA_JPN || _language == Common::ZH_TWN)) { File fp; const char *fontFile = NULL; switch(_language) { - case KO_KOR: + case Common::KO_KOR: _CJKMode = true; fontFile = "korean.fnt"; break; - case JA_JPN: + case Common::JA_JPN: _CJKMode = true; fontFile = (_gameId == GID_DIG) ? "kanji16.fnt" : "japanese.fnt"; break; - case ZH_TWN: + case Common::ZH_TWN: if (_gameId == GID_CMI) { _CJKMode = true; fontFile = "chinese.fnt"; @@ -734,13 +736,13 @@ ScummEngine::ScummEngine(GameDetector *detector, OSystem *syst) int numChar = 0; switch(_language) { - case KO_KOR: + case Common::KO_KOR: numChar = 2350; break; - case JA_JPN: + case Common::JA_JPN: numChar = (_gameId == GID_DIG) ? 1 : 1; //FIXME break; - case ZH_TWN: + case Common::ZH_TWN: numChar = 1; //FIXME break; } @@ -2640,7 +2642,7 @@ Engine *Engine_SCUMM_create(GameDetector *detector, OSystem *syst) { detector->_game.features |= GF_AMIGA; } - switch (GameDetector::parsePlatform(ConfMan.get("platform"))) { + switch (Common::parsePlatform(ConfMan.get("platform"))) { case kPlatformAmiga: detector->_game.features |= GF_AMIGA; break; |