swift
serverform.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (C) 2014 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_NETWORKSERVERFORM_H
7 #define SWIFT_GUI_COMPONENTS_NETWORKSERVERFORM_H
8 
9 #include <QFrame>
10 #include <QObject>
11 #include <QScopedPointer>
12 #include <QString>
13 
14 #include "gui/editors/form.h"
15 #include "gui/swiftguiexport.h"
16 #include "misc/network/server.h"
17 #include "misc/statusmessagelist.h"
18 
19 namespace Ui
20 {
21  class CNetworkServerForm;
22 }
23 namespace swift::gui::editors
24 {
27  {
28  Q_OBJECT
29 
30  public:
32  explicit CServerForm(QWidget *parent = nullptr);
33 
35  ~CServerForm() override;
36 
38  void setServer(const swift::misc::network::CServer &server);
39 
41  swift::misc::network::CServer getServer() const;
42 
44  void resetToFirstTab();
45 
48  void setReadOnly(bool readonly) override;
49  swift::misc::CStatusMessageList validate(bool nested = false) const override;
51 
53  void showPasswordField(bool show);
54 
55  private:
56  void tempUnhidePassword();
57 
59  QString m_passwordNameLabel;
60  };
61 } // namespace swift::gui::editors
62 
63 #endif // SWIFT_GUI_COMPONENTS_NETWORKSERVERFORM_H
Form base class.
Definition: form.h:27
Status messages, e.g. from Core -> GUI.
Value object encapsulating information of a FSD server.
Definition: server.h:28
#define SWIFT_GUI_EXPORT
Export a class or function from the library.