Mercurial > minori
annotate src/main.cc @ 337:a7d4e5107531
dep/animone: REFACTOR ALL THE THINGS
1: animone now has its own syntax divergent from anisthesia,
making different platforms actually have their own sections
2: process names in animone are now called `comm' (this will
probably break things). this is what its called in bsd/linux
so I'm just going to use it everywhere
3: the X11 code now checks for the existence of a UTF-8 window title
and passes it if available
4: ANYTHING THATS NOT LINUX IS 100% UNTESTED AND CAN AND WILL BREAK!
I still actually need to test the bsd code. to be honest I'm probably
going to move all of the bsds into separate files because they're
all essentially different operating systems at this point
author | Paper <paper@paper.us.eu.org> |
---|---|
date | Wed, 19 Jun 2024 12:51:15 -0400 |
parents | b5d6c27c308f |
children |
rev | line source |
---|---|
325
78929794e7d8
pages/seasons: run seasons search in a separate thread
Paper <paper@paper.us.eu.org>
parents:
317
diff
changeset
|
1 #include "core/anime.h" |
258 | 2 #include "core/anime_db.h" |
325
78929794e7d8
pages/seasons: run seasons search in a separate thread
Paper <paper@paper.us.eu.org>
parents:
317
diff
changeset
|
3 #include "core/date.h" |
10 | 4 #include "core/session.h" |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
229
diff
changeset
|
5 #include "core/strings.h" |
258 | 6 #include "gui/window.h" |
250 | 7 #include "services/anilist.h" |
8 | |
10 | 9 #include <QApplication> |
258 | 10 #include <QLocale> |
46 | 11 #include <QStyleFactory> |
108 | 12 #include <QTranslator> |
10 | 13 |
317
b1f4d1867ab1
services: VERY initial Kitsu support
Paper <paper@paper.us.eu.org>
parents:
315
diff
changeset
|
14 #include <cstdlib> |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
229
diff
changeset
|
15 |
10 | 16 int main(int argc, char** argv) { |
17 QApplication app(argc, argv); | |
250 | 18 app.setApplicationName("minori"); |
19 app.setApplicationDisplayName("Minori"); | |
236
4d461ef7d424
HUGE UPDATE: convert build system to autotools
Paper <mrpapersonic@gmail.com>
parents:
229
diff
changeset
|
20 app.setAttribute(Qt::AA_DontShowIconsInMenus, true); |
10 | 21 |
273
f31305b9f60a
*: various code safety changes
Paper <paper@paper.us.eu.org>
parents:
258
diff
changeset
|
22 qRegisterMetaType<std::vector<std::string>>(); /* window.cc */ |
f31305b9f60a
*: various code safety changes
Paper <paper@paper.us.eu.org>
parents:
258
diff
changeset
|
23 qRegisterMetaType<std::vector<int>>(); /* search.cc */ |
315
34347fd2a2de
session: allow printing status messages
Paper <paper@paper.us.eu.org>
parents:
273
diff
changeset
|
24 qRegisterMetaType<std::string>(); |
327
b5d6c27c308f
anime: refactor Anime::SeriesSeason to Season class
Paper <paper@paper.us.eu.org>
parents:
325
diff
changeset
|
25 qRegisterMetaType<Anime::Season>(); |
273
f31305b9f60a
*: various code safety changes
Paper <paper@paper.us.eu.org>
parents:
258
diff
changeset
|
26 |
10 | 27 session.config.Load(); |
177
122fad646f81
anime/db: upgrade to c++17 style, make things easier to read
Paper <mrpapersonic@gmail.com>
parents:
175
diff
changeset
|
28 Anime::db.LoadDatabaseFromDisk(); |
10 | 29 |
30 MainWindow window; | |
31 | |
32 window.resize(941, 750); | |
11 | 33 window.setWindowTitle("Minori"); |
10 | 34 window.show(); |
35 | |
315
34347fd2a2de
session: allow printing status messages
Paper <paper@paper.us.eu.org>
parents:
273
diff
changeset
|
36 /* do this before starting the app... */ |
34347fd2a2de
session: allow printing status messages
Paper <paper@paper.us.eu.org>
parents:
273
diff
changeset
|
37 session.SetMainWindow(&window); |
34347fd2a2de
session: allow printing status messages
Paper <paper@paper.us.eu.org>
parents:
273
diff
changeset
|
38 |
10 | 39 return app.exec(); |
46 | 40 } |