WindowServer: Fix drawing wallpaper on additional screens

We need to translate the source rectangle relative to the screen
location when blitting from the wallpaper bitmap.
This commit is contained in:
Tom 2023-02-17 21:18:02 -07:00 committed by Linus Groh
commit 328a64fbdc
Notes: sideshowbarker 2024-07-17 07:19:27 +09:00

View file

@ -320,7 +320,7 @@ void Compositor::compose()
painter.draw_tiled_bitmap(rect, *m_wallpaper);
} else if (m_wallpaper_mode == WallpaperMode::Stretch) {
VERIFY(screen.compositor_screen_data().m_wallpaper_bitmap);
painter.blit(rect.location(), *screen.compositor_screen_data().m_wallpaper_bitmap, rect);
painter.blit(rect.location(), *screen.compositor_screen_data().m_wallpaper_bitmap, rect.translated(-screen.location()));
} else {
VERIFY_NOT_REACHED();
}