swift
src
gui
editors
pilotform.h
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: Copyright (C) 2017 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_EDITORS_PILOTFORM_H
7
#define SWIFT_GUI_EDITORS_PILOTFORM_H
8
9
#include <QFrame>
10
#include <QIntValidator>
11
#include <QScopedPointer>
12
13
#include "
gui/editors/form.h
"
14
#include "
gui/swiftguiexport.h
"
15
#include "
misc/network/entityflags.h
"
16
#include "
misc/network/user.h
"
17
18
namespace
Ui
19
{
20
class
CPilotForm;
21
}
22
namespace
swift::gui::editors
23
{
25
class
SWIFT_GUI_EXPORT
CPilotForm
:
public
CForm
26
{
27
Q_OBJECT
28
29
public
:
31
explicit
CPilotForm
(QWidget *parent =
nullptr
);
32
34
virtual
~
CPilotForm
()
override
;
35
37
void
setVatsimValidation(
bool
vatsim);
38
40
swift::misc::network::CUser
getUser()
const
;
41
43
void
setUser(
const
swift::misc::network::CUser
&user);
44
46
void
clear();
47
50
virtual
void
setReadOnly(
bool
readonly)
override
;
51
virtual
swift::misc::CStatusMessageList
validate(
bool
nested =
false
)
const override
;
53
54
private
:
56
void
unhidePassword();
57
59
void
doValidation();
60
61
QScopedPointer<Ui::CPilotForm> ui;
62
QScopedPointer<QIntValidator> m_vatsimIntValidator {
new
QIntValidator(100000, 9999999,
this
) };
63
bool
m_vatsim =
false
;
64
};
65
}
// namespace swift::gui::editors
66
67
#endif
// SWIFT_GUI_EDITORS_PILOTFORM_H
swift::gui::editors::CForm
Form base class.
Definition:
form.h:27
swift::gui::editors::CPilotForm
Pilot form (name, homebase)
Definition:
pilotform.h:26
swift::misc::CStatusMessageList
Status messages, e.g. from Core -> GUI.
Definition:
statusmessagelist.h:33
swift::misc::network::CUser
Value object encapsulating information of a user.
Definition:
user.h:28
entityflags.h
form.h
swiftguiexport.h
SWIFT_GUI_EXPORT
#define SWIFT_GUI_EXPORT
Export a class or function from the library.
Definition:
swiftguiexport.h:19
user.h
Generated on Mon Mar 24 2025 16:42:20 for swift by
1.9.1