[Scummvm-git-logs] scummvm master -> 3f63b3c42d82846f42493bae6161e142600b41a1
bluegr
bluegr at gmail.com
Sat Jul 17 06:28:57 UTC 2021
This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
3f63b3c42d SCUMM: Minor cleanup
Commit: 3f63b3c42d82846f42493bae6161e142600b41a1
https://github.com/scummvm/scummvm/commit/3f63b3c42d82846f42493bae6161e142600b41a1
Author: Orgad Shaneh (orgads at gmail.com)
Date: 2021-07-17T09:28:55+03:00
Commit Message:
SCUMM: Minor cleanup
Changed paths:
engines/scumm/dialogs.cpp
diff --git a/engines/scumm/dialogs.cpp b/engines/scumm/dialogs.cpp
index c4171ad9fa..0f7a57ac45 100644
--- a/engines/scumm/dialogs.cpp
+++ b/engines/scumm/dialogs.cpp
@@ -371,13 +371,24 @@ void HelpDialog::handleCommand(GUI::CommandSender *sender, uint32 cmd, uint32 da
#pragma mark -
+static bool isCJKLanguage(Common::Language lang) {
+ switch (lang) {
+ case Common::KO_KOR:
+ case Common::JA_JPN:
+ case Common::ZH_TWN:
+ case Common::ZH_CNA:
+ return true;
+ default:
+ return false;
+ }
+}
+
InfoDialog::InfoDialog(ScummEngine *scumm, int res)
: ScummDialog(0, 0, 0, 0), _vm(scumm), _style(GUI::ThemeEngine::kFontStyleBold) { // dummy x and w
_message = queryResString(res);
- Common::Language lang = (_vm->_language == Common::KO_KOR || _vm->_language == Common::JA_JPN ||
- _vm->_language == Common::ZH_TWN || _vm->_language == Common::ZH_CNA) ? _vm->_language : Common::UNK_LANG;
+ Common::Language lang = isCJKLanguage(_vm->_language) ? _vm->_language : Common::UNK_LANG;
// Width and height are dummy
_text = new GUI::StaticTextWidget(this, 0, 0, 10, 10, _message, kTextAlignCenter, Common::U32String(), GUI::ThemeEngine::kFontStyleBold, lang);
More information about the Scummvm-git-logs
mailing list