1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 03:27:34 +00:00

Applications+Demos+LibGUI: Migrate to fallible WizardDialogs and Pages

And port page text to String. Also removes WizardDialog::show() helper
as all current implementations prefer to derive their own Dialog.
This commit is contained in:
thankyouverycool 2023-06-08 07:46:11 -04:00 committed by Andreas Kling
parent 96e60c98cf
commit caa8f43dbe
12 changed files with 178 additions and 115 deletions

View file

@ -14,15 +14,20 @@
namespace GUI {
class CoverWizardPage : public AbstractWizardPage {
C_OBJECT(CoverWizardPage);
C_OBJECT_ABSTRACT(CoverWizardPage);
static ErrorOr<NonnullRefPtr<CoverWizardPage>> create(StringView title, StringView subtitle);
ImageWidget& banner_image_widget() { return *m_banner_image_widget; }
void set_header_text(DeprecatedString const& text);
void set_body_text(DeprecatedString const& text);
void set_header_text(String);
void set_body_text(String);
protected:
virtual ErrorOr<void> build(String title, String subtitle);
private:
explicit CoverWizardPage();
CoverWizardPage() = default;
RefPtr<ImageWidget> m_banner_image_widget;
RefPtr<Widget> m_content_widget;