mirror of
https://github.com/RGBCube/serenity
synced 2025-07-10 06:17:35 +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:
parent
5f5f837ec5
commit
41289e652f
1 changed files with 2 additions and 2 deletions
|
@ -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;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue