-
Nicolas Werner authoredNicolas Werner authored
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
harbour-matrix.cpp 1.35 KiB
//#ifdef QT_QML_DEBUG
#include <QtQuick>
//#endif
#include <sailfishapp.h>
#include <mtx.hpp>
#include "login.h"
int main(int argc, char *argv[])
{
// SailfishApp::main() will display "qml/harbour-matrix.qml", if you need more
// control over initialization, you can use:
//
// - SailfishApp::application(int, char *[]) to get the QGuiApplication *
// - SailfishApp::createView() to get a new QQuickView * instance
// - SailfishApp::pathTo(QString) to get a QUrl to a resource file
// - SailfishApp::pathToMainQml() to get a QUrl to the main QML file
//
//return SailfishApp::main(argc, argv);
// To display the view, call "show()" (will show fullscreen on device).
// Set up QML engine.
QScopedPointer<QGuiApplication> app(SailfishApp::application(argc, argv));
QScopedPointer<QQuickView> v(SailfishApp::createView());
Login login;
v->rootContext()->setContextProperty("login", &login);
// If you wish to publish your app on the Jolla harbour, it is recommended
// that you prefix your internal namespaces with "harbour.".
//
// For details see:
// https://harbour.jolla.com/faq#1.5.0
//qmlRegisterType<DemoModel>("com.example", 1, 0, "DemoModel");
// Start the application.
v->setSource(SailfishApp::pathTo("qml/harbour-matrix.qml"));
v->show();
return app->exec();
}