swift
matchingform.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_EDITORS_MATCHINGFORM_H
7 #define SWIFT_GUI_EDITORS_MATCHINGFORM_H
8 
9 #include <QScopedPointer>
10 
11 #include "gui/editors/form.h"
12 #include "misc/directories.h"
14 
15 namespace Ui
16 {
17  class CMatchingForm;
18 }
19 namespace swift::gui::editors
20 {
22  class CMatchingForm : public CForm
23  {
24  Q_OBJECT
25 
26  public:
28  explicit CMatchingForm(QWidget *parent = nullptr);
29 
31  virtual ~CMatchingForm() override;
32 
35  virtual void setReadOnly(bool readonly) override;
36  virtual swift::misc::CStatusMessageList validate(bool withNestedForms) const override;
38 
41 
44 
46  void clear();
47 
48  private:
51 
53  swift::misc::simulation::CAircraftMatcherSetup::MatchingMode matchingMode() const;
54 
57 
59  void setPickStrategy(const swift::misc::simulation::CAircraftMatcherSetup &setup);
60 
62  void setMatchingAlgorithm(const swift::misc::simulation::CAircraftMatcherSetup &setup);
63 
65  void onAlgorithmChanged();
66 
68  void onAirlineGroupChanged();
69 
72  void resetByAlgorithm();
73  void resetAll();
75 
77  void fileDialog();
78 
80  this
81  };
82  QScopedPointer<Ui::CMatchingForm> ui;
83  };
84 } // namespace swift::gui::editors
85 
86 #endif // SWIFT_GUI_EDITORS_MATCHINGFORM_H
Form base class.
Definition: form.h:27
CMatchingForm(QWidget *parent=nullptr)
Constructor.
void setValue(const swift::misc::simulation::CAircraftMatcherSetup &setup)
Set valued.
virtual swift::misc::CStatusMessageList validate(bool withNestedForms) const
Validate, empty list means OK.
virtual ~CMatchingForm()
Destructor.
swift::misc::simulation::CAircraftMatcherSetup value() const
Value.
virtual void setReadOnly(bool readonly)
Set editable.
Status messages, e.g. from Core -> GUI.
PickSimilarStrategy
How to pick among similar candiates.