Finalizing initial qt5 version
Change-Id: Ib77cd8bffc8edeeaf4bfe81c8893a9de1d96de16
diff --git a/qt5/tray-menu.hpp b/qt5/tray-menu.hpp
index b4c2c33..10f45c3 100644
--- a/qt5/tray-menu.hpp
+++ b/qt5/tray-menu.hpp
@@ -28,6 +28,8 @@
#include <QtWidgets/QAction>
#include <QtWidgets/QMenu>
+#include <QtQml/QQmlContext>
+
namespace ndn {
class TrayMenu : public QWidget
@@ -42,15 +44,16 @@
nfdActivityUpdate(bool isActive);
public:
- TrayMenu();
+ explicit
+ TrayMenu(QQmlContext* context);
~TrayMenu();
Q_INVOKABLE void
- checkNfdRunning();
+ autoConfig();
Q_INVOKABLE void
- autoConfig();
+ startStopNfd();
private slots:
@@ -70,12 +73,12 @@
updateNfdActivityIcon(bool isActive);
private:
+ QQmlContext* m_context;
+ bool m_isNfdRunning;
QSystemTrayIcon *tray;
QMenu* menu;
QAction* pref;
QAction* quit;
- // QAction* start;
- // QAction* stop;
};
} // namespace ndn