mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-23 08:06:11 +00:00
LibWeb: Use CSS Pixels for viewport rects
This commit is contained in:
@@ -1437,10 +1437,10 @@ void StyleComputer::invalidate_rule_cache()
|
||||
m_rule_cache = nullptr;
|
||||
}
|
||||
|
||||
Gfx::IntRect StyleComputer::viewport_rect() const
|
||||
CSSPixelRect StyleComputer::viewport_rect() const
|
||||
{
|
||||
if (auto const* browsing_context = document().browsing_context())
|
||||
return browsing_context->viewport_rect().to_type<float>().to_type<int>();
|
||||
return browsing_context->viewport_rect();
|
||||
return {};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user