NDEVR
API Documentation
InitialSetupDialog

Shown after a new installation on a device, allowing the user to familiarize themselves with the environment and to setup any needed settings, such as language, and performing registration. More...

Collaboration diagram for InitialSetupDialog:
[legend]

Public Member Functions

 InitialSetupDialog (WindowManager *manager, QWidget *parent=nullptr)
 Constructs the initial setup dialog with the given window manager.
void addWidget (QWidget *widget)
 Adds a custom widget page to the setup wizard.
void finishedSignal ()
 Emitted when the user completes or dismisses the setup wizard.
bool hasContent () const
 Returns whether the dialog has any setup pages to display.
void removeWidget (QWidget *widget)
 Removes a previously added widget page from the setup wizard.
void resetDialog ()
 Resets the dialog to its initial state, returning to the first page.

Protected Member Functions

QSize minimumSizeHint () const override
 Returns the minimum recommended size for this dialog.
void retranslate ()
 Re-translates all user-facing strings when the language changes.
void setupActivationTab ()
 Creates the activation/registration page.
void setupButtons ()
 Creates the navigation buttons (next/previous) at the bottom of the dialog.
void setupFolderTab ()
 Creates the file and folder settings page.
void setupInitialPage ()
 Creates the initial welcome page with language and theme options.
void setupUnitsTab ()
 Creates the units configuration page.
void setVisible (bool visible) override
 Overrides visibility to handle setup completion logic.
QSize sizeHint () const override
 Returns the recommended size for this dialog.
void updateWidgets ()
 Updates the visibility and state of all widgets based on the current page.

Protected Attributes

NDEVRActivationDialog * m_activation_dialog = nullptr
 The activation/registration dialog page.
QWidget * m_first_page = nullptr
 The initial welcome page widget.
FileAndFolderSettingsDialogm_folder_dialog = nullptr
 The file and folder settings dialog page.
bool m_language_changed
 Whether the user changed the language during setup.
QCustomLabelm_language_info_label = nullptr
 Informational label describing language selection.
QCustomLabelm_language_label = nullptr
 Label for the language selection.
Buttonm_lighting_button = nullptr
 Button for toggling the light/dark theme.
QCustomLabelm_lighting_info_label = nullptr
 Informational label describing theme selection.
QCustomLabelm_lighting_label = nullptr
 Label for the light/dark theme setting.
QBoxLayout * m_main_layout = nullptr
 The main layout for the dialog.
Buttonm_next_button = nullptr
 Button to advance to the next setup page.
Buttonm_previous_button = nullptr
 Button to return to the previous setup page.
QCustomStackedWidgetm_stack = nullptr
 The stacked widget containing all setup pages.
QCustomLabelm_text = nullptr
 The welcome text label.
Buttonm_touch_button = nullptr
 Button for toggling touch-optimized mode.
QCustomLabelm_touch_info_label = nullptr
 Informational label describing touch optimization.
QCustomLabelm_touch_label = nullptr
 Label for the touch optimization setting.
TranslationCombom_translation_combo = nullptr
 Combo box for selecting the application language.
UnitsDialogm_unit_dialog = nullptr
 The units configuration dialog page.
ImageViewm_view = nullptr
 The branding image view on the welcome page.
WindowManagerm_window_manager = nullptr
 The window manager providing application context.

Detailed Description

Shown after a new installation on a device, allowing the user to familiarize themselves with the environment and to setup any needed settings, such as language, and performing registration.


Definition at line 22 of file InitialSetupDialog.h.

Constructor & Destructor Documentation

◆ InitialSetupDialog()

InitialSetupDialog::InitialSetupDialog ( WindowManager * manager,
QWidget * parent = nullptr )

Constructs the initial setup dialog with the given window manager.

Parameters
[in]managerThe window manager providing application context.
[in]parentThe parent widget, or nullptr if no parent.

Referenced by removeWidget().

Member Function Documentation

◆ addWidget()

void InitialSetupDialog::addWidget ( QWidget * widget)

Adds a custom widget page to the setup wizard.

Parameters
[in]widgetThe widget to add as a page.

◆ hasContent()

bool InitialSetupDialog::hasContent ( ) const

Returns whether the dialog has any setup pages to display.

Returns
True if the dialog contains at least one setup page.

◆ minimumSizeHint()

QSize InitialSetupDialog::minimumSizeHint ( ) const
overrideprotected

Returns the minimum recommended size for this dialog.

Returns
The minimum QSize for the dialog.

◆ removeWidget()

void InitialSetupDialog::removeWidget ( QWidget * widget)

Removes a previously added widget page from the setup wizard.

Parameters
[in]widgetThe widget to remove.

References InitialSetupDialog().

◆ setVisible()

void InitialSetupDialog::setVisible ( bool visible)
overrideprotected

Overrides visibility to handle setup completion logic.

Parameters
[in]visibleWhether the dialog should be visible.

◆ sizeHint()

QSize InitialSetupDialog::sizeHint ( ) const
overrideprotected

Returns the recommended size for this dialog.

Returns
The preferred QSize for the dialog.

The documentation for this class was generated from the following file: