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

Userland: Port to automatic GML initializer where possible

This commit is contained in:
kleines Filmröllchen 2024-01-22 16:52:25 +01:00 committed by Andrew Kaster
parent dec066fa5c
commit adc845e0cb
41 changed files with 148 additions and 245 deletions

View file

@ -61,13 +61,6 @@ void CardGamePreview::paint_event(GUI::PaintEvent& event)
stack->paint(painter, background_color);
}
ErrorOr<NonnullRefPtr<CardSettingsWidget>> CardSettingsWidget::create()
{
auto card_settings_widget = TRY(try_create());
TRY(card_settings_widget->initialize());
return card_settings_widget;
}
ErrorOr<void> CardSettingsWidget::initialize()
{
auto background_color = Gfx::Color::from_string(Config::read_string("Games"sv, "Cards"sv, "BackgroundColor"sv)).value_or(Gfx::Color::from_rgb(0x008000));