From: Toni Wilen Date: Tue, 23 Apr 2024 17:34:15 +0000 (+0300) Subject: Multimonitor visible monitor check fix X-Git-Tag: 5300~27 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=c108288ccfacef1e604a25d348adbc5632d6e802;p=francis%2Fwinuae.git Multimonitor visible monitor check fix --- diff --git a/gfxboard.cpp b/gfxboard.cpp index d18c4399..f712ee27 100644 --- a/gfxboard.cpp +++ b/gfxboard.cpp @@ -838,7 +838,7 @@ void video_blit_memtoscreen(int x, int y, int y1, int y2, int w, int h) struct rtggfxboard *gb = &rtggfxboards[i]; if (gb->pcemdev && gb->pcemobject) { pcem_flush(gb, i); - if (rtg_visible[gb->monitor_id] >= 0 && gb->monswitch_delay == 0 && gb->monswitch_current == gb->monswitch_new) { + if (rtg_visible[gb->monitor_id] == i && gb->monswitch_delay == 0 && gb->monswitch_current == gb->monswitch_new) { if (gb->gfxboard_surface == NULL) { gb->gfxboard_surface = gfx_lock_picasso(gb->monitor_id, false); } @@ -1703,6 +1703,8 @@ void gfxboard_vsync_handler(bool full_redraw_required, bool redraw_required) } } + gfxboard_unlock(gb); + if (gb->monswitch_keep_trying) { vga_update_size_ext(gb); if (gb->vga_width > 16 && gb->vga_height > 16) {