mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-10 18:10:56 +09:00
LibGUI: Use set_layout<LayoutType>() in lots of client code
This commit is contained in:
parent
03e0ddce52
commit
4697195645
Notes:
sideshowbarker
2024-07-19 08:54:51 +09:00
Author: https://github.com/awesomekling
Commit: 4697195645
45 changed files with 109 additions and 109 deletions
|
@ -97,7 +97,7 @@ void MessageBox::build()
|
|||
int text_width = widget->font().width(m_text);
|
||||
int icon_width = 0;
|
||||
|
||||
widget->set_layout(make<VerticalBoxLayout>());
|
||||
widget->set_layout<VerticalBoxLayout>();
|
||||
widget->set_fill_with_background_color(true);
|
||||
|
||||
widget->layout()->set_margins({ 0, 15, 0, 15 });
|
||||
|
@ -106,7 +106,7 @@ void MessageBox::build()
|
|||
RefPtr<Widget> message_container = widget;
|
||||
if (m_type != Type::None) {
|
||||
message_container = widget->add<Widget>();
|
||||
message_container->set_layout(make<HorizontalBoxLayout>());
|
||||
message_container->set_layout<HorizontalBoxLayout>();
|
||||
message_container->layout()->set_margins({ 8, 0, 8, 0 });
|
||||
message_container->layout()->set_spacing(8);
|
||||
|
||||
|
@ -122,7 +122,7 @@ void MessageBox::build()
|
|||
label->set_preferred_size(text_width, 16);
|
||||
|
||||
auto button_container = widget->add<Widget>();
|
||||
button_container->set_layout(make<HorizontalBoxLayout>());
|
||||
button_container->set_layout<HorizontalBoxLayout>();
|
||||
button_container->layout()->set_spacing(5);
|
||||
button_container->layout()->set_margins({ 15, 0, 15, 0 });
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue