mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-06 08:36:15 +00:00
GWidget: On second thought, don't assert on negative sizes in rects
Just neutralize incoming negative-size rects in set_relative_rect().
This commit is contained in:
@@ -42,9 +42,9 @@ void GWidget::child_event(CChildEvent& event)
|
||||
return CObject::child_event(event);
|
||||
}
|
||||
|
||||
void GWidget::set_relative_rect(const Rect& rect)
|
||||
void GWidget::set_relative_rect(const Rect& a_rect)
|
||||
{
|
||||
ASSERT(rect.width() >= 0 && rect.height() >= 0);
|
||||
Rect rect = a_rect.is_empty() ? Rect() : a_rect;
|
||||
|
||||
if (rect == m_relative_rect)
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user