[Scummvm-git-logs] scummvm master -> 535d6cb899bf1c910d02e255bdceb185b1efa8c3

a-yyg 76591232+a-yyg at users.noreply.github.com
Thu Jul 1 11:42:08 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:
535d6cb899 SAGA2: Fix global constructor warnings


Commit: 535d6cb899bf1c910d02e255bdceb185b1efa8c3
    https://github.com/scummvm/scummvm/commit/535d6cb899bf1c910d02e255bdceb185b1efa8c3
Author: a/ (yuri.kgpps at gmail.com)
Date: 2021-07-01T20:41:01+09:00

Commit Message:
SAGA2: Fix global constructor warnings

Changed paths:
    engines/saga2/contain.cpp
    engines/saga2/contain.h


diff --git a/engines/saga2/contain.cpp b/engines/saga2/contain.cpp
index 4af1a574cf..8e21125a68 100644
--- a/engines/saga2/contain.cpp
+++ b/engines/saga2/contain.cpp
@@ -115,16 +115,16 @@ ContainerList       globalContainerList;
 //	Physical container appearance
 
 static ContainerAppearanceDef physicalContainerAppearance = {
-	Rect16(250, 60, 268, 304 + 16),
-	Rect16(17 + 4, 87, 268 - 2, 304 - 87),
-	Rect16(13 + 8, 37, 44, 42),
-	Rect16(13 + 8 + 44, 37, 44, 42),
-	Rect16(13 + 118, 50, 36, 36),
-	Rect16(13 + 139, 37, 88, 43),
+	{250, 60, 268, 304 + 16},
+	{17 + 4, 87, 268 - 2, 304 - 87},
+	{13 + 8, 37, 44, 42},
+	{13 + 8 + 44, 37, 44, 42},
+	{13 + 118, 50, 36, 36},
+	{13 + 139, 37, 88, 43},
 	{ MKTAG('P', 'C', 'L', 0), MKTAG('P', 'C', 'L', 1) },
 	{ MKTAG('P', 'S', 'L', 0), MKTAG('P', 'S', 'L', 1) },
-	Point16(13, 8),
-	Point16(22, 22),
+	{13, 8},
+	{22, 22},
 	0, 0,
 	0
 };
