Cockatrice 2026-10-19-Development-3.1.2-beta.2
A virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
first_run_wizard_page.h
Go to the documentation of this file.
1#ifndef FIRST_RUN_WIZARD_PAGE_H
2#define FIRST_RUN_WIZARD_PAGE_H
3
4#include <QString>
5#include <QWidget>
6#include <qtmetamacros.h>
7
15class FirstRunWizardPage : public QWidget
16{
17 Q_OBJECT
18
19public:
20 explicit FirstRunWizardPage(QWidget *parent = nullptr) : QWidget(parent)
21 {
22 }
23
25 virtual void initializePage()
26 {
27 }
28
31 virtual bool validatePage()
32 {
33 return true;
34 }
35
38 virtual bool isComplete() const
39 {
40 return true;
41 }
42
44 virtual bool isSkippable() const
45 {
46 return false;
47 }
48
49 virtual QString stepTitle() const = 0;
50 virtual QString stepSubtitle() const
51 {
52 return {};
53 }
54
57 virtual QString nextButtonText() const
58 {
59 return {};
60 }
61
65 virtual bool handleNextClick()
66 {
67 return true;
68 }
69
70 virtual void retranslateUi() = 0;
71
72signals:
75};
76
77#endif // FIRST_RUN_WIZARD_PAGE_H
virtual QString nextButtonText() const
Override to replace the "Next"/"Finish" button text on this page. Return an empty string to use the d...
Definition first_run_wizard_page.h:57
virtual bool isComplete() const
Whether Next/Finish should currently be enabled. Pages doing async work can flip this mid-step; emit ...
Definition first_run_wizard_page.h:38
virtual bool validatePage()
Called before advancing past this page. Return false to block navigation; the page itself is responsi...
Definition first_run_wizard_page.h:31
FirstRunWizardPage(QWidget *parent=nullptr)
Definition first_run_wizard_page.h:20
virtual bool isSkippable() const
Whether the wizard's "Skip" button should be offered on this page.
Definition first_run_wizard_page.h:44
virtual void initializePage()
Called every time the page becomes visible, including navigating back to it.
Definition first_run_wizard_page.h:25
virtual QString stepTitle() const =0
virtual void retranslateUi()=0
virtual QString stepSubtitle() const
Definition first_run_wizard_page.h:50
virtual bool handleNextClick()
Called when the user presses the Next button. Return true to allow advancing to the next page,...
Definition first_run_wizard_page.h:65