mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-22 15:40:19 +00:00
LibGUI: Use Object::remove_all_children() in BreadcrumbBar (#4580)
This commit is contained in:
parent
d1891f67ac
commit
d1366b660e
Notes:
sideshowbarker
2024-07-19 00:31:56 +09:00
Author: https://github.com/dantje 🔰 Commit: https://github.com/SerenityOS/serenity/commit/d1366b660ee Pull-request: https://github.com/SerenityOS/serenity/pull/4580
1 changed files with 1 additions and 5 deletions
|
@ -57,11 +57,7 @@ BreadcrumbBar::~BreadcrumbBar()
|
|||
void BreadcrumbBar::clear_segments()
|
||||
{
|
||||
m_segments.clear();
|
||||
|
||||
// FIXME: Should Core::Object have something like "remove_all_children()" perhaps?
|
||||
auto children = this->children();
|
||||
for (auto& child : children)
|
||||
child.remove_from_parent();
|
||||
remove_all_children();
|
||||
}
|
||||
|
||||
void BreadcrumbBar::append_segment(const String& text, const Gfx::Bitmap* icon, const String& data)
|
||||
|
|
Loading…
Reference in a new issue