summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorfrosch <frosch@openttd.org>2009-06-08 15:42:35 +0000
committerfrosch <frosch@openttd.org>2009-06-08 15:42:35 +0000
commit53a711ede02e01391bd665721dfb5841a2c953f8 (patch)
tree310660247c1b6d0c74e699cf19a9c51459421cf5 /src
parent1df029de1d92895e8a28605fc84e7047e2e9b8af (diff)
downloadopenttd-53a711ede02e01391bd665721dfb5841a2c953f8.tar.xz
(svn r16535) -Fix (r16146): In one case a too small portion of the screen was marked dirty, when (un-)drawing selections.
Diffstat (limited to 'src')
-rw-r--r--src/viewport.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/viewport.cpp b/src/viewport.cpp
index e9be650a2..b944a2aa4 100644
--- a/src/viewport.cpp
+++ b/src/viewport.cpp
@@ -1785,7 +1785,8 @@ static void SetSelectionTilesDirty()
static const int OVERLAY_WIDTH = 4; // part of selection sprites is drawn outside the selected area
- MarkAllViewportsDirty(l - OVERLAY_WIDTH, t - OVERLAY_WIDTH, r + OVERLAY_WIDTH, b + OVERLAY_WIDTH);
+ /* For halftile foundations on SLOPE_STEEP_W the sprite extents some more towards the top */
+ MarkAllViewportsDirty(l - OVERLAY_WIDTH, t - OVERLAY_WIDTH - TILE_HEIGHT, r + OVERLAY_WIDTH, b + OVERLAY_WIDTH);
/* haven't we reached the topmost tile yet? */
if (top_x != x_start) {