1
0
mirror of https://github.com/OpenTTD/OpenTTD.git synced 2025-09-01 02:49:10 +00:00

(svn r15752) -Fix: don't try to (un)draw the cursor when the screen is not ready

This commit is contained in:
glx
2009-03-17 16:28:21 +00:00
parent 93be9a1c90
commit e968f5c572

View File

@@ -1285,6 +1285,9 @@ void ScreenSizeChanged()
void UndrawMouseCursor()
{
/* Don't undraw the mouse cursor if the screen is not ready */
if (_screen.dst_ptr == NULL) return;
if (_cursor.visible) {
Blitter *blitter = BlitterFactoryBase::GetCurrentBlitter();
_cursor.visible = false;
@@ -1300,6 +1303,9 @@ void DrawMouseCursor()
return;
#endif
/* Don't draw the mouse cursor if the screen is not ready */
if (_screen.dst_ptr == NULL) return;
Blitter *blitter = BlitterFactoryBase::GetCurrentBlitter();
int x;
int y;