Changeset View
Changeset View
Standalone View
Standalone View
src/activeconnection.h
Show First 20 Lines • Show All 52 Lines • ▼ Show 20 Line(s) | 48 | public: | |||
---|---|---|---|---|---|
53 | */ | 53 | */ | ||
54 | enum State { | 54 | enum State { | ||
55 | Unknown = 0, /**< The active connection is in an unknown state */ | 55 | Unknown = 0, /**< The active connection is in an unknown state */ | ||
56 | Activating, /**< The connection is activating */ | 56 | Activating, /**< The connection is activating */ | ||
57 | Activated, /**< The connection is activated */ | 57 | Activated, /**< The connection is activated */ | ||
58 | Deactivating, /**< The connection is being torn down and cleaned up */ | 58 | Deactivating, /**< The connection is being torn down and cleaned up */ | ||
59 | Deactivated /**< The connection is no longer active */ | 59 | Deactivated /**< The connection is no longer active */ | ||
60 | }; | 60 | }; | ||
61 | | ||||
62 | enum StateChangeReason { | ||||
63 | UnknownReason = 0, /**< The reason for the VPN connection state change is unknown.*/ | ||||
64 | NoneReason, /**< No reason was given for the VPN connection state change. */ | ||||
65 | UserDisconnectedReason, /**< The VPN connection changed state because the user disconnected it. */ | ||||
66 | DeviceDisconnectedReason, /**< The VPN connection changed state because the device it was using was disconnected. */ | ||||
67 | ServiceStoppedReason, /**< The service providing the VPN connection was stopped. */ | ||||
68 | IpConfigInvalidReason, /**< The IP config of the VPN connection was invalid. */ | ||||
69 | ConnectTimeoutReason, /**< The connection attempt to the VPN service timed out. */ | ||||
70 | ServiceStartTimeoutReason, /**< A timeout occurred while starting the service providing the VPN connection. */ | ||||
71 | ServiceStartFailedReason, /**< Starting the service starting the service providing the VPN connection failed. */ | ||||
72 | NoSecretsReason, /**< Necessary secrets for the VPN connection were not provided. */ | ||||
73 | LoginFailedReason, /**< Authentication to the VPN server failed. */ | ||||
74 | ConnectionRemovedReason, /**< The connection was deleted from settings. */ | ||||
75 | DependencyFailedReason, /**< Master connection of this connection failed to activate. */ | ||||
76 | DeviceRealizeFailedReason, /**< Could not create the software device link. */ | ||||
77 | DeviceRemovedReason /** < The device this connection depended on disappeared. */ | ||||
anthonyfieroni: All others are composed <-- real reason --> ## Reason, but this :) | |||||
78 | }; | ||||
79 | | ||||
61 | /** | 80 | /** | ||
62 | * Creates a new ActiveConnection object. | 81 | * Creates a new ActiveConnection object. | ||
63 | * | 82 | * | ||
64 | * @param path the DBus path of the device | 83 | * @param path the DBus path of the device | ||
65 | */ | 84 | */ | ||
66 | explicit ActiveConnection(const QString &path, QObject *parent = nullptr); | 85 | explicit ActiveConnection(const QString &path, QObject *parent = nullptr); | ||
67 | explicit ActiveConnection(ActiveConnectionPrivate &dd, QObject *parent = nullptr); | 86 | explicit ActiveConnection(ActiveConnectionPrivate &dd, QObject *parent = nullptr); | ||
68 | /** | 87 | /** | ||
▲ Show 20 Lines • Show All 122 Lines • ▼ Show 20 Line(s) | 171 | Q_SIGNALS: | |||
191 | */ | 210 | */ | ||
192 | void masterChanged(const QString &uni); | 211 | void masterChanged(const QString &uni); | ||
193 | /** | 212 | /** | ||
194 | * The @p path to the specific object changed | 213 | * The @p path to the specific object changed | ||
195 | */ | 214 | */ | ||
196 | void specificObjectChanged(const QString &path); | 215 | void specificObjectChanged(const QString &path); | ||
197 | /** | 216 | /** | ||
198 | * The @p state changed | 217 | * The @p state changed | ||
218 | * FIXME: remove this on API/ABI change | ||||
219 | * @deprecated keeping only for backward compatibility, there is new signal below with additional reason property | ||||
199 | */ | 220 | */ | ||
200 | void stateChanged(NetworkManager::ActiveConnection::State state); | 221 | void stateChanged(NetworkManager::ActiveConnection::State state); | ||
201 | /** | 222 | /** | ||
223 | * This signal is emitted when the connection @p state has changed | ||||
224 | * FIXME rename back to stateChanged on API/ABI change | ||||
225 | */ | ||||
226 | void stateChangedWithReason(NetworkManager::ActiveConnection::State state, NetworkManager::ActiveConnection::StateChangeReason reason); | ||||
227 | /** | ||||
202 | * The VPN property changed. | 228 | * The VPN property changed. | ||
203 | */ | 229 | */ | ||
204 | void vpnChanged(bool isVpn); | 230 | void vpnChanged(bool isVpn); | ||
205 | /** | 231 | /** | ||
206 | * The @p uuid changed. | 232 | * The @p uuid changed. | ||
207 | */ | 233 | */ | ||
208 | void uuidChanged(const QString &uuid); | 234 | void uuidChanged(const QString &uuid); | ||
209 | /** | 235 | /** | ||
Show All 14 Lines |
All others are composed <-- real reason --> ## Reason, but this :)