aboutsummaryrefslogtreecommitdiffstats
path: root/homescreen/src/statusbarmodel.h
diff options
context:
space:
mode:
authorMatt Porter <mporter@konsulko.com>2018-07-27 13:07:56 -0400
committerMatt Porter <mporter@konsulko.com>2018-07-27 13:07:56 -0400
commitdb717523a6f9797312c94e756bac1b7b542e40ed (patch)
tree494726760bdf61f31b767216e5338bfbb06f5869 /homescreen/src/statusbarmodel.h
parenta8b94699ae7ec155729fcccda2be4f22328ca790 (diff)
Convert StatusBarModel to get WiFi status info from network binding
The StatusBarModel updates icons using an exposed DBus API that avoids the appfw. The new networking binding does not support the out of band StatusBar DBus API. Use events from the network binding (exposed as Qt properties) to update the WiFi status indicator. Bug-AGL: SPEC-1628 Change-Id: Ie91f69c1d5d54d4fb225e4e99a1d5a94a0dc83e7 Signed-off-by: Matt Porter <mporter@konsulko.com>
Diffstat (limited to 'homescreen/src/statusbarmodel.h')
-rw-r--r--homescreen/src/statusbarmodel.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/homescreen/src/statusbarmodel.h b/homescreen/src/statusbarmodel.h
index 8d6a70b..39fe148 100644
--- a/homescreen/src/statusbarmodel.h
+++ b/homescreen/src/statusbarmodel.h
@@ -26,14 +26,21 @@ public:
explicit StatusBarModel(QObject *parent = NULL);
~StatusBarModel();
+ void init(QUrl &url, QQmlContext *context);
int rowCount(const QModelIndex &parent = QModelIndex()) const override;
QVariant data(const QModelIndex &index, int role = Qt::DisplayRole) const override;
QHash<int, QByteArray> roleNames() const override;
+ // slots
+ void onWifiConnectedChanged(bool connected);
+ void onWifiEnabledChanged(bool enabled);
+ void onWifiStrengthChanged(int strength);
+
private:
class Private;
Private *d;
+ void setWifiStatus(bool connected, bool enabled, int strength);
};
#endif // STATUSBARMODEL_H