22 #include <QDBusConnection>
24 #include <QStringList>
27 #include <unity/util/DefinesPtrs.h>
44 static void registerMetaTypes();
72 Connectivity(
const QDBusConnection& sessionConnection = QDBusConnection::sessionBus(), QObject* parent = 0);
76 Q_PROPERTY(
bool FlightMode READ flightMode WRITE setFlightMode NOTIFY flightModeUpdated)
77 bool flightMode()
const;
79 Q_PROPERTY(
bool online READ online NOTIFY onlineUpdated)
82 Q_PROPERTY(
bool limitedBandwith READ limitedBandwith NOTIFY limitedBandwithUpdated)
83 bool limitedBandwith()
const;
85 Q_PROPERTY(QVector<Limitations>
Limitations READ limitations NOTIFY limitationsUpdated)
86 QVector<Limitations> limitations()
const;
91 Q_PROPERTY(
bool WifiEnabled READ wifiEnabled WRITE setwifiEnabled NOTIFY wifiEnabledUpdated)
92 bool wifiEnabled()
const;
94 Q_PROPERTY(
bool UnstoppableOperationHappening READ unstoppableOperationHappening NOTIFY unstoppableOperationHappeningUpdated)
95 bool unstoppableOperationHappening()
const;
97 Q_PROPERTY(QByteArray hotspotSsid READ hotspotSsid WRITE setHotspotSsid NOTIFY hotspotSsidUpdated)
98 QByteArray hotspotSsid()
const;
100 Q_PROPERTY(QString hotspotPassword READ hotspotPassword WRITE setHotspotPassword NOTIFY hotspotPasswordUpdated)
101 QString hotspotPassword()
const;
103 Q_PROPERTY(
bool hotspotEnabled READ hotspotEnabled WRITE setHotspotEnabled NOTIFY hotspotEnabledUpdated)
104 bool hotspotEnabled()
const;
106 Q_PROPERTY(QString hotspotMode READ hotspotMode WRITE setHotspotMode NOTIFY hotspotModeUpdated)
107 QString hotspotMode()
const;
109 Q_PROPERTY(
bool hotspotStored READ hotspotStored NOTIFY hotspotStoredUpdated)
110 bool hotspotStored()
const;
112 Q_PROPERTY(
bool Initialized READ isInitialized NOTIFY initialized)
113 bool isInitialized()
const;
116 void setFlightMode(
bool enabled);
118 void setwifiEnabled(
bool enabled);
120 void setHotspotEnabled(
bool active);
122 void setHotspotSsid(
const QByteArray& ssid);
124 void setHotspotPassword(
const QString& password);
126 void setHotspotMode(
const QString& mode);
129 void flightModeUpdated(
bool);
131 void onlineUpdated(
bool value);
133 void limitedBandwithUpdated(
bool value);
135 void limitationsUpdated(
const QVector<Limitations>&);
139 void wifiEnabledUpdated(
bool);
141 void unstoppableOperationHappeningUpdated(
bool);
143 void hotspotSsidUpdated(
const QByteArray& name);
145 void hotspotPasswordUpdated(
const QString& password);
147 void hotspotEnabledUpdated(
bool);
149 void hotspotModeUpdated(
const QString& mode);
151 void hotspotStoredUpdated(
bool);
153 void reportError(
int reason);
159 std::shared_ptr<Priv>
d;
165 Q_DECLARE_METATYPE(QVector<
connectivityqt::Connectivity::Limitations>)
Definition: connectivity.cpp:30
Definition: connectivity.h:32
Limitations
enum for networking limitations
Definition: connectivity.h:51
Status
enum for networking status
Definition: connectivity.h:65
std::shared_ptr< Priv > d
Definition: connectivity.h:158