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);
}
}
}
+ gfxboard_unlock(gb);
+
if (gb->monswitch_keep_trying) {
vga_update_size_ext(gb);
if (gb->vga_width > 16 && gb->vga_height > 16) {