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

CrashReporter: Factorize exiting behavior to window->close()

This commit is contained in:
Lucas CHOLLET 2022-12-08 13:55:25 +01:00 committed by Andreas Kling
parent fef255ee22
commit f14006637d

View file

@ -264,9 +264,7 @@ ErrorOr<int> serenity_main(Main::Arguments arguments)
auto& close_button = *widget->find_descendant_of_type_named<GUI::Button>("close_button");
close_button.on_click = [&](auto) {
if (unlink_on_exit)
unlink_coredump(coredump_path);
app->quit();
window->close();
};
close_button.set_focus(true);