-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
29 lines (27 loc) · 912 Bytes
/
main.cpp
File metadata and controls
29 lines (27 loc) · 912 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
/////////////////////////////////////////////////////////////////////////////
// Name: main.cpp
// Purpose: Main, load Go library, apply style
// Author: Jan Buchholz
// Created: 2026-04-23
// Changed: 2026-05-06
/////////////////////////////////////////////////////////////////////////////
#include "mainwindow.h"
#include <QApplication>
#include <QStyleFactory>
#include "jbgolib.hpp"
#include "apicall.h"
int main(int argc, char *argv[]) {
QApplication a(argc, argv);
GoLib api;
if (!api.load()) return -1; // LoadLibrary("jbembyapi")
#if defined (Q_OS_WIN)
a.setStyle(QStyleFactory::create("fusion"));
#elif defined (Q_OS_MAC)
a.setStyle(QStyleFactory::create("macos"));
#endif
qRegisterMetaType<EmbyCollection>("embyCollection");
APICall::setAPI(&api);
MainWindow w;
w.show();
return QCoreApplication::exec();
}