1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 22:07:35 +00:00

Userland: Prefer _string over _short_string

As `_string` can't fail anymore (since 3434412), there are no real
benefits to use the short variant in most cases.
This commit is contained in:
Lucas CHOLLET 2023-08-07 22:26:17 -04:00 committed by Andreas Kling
parent a5edc9cdfc
commit 3f35ffb648
198 changed files with 684 additions and 684 deletions

View file

@ -24,7 +24,7 @@ CreateNewLayerDialog::CreateNewLayerDialog(Gfx::IntSize suggested_size, GUI::Win
main_widget->set_fill_with_background_color(true);
main_widget->set_layout<GUI::VerticalBoxLayout>(4);
auto& name_label = main_widget->add<GUI::Label>("Name:"_short_string);
auto& name_label = main_widget->add<GUI::Label>("Name:"_string);
name_label.set_text_alignment(Gfx::TextAlignment::CenterLeft);
m_name_textbox = main_widget->add<GUI::TextBox>();
@ -34,12 +34,12 @@ CreateNewLayerDialog::CreateNewLayerDialog(Gfx::IntSize suggested_size, GUI::Win
m_layer_name = m_name_textbox->text();
};
auto& width_label = main_widget->add<GUI::Label>("Width:"_short_string);
auto& width_label = main_widget->add<GUI::Label>("Width:"_string);
width_label.set_text_alignment(Gfx::TextAlignment::CenterLeft);
auto& width_spinbox = main_widget->add<GUI::SpinBox>();
auto& height_label = main_widget->add<GUI::Label>("Height:"_short_string);
auto& height_label = main_widget->add<GUI::Label>("Height:"_string);
height_label.set_text_alignment(Gfx::TextAlignment::CenterLeft);
auto& height_spinbox = main_widget->add<GUI::SpinBox>();
@ -47,13 +47,13 @@ CreateNewLayerDialog::CreateNewLayerDialog(Gfx::IntSize suggested_size, GUI::Win
auto& button_container = main_widget->add<GUI::Widget>();
button_container.set_layout<GUI::HorizontalBoxLayout>();
auto& ok_button = button_container.add<GUI::Button>("OK"_short_string);
auto& ok_button = button_container.add<GUI::Button>("OK"_string);
ok_button.on_click = [this](auto) {
done(ExecResult::OK);
};
ok_button.set_default(true);
auto& cancel_button = button_container.add<GUI::Button>("Cancel"_short_string);
auto& cancel_button = button_container.add<GUI::Button>("Cancel"_string);
cancel_button.on_click = [this](auto) {
done(ExecResult::Cancel);
};