Index: sources/view/VNetworkModel.h =================================================================== diff -u -rea52cee2614f319804690a9b1d5091bed9676753 -r5600d2133dd0ea6dc1f733aa78bd26e2a4892a38 --- sources/view/VNetworkModel.h (.../VNetworkModel.h) (revision ea52cee2614f319804690a9b1d5091bed9676753) +++ sources/view/VNetworkModel.h (.../VNetworkModel.h) (revision 5600d2133dd0ea6dc1f733aa78bd26e2a4892a38) @@ -26,28 +26,34 @@ { Q_OBJECT - PROPERTY(bool, scanInProgress, false) + PROPERTY(bool , scanInProgress, false) + PROPERTY(QString, status , "") public: // Note: VIEW_DEC_CLASS(VNetworkModel) requires QObject as the parent, so it's necessary to define it here // Otherwise a VIEW_DEC_CLASS macro could allow specifying the parent class with QObject as the default VNetworkModel(QAbstractListModel *parent = nullptr) : QAbstractListModel(parent) { initConnections(); } enum NetworkDataRole { - SSIDRole = Qt::UserRole + 1, + MacAddressRole = Qt::UserRole + 1, + SSIDRole, SecurityLevelRole, StatusRole, + SignalLevelRole, }; void addNetwork (const Network &network); int rowCount (const QModelIndex &parent = QModelIndex()) const; QVariant data (const QModelIndex &index, int role = Qt::DisplayRole) const; signals: void didScan(); + void didJoinNetwork(const Network, const QString); public slots: void doScan(); void doAddNetwork(const Network &vNetwork); + bool doCheckIfConnected(const QString &vMacAddress); + void doJoinNetwork(const QString &vMacAddress, const QString &vPassword); protected: QHash roleNames() const;