[Scummvm-cvs-logs] CVS: scummvm/backends/morphos morphos.cpp,1.27,1.28 morphos_start.cpp,1.13,1.14

Ruediger Hanke tomjoad at users.sourceforge.net
Tue Jul 22 15:38:20 CEST 2003


Update of /cvsroot/scummvm/scummvm/backends/morphos
In directory sc8-pr-cvs1:/tmp/cvs-serv29981

Modified Files:
	morphos.cpp morphos_start.cpp 
Log Message:
Some MorphOS port fixes

Index: morphos.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/backends/morphos/morphos.cpp,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -d -r1.27 -r1.28
--- morphos.cpp	22 Jul 2003 20:36:43 -0000	1.27
+++ morphos.cpp	22 Jul 2003 22:37:37 -0000	1.28
@@ -213,8 +213,11 @@
 
 	if (ScummMusicThread)
 	{
-		Signal((Task *) ScummMusicThread, SIGBREAKF_CTRL_C);
-		ObtainSemaphore(&ScummMusicThreadRunning);    /* Wait for thread to finish */
+		if (!AttemptSemaphore(&ScummMusicThreadRunning))
+		{
+			Signal((Task *) ScummMusicThread, SIGBREAKF_CTRL_C);
+			ObtainSemaphore(&ScummMusicThreadRunning);    /* Wait for thread to finish */
+		}
 		ReleaseSemaphore(&ScummMusicThreadRunning);
 	}
 
@@ -1096,8 +1099,9 @@
 	} else if (dy < 0) {
 		// move up
 		// copy from top to bottom
+		dy = -dy;
 		for (int y = dy; y < height; y++)
-			copy_rect((byte *)ScummBuffer + ScummBufferWidth * (y - dy), ScummBufferWidth, 0, y, ScummBufferWidth, 1);
+			copy_rect((byte *)ScummBuffer + ScummBufferWidth * y, ScummBufferWidth, 0, y - dy, ScummBufferWidth, 1);
 	}
 
 	// horizontal movement
@@ -1109,8 +1113,9 @@
 	} else if (dx < 0) {
 		// move left
 		// copy from left to right
+		dx = -dx;
 		for (int x = dx; x < ScummBufferWidth; x++)
-			copy_rect((byte *)ScummBuffer + x - dx, ScummBufferWidth, x, 0, 1, height);
+			copy_rect((byte *)ScummBuffer + x, ScummBufferWidth, x, 0, 1, height);
 	}
 }
 

Index: morphos_start.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/backends/morphos/morphos_start.cpp,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -d -r1.13 -r1.14
--- morphos_start.cpp	26 Apr 2003 11:43:44 -0000	1.13
+++ morphos_start.cpp	22 Jul 2003 22:37:37 -0000	1.14
@@ -97,9 +97,6 @@
 
 void close_resources()
 {
-	if (EtudeMidiDriver)
-		EtudeMidiDriver->close();
-
 	if (TheSystem)
 		delete TheSystem;
 





More information about the Scummvm-git-logs mailing list