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

LibGUI: Allow a wizard page to return null as its next page

This commit is contained in:
AnotherTest 2021-03-19 17:23:10 +03:30 committed by Andreas Kling
parent b072cb725f
commit 714ce4741d

View file

@ -79,7 +79,11 @@ WizardDialog::WizardDialog(Window* parent_window)
if (!current_page().can_go_next())
return done(ExecOK);
push_page(*current_page().next_page());
auto next_page = current_page().next_page();
if (!next_page)
return done(ExecOK);
push_page(*next_page);
};
auto& button_spacer = nav_container_widget.add<Widget>();