[Scummvm-git-logs] scummvm master -> 274c406c31a4fb58b2d7791db4cd6638d4d25a06

eriktorbjorn noreply at scummvm.org
Fri Mar 11 14:59:23 UTC 2022


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:
274c406c31 SCUMM: Only auto-show keyboard in MI2 if it has copy protection screen


Commit: 274c406c31a4fb58b2d7791db4cd6638d4d25a06
    https://github.com/scummvm/scummvm/commit/274c406c31a4fb58b2d7791db4cd6638d4d25a06
Author: Torbjörn Andersson (eriktorbjorn at users.sourceforge.net)
Date: 2022-03-11T15:55:50+01:00

Commit Message:
SCUMM: Only auto-show keyboard in MI2 if it has copy protection screen

The Mac version only shows a copy protection screen if you explicitly
ask for it, and the unofficial talkie version doesn't show one ever.
Therefore there is no reason to trigger the virtual keyboard.

Changed paths:
    engines/scumm/room.cpp


diff --git a/engines/scumm/room.cpp b/engines/scumm/room.cpp
index 5f802842159..406b270644d 100644
--- a/engines/scumm/room.cpp
+++ b/engines/scumm/room.cpp
@@ -216,11 +216,24 @@ void ScummEngine::startScene(int room, Actor *a, int objectNr) {
 
 	// Hint the backend about the virtual keyboard during copy protection screens
 	if (_game.id == GID_MONKEY2) {
-		if (_system->getFeatureState(OSystem::kFeatureVirtualKeyboard)) {
-			if (room != 108)
-				_system->setFeatureState(OSystem::kFeatureVirtualKeyboard, false);
-		} else if (room == 108)
-			_system->setFeatureState(OSystem::kFeatureVirtualKeyboard, true);
+		bool hasCopyProtectionScreen = true;
+
+		// The Macintosh version skips the copy protection screen with
+		// a boot param, unless you ask it not to.
+		if (_game.platform == Common::kPlatformMacintosh && _bootParam == -7873)
+			hasCopyProtectionScreen = false;
+
+		// The unofficial talkie never shows any copy protection screen.
+		if (strcmp(_game.variant, "SE Talkie") == 0)
+			hasCopyProtectionScreen = false;
+
+		if (hasCopyProtectionScreen) {
+			if (_system->getFeatureState(OSystem::kFeatureVirtualKeyboard)) {
+				if (room != 108)
+					_system->setFeatureState(OSystem::kFeatureVirtualKeyboard, false);
+			} else if (room == 108)
+				_system->setFeatureState(OSystem::kFeatureVirtualKeyboard, true);
+		}
 	} else if (_game.id == GID_MONKEY_EGA) {	// this is my estimation that the room code is 90 (untested)
 		if (_system->getFeatureState(OSystem::kFeatureVirtualKeyboard)) {
 			if (room != 90)




More information about the Scummvm-git-logs mailing list