annotate src/include/window.h @ 6:1d82f6e04d7d

Update: add first parts to the settings dialog
author Paper <mrpapersonic@gmail.com>
date Wed, 16 Aug 2023 00:49:17 -0400
parents 5af270662505
children 07a9095eaeed
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
1 #ifndef __window_h
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
2 # define __window_h
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
3 /* FIXME: include these in specific .cpp files */
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
4 # include <QApplication>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
5 # include <QMainWindow>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
6 # include <QToolBar>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
7 # include <QMenuBar>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
8 # include <QWidget>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
9 # include <QTreeView>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
10 # include <QMessageBox>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
11 # include <QDesktopServices>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
12 # include <QUrl>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
13 # include <QInputDialog>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
14 # include <QDate>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
15 # include <QHeaderView>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
16 # include <QShortcut>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
17 # include <QFile>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
18 # include <QTextStream>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
19 # include <QCloseEvent>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
20 # include <QPlainTextEdit>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
21 # include <QLabel>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
22 # include <QHBoxLayout>
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
23 # include <QTextStream>
6
1d82f6e04d7d Update: add first parts to the settings dialog
Paper <mrpapersonic@gmail.com>
parents: 4
diff changeset
24 # include <QSortFilterProxyModel>
2
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
25 # include "config.h"
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
26 //# include "statistics.h"
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
27 //# include "now_playing.h"
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
28
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
29 class MainWindow : public QMainWindow {
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
30 public:
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
31 MainWindow(QWidget* parent = nullptr);
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
32 void SetActivePage(QWidget* page);
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
33 void SetStyleSheet(enum Themes theme);
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
34 void ThemeChanged();
4
5af270662505 Set override functions as override
Paper <mrpapersonic@gmail.com>
parents: 2
diff changeset
35 void closeEvent(QCloseEvent* event) override;
2
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
36
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
37 private:
6
1d82f6e04d7d Update: add first parts to the settings dialog
Paper <mrpapersonic@gmail.com>
parents: 4
diff changeset
38 QWidget* main_widget;
2
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
39 QWidget* anime_list_page;
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
40 };
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
41
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
42 struct Session {
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
43 Config config;
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
44 };
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
45
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
46 extern Session session;
Paper <mrpapersonic@gmail.com>
parents: 1
diff changeset
47 #endif // __window_h