mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-28 12:18:25 +00:00
LibCore+LibGUI: Switch to using AK::is and AK::downcast
This commit is contained in:
@@ -63,9 +63,9 @@ void StackWidget::resize_event(ResizeEvent& event)
|
||||
|
||||
void StackWidget::child_event(Core::ChildEvent& event)
|
||||
{
|
||||
if (!event.child() || !Core::is<Widget>(*event.child()))
|
||||
if (!event.child() || !is<Widget>(*event.child()))
|
||||
return Widget::child_event(event);
|
||||
auto& child = Core::to<Widget>(*event.child());
|
||||
auto& child = downcast<Widget>(*event.child());
|
||||
if (event.type() == Event::ChildAdded) {
|
||||
if (!m_active_widget)
|
||||
set_active_widget(&child);
|
||||
|
||||
Reference in New Issue
Block a user