6 #ifndef SWIFT_GUI_LOGINCOMPONENT_H
7 #define SWIFT_GUI_LOGINCOMPONENT_H
12 #include <QScopedPointer>
35 class CLoginComponent;
37 namespace swift::misc::simulation
40 class CSimulatedAircraft;
60 static const QStringList &getLogCategories();
72 void mainInfoAreaChanged(
const QWidget *currentWidget);
75 void setLogoffCountdown(std::chrono::seconds timeout = LogoffIntervalSeconds);
78 void toggleNetworkConnection();
104 bool updateOwnAircraftCallsignAndPilotFromGuiValues();
129 void loginCancelled();
132 void logoffCountdown();
135 void autoLogoffDetection();
138 void autoLogoffFrameRate(
bool fatal);
144 void toggleTimeout();
147 void updateUiConnectState();
150 void blinkConnectButton();
153 void setOkButtonString(
bool connected);
156 void startLogoffTimerCountdown();
159 bool isVatsimNetworkTabSelected()
const;
162 void loadRememberedUserData();
168 void onSimulatorStatusChanged(
int status);
175 void onServerTabWidgetChanged(
int index);
178 bool hasValidContexts()
const;
180 static constexpr std::chrono::milliseconds OverlayMessageMs { 5000 };
181 static constexpr std::chrono::seconds LogoffIntervalSeconds { 20 };
183 QScopedPointer<Ui::CLoginComponent> ui;
185 std::chrono::milliseconds { 1500 }, 10 };
186 bool m_updatePilotOnServerChanges =
true;
187 bool m_networkConnected =
false;
188 bool m_simulatorConnected =
false;
189 const QIcon m_iconPlay {
":/pastel/icons/pastel/16/control-play.png" };
190 const QIcon m_iconPause {
":/pastel/icons/pastel/16/control-pause.png" };
191 std::chrono::seconds m_logoffIntervalSeconds = LogoffIntervalSeconds;
192 QTimer m_logoffCountdownTimer;
Remembering the last servers and ecosystem.
Using this class provides a QFrame with the overlay functionality already integrated.
Login component to flight network.
void loginDataChangedDigest()
Relevant login data changed (digest version)
void loginOrLogoffCancelled()
Cancelled.
void setAutoPopupWizad(bool autoPopup)
Automatically popup.
void requestNetworkSettings()
Request network settings.
void loginOrLogoffSuccessful()
Login.
void requestLoginPage()
Request to be shown.
Receive 1..n signals, collect them over time, and resend afer n milliseconds.
Value object encapsulating information about a connection status.
Value object encapsulating information of a server.
Value object encapsulating information of a user.
Aircraft model (used by another pilot, my models on disk)
Comprehensive information of an aircraft.
High level reusable GUI components.
#define SWIFT_GUI_EXPORT
Export a class or function from the library.