File indexing completed on 2025-03-23 12:49:54
0001 /* 0002 SPDX-FileCopyrightText: 2011 Ilia Kats <ilia-kats@gmx.net> 0003 SPDX-FileCopyrightText: 2013-2014 Jan Grulich <jgrulich@redhat.com> 0004 0005 SPDX-License-Identifier: LGPL-2.1-only OR LGPL-3.0-only OR LicenseRef-KDE-Accepted-LGPL 0006 */ 0007 0008 #ifndef NETWORKMANAGERQT_VPNCONNECTION_P_H 0009 #define NETWORKMANAGERQT_VPNCONNECTION_P_H 0010 0011 #include "activeconnection_p.h" 0012 #include "manager_p.h" 0013 #include "vpnconnection.h" 0014 0015 #include "vpnconnectioninterface.h" 0016 0017 namespace NetworkManager 0018 { 0019 class VpnConnectionPrivate : public ActiveConnectionPrivate 0020 { 0021 Q_OBJECT 0022 public: 0023 VpnConnectionPrivate(const QString &path, VpnConnection *q); 0024 0025 static NetworkManager::VpnConnection::State convertVpnConnectionState(uint state); 0026 static NetworkManager::VpnConnection::StateChangeReason convertVpnConnectionStateReason(uint reason); 0027 0028 QString banner; 0029 NetworkManager::VpnConnection::State state; 0030 OrgFreedesktopNetworkManagerVPNConnectionInterface iface; 0031 0032 Q_DECLARE_PUBLIC(VpnConnection) 0033 VpnConnection *q_ptr; 0034 0035 protected: 0036 /** 0037 * When subclassing make sure to call the parent class method 0038 * if the property was not useful to your new class 0039 */ 0040 void propertyChanged(const QString &property, const QVariant &value) override; 0041 0042 private Q_SLOTS: 0043 void dbusPropertiesChanged(const QString &interfaceName, const QVariantMap &properties, const QStringList &invalidatedProperties); 0044 void vpnStateChanged(uint new_state, uint reason); 0045 }; 0046 0047 } 0048 0049 #endif // NETWORKMANAGERQT_VPNCONNECTION_P_H