There was register HistoryNotificationsModel in qml

This commit is contained in:
master 2023-04-05 15:33:24 +03:00
parent 1c6e7f06bc
commit 45edd82368

View File

@ -7,6 +7,7 @@
#include "notificationservice.h"
#include "qmlnotifyservice.h"
#include "historynotificationsmodel.h"
#include <QQmlApplicationEngine>
#include <QQmlContext>
@ -22,10 +23,12 @@ bool init(QQmlApplicationEngine *engine) {
return false;
initSNotufyResources();
QPointer<HistoryNotificationsModel> historyModel = new HistoryNotificationsModel();
engine->addImportPath(":/");
root->setContextProperty("notificationService", NotificationService::getService());
root->setContextProperty("historyNotificationsModel", historyModel);
return true;
}
}