@@ -156,17 +156,17 @@ static StaticWindow woodDecorations[] = {
 //-----------------------------------------------------------------------
 //	Death container appearance
 
-ContainerAppearanceDef  deathContainerAppearance = {
-	Rect16(260, 60, 206, 250),
-	Rect16(2, 87, 206 - 22, 250 - 87 - 32),
-	Rect16(16,  24, 44, 42),
-	Rect16(120 + 18, 24, 44, 42),
-	Rect16(0, 0, 0, 0),
-	Rect16(0, 0, 0, 0),
+static ContainerAppearanceDef deathContainerAppearance = {
+	{260, 60, 206, 250},
+	{2, 87, 206 - 22, 250 - 87 - 32},
+	{16,  24, 44, 42},
+	{120 + 18, 24, 44, 42},
+	{0, 0, 0, 0},
+	{0, 0, 0, 0},
 	{ MKTAG('D', 'C', 'L', 0), MKTAG('D', 'C', 'L', 1) },
 	{ MKTAG('D', 'S', 'L', 0), MKTAG('D', 'S', 'L', 1) },
-	Point16(27, -4),
-	Point16(22, 22),
+	{27, -4},
+	{22, 22},
 	0, 0,
 	0
 };
@@ -179,17 +179,17 @@ static StaticWindow deathDecorations[] = {
 //-----------------------------------------------------------------------
 //	ReadyContainer appearance
 
-ContainerAppearanceDef  readyContainerAppearance = {
-	Rect16(0, 0, 0, 0),
-	Rect16(476, 105, 0, 0),
-	Rect16(0, 0, 0, 0),
-	Rect16(0, 0, 0, 0),
-	Rect16(0, 0, 0, 0),
-	Rect16(0, 0, 0, 0),
+static ContainerAppearanceDef readyContainerAppearance = {
+	{0, 0, 0, 0},
+	{476, 105, 0, 0},
+	{0, 0, 0, 0},
+	{0, 0, 0, 0},
+	{0, 0, 0, 0},
+	{0, 0, 0, 0},
 	{ 0, 0 },
 	{ 0, 0 },
-	Point16(iconOriginX - 1, iconOriginY - 1 - 8),
-	Point16(iconSpacingX, iconSpacingY),
+	{iconOriginX - 1, iconOriginY - 1 - 8},
+	{iconSpacingX, iconSpacingY},
 	1, 3,
 	3
 };
@@ -197,17 +197,17 @@ ContainerAppearanceDef  readyContainerAppearance = {
 //-----------------------------------------------------------------------
 //	Mental Container appearance
 
-ContainerAppearanceDef  mentalContainerAppearance = {
-	Rect16(478, 168 - 54, 158, 215),
-	Rect16(2, 86 - 18 - 4, 158 - 2, 215 - 66),
-	Rect16(2, 19, 44, 44),
-	Rect16(103, 40 - 18 - 4, 44, 44),
-	Rect16(0, 0, 0, 0),
-	Rect16(0, 0, 0, 0),
+static ContainerAppearanceDef mentalContainerAppearance = {
+	{478, 168 - 54, 158, 215},
+	{2, 86 - 18 - 4, 158 - 2, 215 - 66},
+	{2, 19, 44, 44},
+	{103, 40 - 18 - 4, 44, 44},
+	{0, 0, 0, 0},
+	{0, 0, 0, 0},
 	{ MKTAG('C', 'L', 'S', 0), MKTAG('C', 'L', 'S', 1) },
 	{ MKTAG('S', 'E', 'L', 0), MKTAG('S', 'E', 'L', 1) },
-	Point16(3, 0),
-	Point16(4, 4),
+	{3, 0},
+	{4, 4},
 	4, 4,
 	20
 };
@@ -218,17 +218,17 @@ static StaticWindow mentalDecorations[] = {
 //-----------------------------------------------------------------------
 //	Enchantment container appearance
 
-ContainerAppearanceDef  enchantmentContainerAppearance = {
-	Rect16(262, 92, 116, 202),
-	Rect16(2, 87, 116 - 2, 202 - 87),
-	Rect16(7, 50, 44, 43),
-	Rect16(57, 50, 44, 43),
-	Rect16(38, 7, 32, 32),
-	Rect16(0, 0, 0, 0),
+static ContainerAppearanceDef enchantmentContainerAppearance = {
+	{262, 92, 116, 202},
+	{2, 87, 116 - 2, 202 - 87},
+	{7, 50, 44, 43},
+	{57, 50, 44, 43},
+	{38, 7, 32, 32},
+	{0, 0, 0, 0},
 	{ MKTAG('A', 'A', 'A', 0), MKTAG('A', 'A', 'A', 0) },
 	{ MKTAG('A', 'A', 'A', 0), MKTAG('A', 'A', 'A', 0) },
-	Point16(12, 98),
-	Point16(16, 13),
+	{12, 98},
+	{16, 13},
 	2, 2,
 	2
 };
diff --git a/engines/saga2/contain.h b/engines/saga2/contain.h
index 9939f3632a..e6a6cd3404 100644
--- a/engines/saga2/contain.h
+++ b/engines/saga2/contain.h
@@ -362,19 +362,21 @@ public:
  * ===================================================================== */
 
 struct ContainerAppearanceDef {
-	Rect16          defaultWindowPos;       //  default position of window
-	Rect16          viewRect;               //  position of view within window
-	Rect16          closeRect,              //  position of close button
-	                scrollRect,             //  position of scrolling button
-	                iconRect,               //  position of container icon
-	                massRect;               //  position of mass & bulk indicator
-	hResID          closeResID[2],        //  resource ID's for close box
-	                scrollResID[2];       //  resource ID's for scroll indicator
-	Point16         iconOrigin,
-	                iconSpacing;
-	uint16          rows,
-	                cols,
-	                totRows;
+	StaticRect defaultWindowPos;       //  default position of window
+	StaticRect viewRect;               //  position of view within window
+	StaticRect closeRect,              //  position of close button
+	           scrollRect,             //  position of scrolling button
+	           iconRect,               //  position of container icon
+	           massRect;               //  position of mass & bulk indicator
+
+	hResID closeResID[2],              //  resource ID's for close box
+	       scrollResID[2];             //  resource ID's for scroll indicator
+
+	StaticPoint16 iconOrigin,
+	              iconSpacing;
+	uint16 rows,
+	       cols,
+	       totRows;
 };
 
 /* ===================================================================== *




More information about the Scummvm-git-logs mailing list