mirror of
https://github.com/HenkKalkwater/harbour-sailfin.git
synced 2024-05-04 05:22:42 +00:00
39 lines
1.1 KiB
C++
39 lines
1.1 KiB
C++
#ifndef QT_DEBUG
|
|
#include <QtQuick>
|
|
#endif
|
|
|
|
#include <QDebug>
|
|
#include <QQmlApplicationEngine>
|
|
#include <QGuiApplication>
|
|
#include <QString>
|
|
|
|
#include <QtCore/qloggingcategory.h>
|
|
|
|
#include <JellyfinQt/jellyfin.h>
|
|
|
|
int main(int argc, char** argv) {
|
|
QGuiApplication app(argc, argv);
|
|
app.setApplicationDisplayName(QStringLiteral("Sailfin QtQuick"));
|
|
app.setApplicationName("Sailfin QtQuick");
|
|
app.setOrganizationDomain("nl.netsoj.chris");
|
|
app.setOrganizationName("Chris Josten");
|
|
|
|
#if QT_VERSION >= QT_VERSION_CHECK(5, 15, 0)
|
|
// Disable Qt nagging about "implicitly defined onFoo properties in connections are deprecated",
|
|
// as we cannot yet move towards a newer version.
|
|
QLoggingCategory::setFilterRules("qt.qml.connections=false");
|
|
#endif
|
|
|
|
qDebug() << "Creating engine";
|
|
QQmlApplicationEngine engine;
|
|
|
|
qDebug() << "Registering types";
|
|
Jellyfin::JellyfinPlugin plugin;
|
|
plugin.registerTypes("nl.netsoj.chris.Jellyfin");
|
|
|
|
qDebug() << "Loading file";
|
|
engine.load(QStringLiteral("qrc:/qml/main.qml"));
|
|
qDebug() << "Entering event loop";
|
|
return app.exec();
|
|
}
|