pingus-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pingus-CVS] r2809 - branches/pingus_sdl/src


From: jsalmon3
Subject: [Pingus-CVS] r2809 - branches/pingus_sdl/src
Date: Sun, 5 Aug 2007 05:21:08 +0200

Author: jsalmon3
Date: 2007-08-05 05:21:01 +0200 (Sun, 05 Aug 2007)
New Revision: 2809

Modified:
   branches/pingus_sdl/src/graphic_context_state.cpp
Log:
Fixed off by 1 that caused the screen to wobble when scrolling

Modified: branches/pingus_sdl/src/graphic_context_state.cpp
===================================================================
--- branches/pingus_sdl/src/graphic_context_state.cpp   2007-08-05 03:03:16 UTC 
(rev 2808)
+++ branches/pingus_sdl/src/graphic_context_state.cpp   2007-08-05 03:21:01 UTC 
(rev 2809)
@@ -161,20 +161,20 @@
     {
       if (-impl->offset.x < impl->limit.left)
         {
-         impl->offset.x = (float)-(impl->limit.left);
+          impl->offset.x = (float)-(impl->limit.left);
         }
-      else if (-impl->offset.x + get_width() >= impl->limit.right)
+      else if (-impl->offset.x + get_width() > impl->limit.right)
         {
-         impl->offset.x = (float)-(impl->limit.right - get_width() - 1);
+          impl->offset.x = (float)-(impl->limit.right - get_width());
         }
 
       if (-impl->offset.y < impl->limit.top)
         {
           impl->offset.y = (float)-(impl->limit.top);
         }
-      else if (-impl->offset.y + get_height() >= impl->limit.bottom)
+      else if (-impl->offset.y + get_height() > impl->limit.bottom)
         {
-          impl->offset.y = (float)-(impl->limit.bottom - get_height() - 1);
+          impl->offset.y = (float)-(impl->limit.bottom - get_height());
         }
     }
 }





reply via email to

[Prev in Thread] Current Thread [Next in Thread]