[Scummvm-git-logs] scummvm master -> 9e144deb150d73bef4ebdfd8aee25a7f72769d15

digitall noreply at scummvm.org
Tue Mar 29 18:20:03 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:
9e144deb15 CHEWY: Fix Signed vs. Unsigned Comparison GCC Compiler Warnings


Commit: 9e144deb150d73bef4ebdfd8aee25a7f72769d15
    https://github.com/scummvm/scummvm/commit/9e144deb150d73bef4ebdfd8aee25a7f72769d15
Author: D G Turner (digitall at scummvm.org)
Date: 2022-03-29T19:19:25+01:00

Commit Message:
CHEWY: Fix Signed vs. Unsigned Comparison GCC Compiler Warnings

Changed paths:
    engines/chewy/main.cpp
    engines/chewy/menus.cpp
    engines/chewy/rooms/room00.cpp


diff --git a/engines/chewy/main.cpp b/engines/chewy/main.cpp
index 91ed2f8066b..d7ba43fe9a0 100644
--- a/engines/chewy/main.cpp
+++ b/engines/chewy/main.cpp
@@ -691,7 +691,7 @@ void mous_obj_action(int16 nr, int16 mode, int16 txt_mode, int16 txt_nr) {
 				int16 x = g_events->_mousePos.x;
 				int16 y = g_events->_mousePos.y;
 				calcTxtXy(&x, &y, desc);
-				for (int16 i = 0; i < desc.size(); i++)
+				for (int16 i = 0; i < (int16)desc.size(); i++)
 					printShadowed(x, y + i * 10, 255, 300, 0, _G(scr_width), desc[i].c_str());
 			}
 		}
@@ -1427,7 +1427,7 @@ int16 calcMouseText(int16 x, int16 y, int16 mode) {
 						ret = txtNr;
 						_G(fontMgr)->setFont(_G(font8));
 						calcTxtXy(&x, &y, desc);
-						for (int16 i = 0; i < desc.size(); i++)
+						for (int16 i = 0; i < (int16)desc.size(); i++)
 							printShadowed(x, y + i * 10, 255, 300, 0, _G(scr_width), desc[i].c_str());
 					}
 				}
diff --git a/engines/chewy/menus.cpp b/engines/chewy/menus.cpp
index a4423aeff73..7eb8081431f 100644
--- a/engines/chewy/menus.cpp
+++ b/engines/chewy/menus.cpp
@@ -112,8 +112,8 @@ void calcTxtXy(int16 *x, int16 *y, char *txtAdr, int16 txtCount) {
 
 void calcTxtXy(int16 *x, int16 *y, Common::StringArray &textList) {
 	int16 len = 0;
-	for (int16 i = 0; i < textList.size(); i++) {
-		if (textList[i].size() > len)
+	for (int16 i = 0; i < (int16)textList.size(); i++) {
+		if ((int16)textList[i].size() > len)
 			len = textList[i].size();
 	}
 	len = len * _G(fontMgr)->getFont()->getDataWidth();
diff --git a/engines/chewy/rooms/room00.cpp b/engines/chewy/rooms/room00.cpp
index e439e755cf7..a3d96a9c18c 100644
--- a/engines/chewy/rooms/room00.cpp
+++ b/engines/chewy/rooms/room00.cpp
@@ -307,7 +307,7 @@ void Room0::calcEyeClick(int16 aniNr) {
 				int16 x = g_events->_mousePos.x;
 				int16 y = g_events->_mousePos.y;
 				calcTxtXy(&x, &y, desc);
-				for (int16 i = 0; i < desc.size(); i++)
+				for (int16 i = 0; i < (int16)desc.size(); i++)
 					printShadowed(x, y + i * 10, 255, 300, 0, _G(scr_width), desc[i].c_str());
 			}
 		} else if (_G(minfo)._button == 1 || g_events->_kbInfo._keyCode == Common::KEYCODE_RETURN) {
@@ -545,7 +545,7 @@ void Room0::calcPillowClick(int16 aniNr) {
 				int16 x = g_events->_mousePos.x;
 				int16 y = g_events->_mousePos.y;
 				calcTxtXy(&x, &y, desc);
-				for (int16 i = 0; i < desc.size(); i++)
+				for (int16 i = 0; i < (int16)desc.size(); i++)
 					printShadowed(x, y + i * 10, 255, 300, 0, _G(scr_width), desc[i].c_str());
 			}
 		} else if (_G(minfo)._button == 1 || g_events->_kbInfo._keyCode == Common::KEYCODE_RETURN) {




More information about the Scummvm-git-logs mailing list