mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 07:48:11 +00:00
SharedGraphics: Make Painter clipping work with translated clip origin.
This commit is contained in:
parent
8eefdbdce8
commit
fd428d6ed3
6 changed files with 20 additions and 9 deletions
|
@ -865,8 +865,10 @@ void WSWindowManager::compose()
|
|||
m_back_painter->set_clip_rect(dirty_rect);
|
||||
paint_window_frame(window);
|
||||
Rect dirty_rect_in_window_coordinates = Rect::intersection(dirty_rect, window.rect());
|
||||
if (dirty_rect_in_window_coordinates.is_empty())
|
||||
if (dirty_rect_in_window_coordinates.is_empty()) {
|
||||
m_back_painter->clear_clip_rect();
|
||||
continue;
|
||||
}
|
||||
dirty_rect_in_window_coordinates.set_x(dirty_rect_in_window_coordinates.x() - window.x());
|
||||
dirty_rect_in_window_coordinates.set_y(dirty_rect_in_window_coordinates.y() - window.y());
|
||||
auto dst = window.position();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue