From 5ef90db242ad29c9772f2237b477c58ef65545c7 Mon Sep 17 00:00:00 2001 From: Scott Murray Date: Fri, 28 Jan 2022 16:54:55 -0500 Subject: Re-enable network support Rework network support code to use new connman-glib library instead of the previously disabled agl-service-network API. The only user visible change is that a few extra previously exported header files have been pruned from installation to avoid exposing GLib usage and potentially requiring users needing to build against it. Bug-AGL: SPEC-4182 Signed-off-by: Scott Murray Change-Id: Iab8f3c9d04ee603e06b80dfd92ac03d9d52af477 --- network/wiredadapter.h | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'network/wiredadapter.h') diff --git a/network/wiredadapter.h b/network/wiredadapter.h index 141ccfb..6bd3381 100644 --- a/network/wiredadapter.h +++ b/network/wiredadapter.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2019 Konsulko Group + * Copyright (C) 2019,2022 Konsulko Group * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -19,7 +19,6 @@ #include #include -#include #include #include "networkadapter.h" @@ -28,27 +27,27 @@ class WiredNetworkModel; class WiredAdapter : public QObject, public AdapterIf { - Q_OBJECT - Q_INTERFACES(AdapterIf) - public: + Q_OBJECT + Q_INTERFACES(AdapterIf) + public: explicit WiredAdapter(Network *network, QQmlContext *context, QObject *parent); virtual ~WiredAdapter(); bool wiredConnected() const { return m_wiredConnected; } bool wiredEnabled() const { return m_wiredEnabled; } - bool addService(QString id, QJsonObject properties) override; - void removeService(QString id) override; - void updateProperties(QString service, QJsonObject properties) override; + bool addService(const QString &id, const QVariantMap &properties) override; + void removeService(const QString &id) override; + void updateProperties(const QString &service, const QVariantMap &properties) override; QString getType() override { return "ethernet"; } - void updateStatus(QJsonObject properties) override; + void updateStatus(const QVariantMap &properties) override; - signals: +signals: void wiredConnectedChanged(bool connected); void wiredEnabledChanged(bool enabled); - private: +private: bool m_wiredConnected; bool m_wiredEnabled; WiredNetworkModel *m_model; -- cgit 1.2.3-korg