swift
src
gui
components
legalinfocomponent.h
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: Copyright (C) 2018 swift Project Community / Contributors
2
// SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1
3
5
6
#ifndef SWIFT_GUI_COMPONENTS_LEGALINFOCOMPONENT_H
7
#define SWIFT_GUI_COMPONENTS_LEGALINFOCOMPONENT_H
8
9
#include <QFrame>
10
#include <QScopedPointer>
11
#include <QWizardPage>
12
13
#include "
core/application/applicationsettings.h
"
14
#include "
gui/overlaymessagesframe.h
"
15
16
namespace
Ui
17
{
18
class
CLegalInfoComponent;
19
}
20
namespace
swift::gui::components
21
{
25
class
CLegalInfoComponent
:
public
COverlayMessagesFrame
26
{
27
Q_OBJECT
28
29
public
:
31
explicit
CLegalInfoComponent
(QWidget *parent =
nullptr
);
32
34
virtual
~CLegalInfoComponent
();
35
37
bool
isAgreedTo
()
const
;
38
40
bool
validateAgreement
();
41
42
private
:
44
void
onAllowCrashDumps(
bool
checked);
45
47
void
setChecklistInfo();
48
49
QScopedPointer<Ui::CLegalInfoComponent> ui;
50
swift::misc::CSetting<swift::core::application::TCrashDumpUploadEnabled>
m_crashDumpUploadEnabled {
this
};
51
};
52
56
class
CLegalInfoWizardPage
:
public
QWizardPage
57
{
58
Q_OBJECT
59
60
public
:
62
using
QWizardPage::QWizardPage;
63
65
void
setConfigComponent
(
CLegalInfoComponent
*config) { m_legalInfo = config; }
66
68
virtual
bool
validatePage
()
override
;
69
70
private
:
71
CLegalInfoComponent
*m_legalInfo =
nullptr
;
72
};
73
}
// namespace swift::gui::components
74
75
#endif
// SWIFT_GUI_COMPONENTS_LEGALINFOCOMPONENT_H
applicationsettings.h
swift::gui::COverlayMessagesFrame
Using this class provides a QFrame with the overlay functionality already integrated.
Definition:
overlaymessagesframe.h:381
swift::gui::components::CLegalInfoComponent
swift legal information
Definition:
legalinfocomponent.h:26
swift::gui::components::CLegalInfoComponent::validateAgreement
bool validateAgreement()
Validate that the agreement is accepted.
Definition:
legalinfocomponent.cpp:41
swift::gui::components::CLegalInfoComponent::isAgreedTo
bool isAgreedTo() const
Agreed with?
Definition:
legalinfocomponent.cpp:39
swift::gui::components::CLegalInfoComponent::CLegalInfoComponent
CLegalInfoComponent(QWidget *parent=nullptr)
Constructor.
Definition:
legalinfocomponent.cpp:24
swift::gui::components::CLegalInfoComponent::~CLegalInfoComponent
virtual ~CLegalInfoComponent()
Destructor.
Definition:
legalinfocomponent.cpp:37
swift::gui::components::CLegalInfoWizardPage
Wizard page for CLegalInfoComponent.
Definition:
legalinfocomponent.h:57
swift::gui::components::CLegalInfoWizardPage::validatePage
virtual bool validatePage()
Definition:
legalinfocomponent.cpp:67
swift::gui::components::CLegalInfoWizardPage::setConfigComponent
void setConfigComponent(CLegalInfoComponent *config)
Set config.
Definition:
legalinfocomponent.h:65
swift::misc::CSetting< swift::core::application::TCrashDumpUploadEnabled >
swift::gui::components
High level reusable GUI components.
Definition:
aboutdialog.cpp:13
overlaymessagesframe.h
Generated on Mon Mar 24 2025 16:42:20 for swift by
1.9.1