Viewport: Fix casing of ClearViewportCache(s)
This commit is contained in:
@@ -1718,8 +1718,8 @@ void DrawDirtyBlocks()
|
|||||||
_gfx_draw_active = false;
|
_gfx_draw_active = false;
|
||||||
++_dirty_block_colour;
|
++_dirty_block_colour;
|
||||||
|
|
||||||
extern void ClearViewPortCaches();
|
extern void ClearViewportCaches();
|
||||||
ClearViewPortCaches();
|
ClearViewportCaches();
|
||||||
}
|
}
|
||||||
|
|
||||||
void UnsetDirtyBlocks(int left, int top, int right, int bottom)
|
void UnsetDirtyBlocks(int left, int top, int right, int bottom)
|
||||||
|
@@ -675,7 +675,7 @@ static void LargeWorldCallback(void *userdata, void *buf, uint y, uint pitch, ui
|
|||||||
_screen = old_screen;
|
_screen = old_screen;
|
||||||
_screen_disable_anim = old_disable_anim;
|
_screen_disable_anim = old_disable_anim;
|
||||||
|
|
||||||
ClearViewPortCache(vp);
|
ClearViewportCache(vp);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -336,7 +336,7 @@ static Point MapXYZToViewport(const Viewport *vp, int x, int y, int z)
|
|||||||
return p;
|
return p;
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClearViewPortCache(Viewport *vp)
|
void ClearViewportCache(Viewport *vp)
|
||||||
{
|
{
|
||||||
if (vp->zoom >= ZOOM_LVL_DRAW_MAP) {
|
if (vp->zoom >= ZOOM_LVL_DRAW_MAP) {
|
||||||
memset(vp->map_draw_vehicles_cache.done_hash_bits, 0, sizeof(vp->map_draw_vehicles_cache.done_hash_bits));
|
memset(vp->map_draw_vehicles_cache.done_hash_bits, 0, sizeof(vp->map_draw_vehicles_cache.done_hash_bits));
|
||||||
@@ -344,10 +344,10 @@ void ClearViewPortCache(Viewport *vp)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ClearViewPortCaches()
|
void ClearViewportCaches()
|
||||||
{
|
{
|
||||||
for (Viewport *vp : _viewport_window_cache) {
|
for (Viewport *vp : _viewport_window_cache) {
|
||||||
ClearViewPortCache(vp);
|
ClearViewportCache(vp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -680,7 +680,7 @@ static void SetViewportPosition(Window *w, int x, int y, bool force_update_overl
|
|||||||
if (height > 0 && (_vp_move_offs.x != 0 || _vp_move_offs.y != 0)) {
|
if (height > 0 && (_vp_move_offs.x != 0 || _vp_move_offs.y != 0)) {
|
||||||
SCOPE_INFO_FMT([&], "DoSetViewportPosition: %d, %d, %d, %d, %d, %d, %s", left, top, width, height, _vp_move_offs.x, _vp_move_offs.y, scope_dumper().WindowInfo(w));
|
SCOPE_INFO_FMT([&], "DoSetViewportPosition: %d, %d, %d, %d, %d, %d, %s", left, top, width, height, _vp_move_offs.x, _vp_move_offs.y, scope_dumper().WindowInfo(w));
|
||||||
DoSetViewportPosition((Window *) w->z_front, left, top, width, height);
|
DoSetViewportPosition((Window *) w->z_front, left, top, width, height);
|
||||||
ClearViewPortCache(w->viewport);
|
ClearViewportCache(w->viewport);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -23,8 +23,8 @@ static const int TILE_HEIGHT_STEP = 50; ///< One Z unit tile height difference i
|
|||||||
|
|
||||||
void SetSelectionRed(bool);
|
void SetSelectionRed(bool);
|
||||||
|
|
||||||
void ClearViewPortCache(Viewport *vp);
|
void ClearViewportCache(Viewport *vp);
|
||||||
void ClearViewPortCaches();
|
void ClearViewportCaches();
|
||||||
void DeleteWindowViewport(Window *w);
|
void DeleteWindowViewport(Window *w);
|
||||||
void InitializeWindowViewport(Window *w, int x, int y, int width, int height, uint32 follow_flags, ZoomLevel zoom);
|
void InitializeWindowViewport(Window *w, int x, int y, int width, int height, uint32 follow_flags, ZoomLevel zoom);
|
||||||
Viewport *IsPtInWindowViewport(const Window *w, int x, int y);
|
Viewport *IsPtInWindowViewport(const Window *w, int x, int y);
|
||||||
|
Reference in New Issue
Block a user