[Scummvm-cvs-logs] SF.net SVN: scummvm:[44725] scummvm/trunk/engines/sci/engine/kgraphics.cpp

m_kiewitz at users.sourceforge.net m_kiewitz at users.sourceforge.net
Wed Oct 7 13:35:13 CEST 2009


Revision: 44725
          http://scummvm.svn.sourceforge.net/scummvm/?rev=44725&view=rev
Author:   m_kiewitz
Date:     2009-10-07 11:35:12 +0000 (Wed, 07 Oct 2009)

Log Message:
-----------
SCI: removed r44595, sierra sci really does behave like Common::Rect, no need for +1

Modified Paths:
--------------
    scummvm/trunk/engines/sci/engine/kgraphics.cpp

Modified: scummvm/trunk/engines/sci/engine/kgraphics.cpp
===================================================================
--- scummvm/trunk/engines/sci/engine/kgraphics.cpp	2009-10-07 11:31:30 UTC (rev 44724)
+++ scummvm/trunk/engines/sci/engine/kgraphics.cpp	2009-10-07 11:35:12 UTC (rev 44725)
@@ -268,6 +268,8 @@
 }
 
 static reg_t kSetCursorSci0(EngineState *s, int argc, reg_t *argv) {
+	
+
 	int16 cursor = argv[0].toSint16();
 
 	if ((argc >= 2) && (argv[1].toSint16() == 0))
@@ -299,7 +301,7 @@
 		int16 right = argv[3].toSint16();
 
 		if ((right >= left) && (bottom >= top)) {
-			Common::Rect rect = Common::Rect(left, top, right + 1, bottom + 1);
+			Common::Rect rect = Common::Rect(left, top, right, bottom);
 			gfxop_set_pointer_zone(s->gfx_state, rect);
 		} else {
 			warning("kSetCursor: Ignoring invalid mouse zone (%i, %i)-(%i, %i)", left, top, right, bottom);
@@ -877,8 +879,8 @@
 	rect.left = argv[argBase].toSint16();
 	rect.top = argv[argBase + 1].toSint16();
 	if (argc > 3) {
-		rect.right = argv[argBase + 2].toSint16() + 1;
-		rect.bottom = argv[argBase + 3].toSint16() + 1;
+		rect.right = argv[argBase + 2].toSint16();
+		rect.bottom = argv[argBase + 3].toSint16();
 	} else {
 		rect.right = rect.left + 1;
 		rect.bottom = rect.top + 1;
@@ -1403,7 +1405,7 @@
 	rect_t area = gfx_rect(x, y, xl, yl);
 
 	Common::Rect rect;
-	rect = Common::Rect (x, y, (int16)GET_SEL32V(obj, nsRight) + 1, (int16)GET_SEL32V(obj, nsBottom) + 1);
+	rect = Common::Rect (x, y, (int16)GET_SEL32V(obj, nsRight), (int16)GET_SEL32V(obj, nsBottom));
 
 	int font_nr = GET_SEL32V(obj, font);
 	reg_t text_pos = GET_SEL32(obj, text);
@@ -1587,8 +1589,8 @@
 		case 6:
 		picRect.top = argv[0].toSint16();
 		picRect.left = argv[1].toSint16();
-		picRect.bottom = argv[2].toSint16() + 1;
-		picRect.right = argv[3].toSint16() + 1;
+		picRect.bottom = argv[2].toSint16();
+		picRect.right = argv[3].toSint16();
 		picTop = argv[4].toSint16();
 		picLeft = argv[5].toSint16();
 		s->gui->setPortPic(picRect, picTop, picLeft);
@@ -1624,7 +1626,7 @@
 }
 
 reg_t kNewWindow(EngineState *s, int argc, reg_t *argv) {
-	Common::Rect rect1 (argv[1].toSint16(), argv[0].toSint16(), argv[3].toSint16() + 1, argv[2].toSint16() + 1);
+	Common::Rect rect1 (argv[1].toSint16(), argv[0].toSint16(), argv[3].toSint16(), argv[2].toSint16());
 	Common::Rect rect2;
 	int argextra = argc == 13 ? 4 : 0; // Triggers in PQ3 and SCI1.1 games
 	int	style = argv[5 + argextra].toSint16();
@@ -1634,7 +1636,7 @@
 
 	//	const char *title = argv[4 + argextra].segment ? kernel_dereference_char_pointer(s, argv[4 + argextra], 0) : NULL;
 	if (argc==13) {
-		rect2 = Common::Rect (argv[5].toSint16(), argv[4].toSint16(), argv[7].toSint16() + 1, argv[6].toSint16() + 1);
+		rect2 = Common::Rect (argv[5].toSint16(), argv[4].toSint16(), argv[7].toSint16(), argv[6].toSint16());
 	}
 
 	Common::String title;


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list