-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy paththemehandler.h
More file actions
executable file
·44 lines (35 loc) · 948 Bytes
/
themehandler.h
File metadata and controls
executable file
·44 lines (35 loc) · 948 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
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#ifndef THEMEHANDLER_H
#define THEMEHANDLER_H
#include <QObject>
#include "thememodel.h"
class MGConfItem;
class QSettings;
class ThemeHandler : public QObject
{
Q_OBJECT
public:
explicit ThemeHandler(QObject *parent = 0);
void fetchCurrentTheme();
signals:
void currentThemeChanged(int index);
void newThemeApplied();
void themeChangeCanceled();
void cacheFixSucceeded();
void cacheFixFailed();
public slots:
Q_INVOKABLE void changeTheme(int index);
Q_INVOKABLE ThemeModel* themeModel();
Q_INVOKABLE void fixEmoticonCache();
private slots:
void updateCurrentTheme();
private:
QList<ThemeModel::ThemeInfo> findAvailableThemes();
void initializeGConfItem();
void populateModel();
QSettings* themeFile(const QString& theme);
ThemeModel* m_model;
int m_currentThemeIndex;
MGConfItem* m_gconfItem;
// QProcess* m_rebootProcess;
};
#endif // THEMEHANDLER_H