[Scummvm-cvs-logs] CVS: scummvm/common rect.h,1.6,1.7

Max Horn fingolfin at users.sourceforge.net
Thu May 15 15:16:09 CEST 2003


Update of /cvsroot/scummvm/scummvm/common
In directory sc8-pr-cvs1:/tmp/cvs-serv19003

Modified Files:
	rect.h 
Log Message:
add method to grow a rect

Index: rect.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/common/rect.h,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -d -r1.6 -r1.7
--- rect.h	15 May 2003 21:52:10 -0000	1.6
+++ rect.h	15 May 2003 22:15:24 -0000	1.7
@@ -87,6 +87,13 @@
 	bool contains(const Rect & r) const {
 		return (left <= r.right) && (r.left < right) && (top <= r.bottom) && (r.top < bottom);
 	}
+	
+	void grow(int16 offset) {
+		top -= offset;
+		left -= offset;
+		bottom += offset;
+		right += offset;
+	}
 };
 
 };	// End of namespace ScummVM





More information about the Scummvm-git-logs mailing list