1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 06:48:12 +00:00

LibWeb: Switch to using AK::is and AK::downcast

This commit is contained in:
Andreas Kling 2020-07-26 17:16:18 +02:00
parent fe6474e692
commit 71556e39a4
73 changed files with 249 additions and 433 deletions

View file

@ -54,7 +54,7 @@ void StackingContext::paint(PaintContext& context, LayoutNode::PaintPhase phase)
} else {
// NOTE: LayoutDocument::paint() merely calls StackingContext::paint()
// so we call its base class instead.
to<LayoutDocument>(m_box).LayoutBlock::paint(context, phase);
downcast<LayoutDocument>(m_box).LayoutBlock::paint(context, phase);
}
for (auto* child : m_children) {
child->paint(context, phase);
@ -69,7 +69,7 @@ HitTestResult StackingContext::hit_test(const Gfx::IntPoint& position) const
} else {
// NOTE: LayoutDocument::hit_test() merely calls StackingContext::hit_test()
// so we call its base class instead.
result = to<LayoutDocument>(m_box).LayoutBlock::hit_test(position);
result = downcast<LayoutDocument>(m_box).LayoutBlock::hit_test(position);
}
for (auto* child : m_children) {