From 8fcd92c38af19ebfc637e7a0dc623371453d986c Mon Sep 17 00:00:00 2001 From: Ovnuniarchos Date: Tue, 23 Aug 2016 07:56:44 +0200 Subject: Mouse hotspot is not honored. --- servers/visual/visual_server_raster.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'servers/visual') diff --git a/servers/visual/visual_server_raster.cpp b/servers/visual/visual_server_raster.cpp index d89ea887fa..2489dd5381 100644 --- a/servers/visual/visual_server_raster.cpp +++ b/servers/visual/visual_server_raster.cpp @@ -7533,10 +7533,10 @@ void VisualServerRaster::_draw_cursors_and_margins() { ERR_CONTINUE( !tex ); if (cursors[i].region.has_no_area()) { Point2 size(texture_get_width(tex), texture_get_height(tex)); - rasterizer->canvas_draw_rect(Rect2(cursors[i].pos, size), 0, Rect2(), tex, Color(1, 1, 1, 1)); + rasterizer->canvas_draw_rect(Rect2(cursors[i].pos-cursors[i].center, size), 0, Rect2(), tex, Color(1, 1, 1, 1)); } else { Point2 size = cursors[i].region.size; - rasterizer->canvas_draw_rect(Rect2(cursors[i].pos, size), Rasterizer::CANVAS_RECT_REGION, cursors[i].region, tex, Color(1, 1, 1, 1)); + rasterizer->canvas_draw_rect(Rect2(cursors[i].pos-cursors[i].center, size), Rasterizer::CANVAS_RECT_REGION, cursors[i].region, tex, Color(1, 1, 1, 1)); } }; -- cgit v1.2.3