debugged a crash, keys are now fetching, refactored main, added some exceptions instead of ints, debugged termination process
This commit is contained in:
parent
927bdf0dab
commit
4b68da458f
9 changed files with 321 additions and 130 deletions
42
main/root.h
42
main/root.h
|
@ -18,11 +18,53 @@
|
|||
#define ROOT_H
|
||||
|
||||
#include <QApplication>
|
||||
#include <QTranslator>
|
||||
#include <QIcon>
|
||||
#include <QSettings>
|
||||
#include <QThread>
|
||||
|
||||
#include <vector>
|
||||
|
||||
#include <core/squawk.h>
|
||||
#include <core/signalcatcher.h>
|
||||
|
||||
#include <shared/global.h>
|
||||
|
||||
#include "application.h"
|
||||
|
||||
class Root : public QApplication {
|
||||
Q_OBJECT
|
||||
public:
|
||||
Root(int& argc, char* argv[]);
|
||||
~Root();
|
||||
bool notify(QObject* receiver, QEvent* e) override;
|
||||
int run();
|
||||
|
||||
bool initializeSettings();
|
||||
|
||||
private slots:
|
||||
void onCoreDestroyed();
|
||||
|
||||
private:
|
||||
void initializeTranslation();
|
||||
void initializeAppIcon();
|
||||
void initializeComponents();
|
||||
|
||||
private:
|
||||
static const std::vector<unsigned int> appIconSizes;
|
||||
|
||||
SignalCatcher signalCatcher;
|
||||
QTranslator defaultTranslator;
|
||||
QTranslator currentTranslator;
|
||||
QIcon appIcon;
|
||||
QSettings settings;
|
||||
bool componentsInitialized;
|
||||
|
||||
Shared::Global* global;
|
||||
QThread* coreThread;
|
||||
Core::Squawk* core;
|
||||
Application* gui;
|
||||
|
||||
};
|
||||
|
||||
#endif // ROOT_H
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue