comparison src/main.cc @ 315:34347fd2a2de

session: allow printing status messages ...!
author Paper <paper@paper.us.eu.org>
date Tue, 11 Jun 2024 14:16:40 -0400
parents f31305b9f60a
children b1f4d1867ab1
comparison
equal deleted inserted replaced
314:76d7315504c4 315:34347fd2a2de
9 #include <QStyleFactory> 9 #include <QStyleFactory>
10 #include <QTranslator> 10 #include <QTranslator>
11 11
12 #include <iostream> 12 #include <iostream>
13 13
14 Session session;
15
16 int main(int argc, char** argv) { 14 int main(int argc, char** argv) {
17 QApplication app(argc, argv); 15 QApplication app(argc, argv);
18 app.setApplicationName("minori"); 16 app.setApplicationName("minori");
19 app.setApplicationDisplayName("Minori"); 17 app.setApplicationDisplayName("Minori");
20 app.setAttribute(Qt::AA_DontShowIconsInMenus, true); 18 app.setAttribute(Qt::AA_DontShowIconsInMenus, true);
21 19
22 qRegisterMetaType<std::vector<std::string>>(); /* window.cc */ 20 qRegisterMetaType<std::vector<std::string>>(); /* window.cc */
23 qRegisterMetaType<std::vector<int>>(); /* search.cc */ 21 qRegisterMetaType<std::vector<int>>(); /* search.cc */
22 qRegisterMetaType<std::string>();
24 23
25 session.config.Load(); 24 session.config.Load();
26 Anime::db.LoadDatabaseFromDisk(); 25 Anime::db.LoadDatabaseFromDisk();
27 26
28 MainWindow window; 27 MainWindow window;
29 28
30 window.resize(941, 750); 29 window.resize(941, 750);
31 window.setWindowTitle("Minori"); 30 window.setWindowTitle("Minori");
32 window.show(); 31 window.show();
33 32
33 /* do this before starting the app... */
34 session.SetMainWindow(&window);
35
34 return app.exec(); 36 return app.exec();
35 } 37 }