mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-19 15:43:20 +00:00
LibWeb: Get rid of PaintableBox::is_viewport()
This function used layout node pointer to check if it's corresponding to viewport. There is no need for that, since `is_viewport_paintable()` does exactly the same check without going through layout node.
This commit is contained in:
parent
1ffb0ca311
commit
81aeee3fb4
Notes:
github-actions[bot]
2025-10-14 09:25:05 +00:00
Author: https://github.com/kalenikaliaksandr
Commit: 81aeee3fb4
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/6465
5 changed files with 9 additions and 11 deletions
|
@ -167,7 +167,7 @@ void paint_background(DisplayListRecordingContext& context, PaintableBox const&
|
|||
background_positioning_area.set_location(paintable_box.layout_node().root().navigable()->viewport_scroll_offset());
|
||||
break;
|
||||
case CSS::BackgroundAttachment::Local:
|
||||
if (!paintable_box.is_viewport()) {
|
||||
if (!paintable_box.is_viewport_paintable()) {
|
||||
auto scroll_offset = paintable_box.scroll_offset();
|
||||
background_positioning_area.translate_by(-scroll_offset.x(), -scroll_offset.y());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue