Fixed mouse cursor location for scaled dmabuf
cover Fixed mouse cursor location for scaled dmabuf
When a GVT-g virtual machine using dmabuf has its display output scaled by the gtk UI, its mouse cursor is positioned incorrectly.
This patch fixes that.
Qiming HOU (1):
hw/gtk-egl: fixed dmabuf cursor location when the main buffer is
scaled
ui/gtk-egl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Signature · 1 line
2.17.1.windows.2
PATCH 1/1 hw/gtk-egl: fixed dmabuf cursor location when the main buffer is scaled
Signed-off-by Qiming HOU <[email protected]>
--- ui/gtk-egl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
ui/gtk-egl.c +1 -1
@@ -272,7 +272,7 @@ void gd_egl_scanout_flush(DisplayChangeListener *dcl, vc->gfx.y0_top);egl_texture_blend (vc->gfx.gls, &vc->gfx.win_fb, &vc->gfx.cursor_fb, vc->gfx.y0_top, - vc->gfx.cursor_x, vc->gfx.cursor_y); + vc->gfx.cursor_x * ww / vc->gfx.w, vc->gfx.cursor_y * wh / vc->gfx.h); }else {egl_fb_blit (&vc->gfx.win_fb, &vc->gfx.guest_fb, !vc->gfx.y0_top); }
Signature · 1 line
2.17.1.windows.2