Changeset View
Changeset View
Standalone View
Standalone View
src/gtkconfigkcmodule.h
Show All 23 Lines | |||||
24 | #ifndef GTKCONFIGKCMODULE_H | 24 | #ifndef GTKCONFIGKCMODULE_H | ||
25 | #define GTKCONFIGKCMODULE_H | 25 | #define GTKCONFIGKCMODULE_H | ||
26 | 26 | | |||
27 | #include <kcmodule.h> | 27 | #include <kcmodule.h> | ||
28 | #include "appearencegtk.h" | 28 | #include "appearencegtk.h" | ||
29 | #include "dialog_installer.h" | 29 | #include "dialog_installer.h" | ||
30 | #include "dialog_uninstaller.h" | 30 | #include "dialog_uninstaller.h" | ||
31 | #include <kns3/downloaddialog.h> | 31 | #include <kns3/downloaddialog.h> | ||
32 | #include "iconthemesmodel.h" | | |||
33 | #include "cursorthemesmodel.h" | | |||
34 | 32 | | |||
35 | class KProcess; | 33 | class KProcess; | ||
36 | namespace Ui { class Modulo; class GUI; } | 34 | namespace Ui { class Modulo; class GUI; } | ||
37 | 35 | | |||
38 | class GTKConfigKCModule : public KCModule | 36 | class GTKConfigKCModule : public KCModule | ||
39 | { | 37 | { | ||
40 | Q_OBJECT | 38 | Q_OBJECT | ||
41 | public: | 39 | public: | ||
42 | explicit GTKConfigKCModule(QWidget* parent = 0 ,const QVariantList& args = QVariantList() ); | 40 | explicit GTKConfigKCModule(QWidget* parent = 0 ,const QVariantList& args = QVariantList() ); | ||
43 | ~GTKConfigKCModule(); | 41 | ~GTKConfigKCModule(); | ||
44 | 42 | | |||
45 | void refreshThemesUi(bool useConfig=false); | 43 | void refreshThemesUi(bool useConfig=false); | ||
46 | 44 | | |||
47 | void save() override; | 45 | void save() override; | ||
48 | void defaults() override; | 46 | void defaults() override; | ||
49 | void load() override; | 47 | void load() override; | ||
50 | 48 | | |||
51 | public slots: | 49 | public slots: | ||
52 | void refreshLists(); | 50 | void refreshLists(); | ||
53 | void makePreviewIconTheme(); | | |||
54 | 51 | | |||
55 | ///it is called whenever something in the UI has changed | 52 | ///it is called whenever something in the UI has changed | ||
56 | void appChanged(); | 53 | void appChanged(); | ||
57 | void savePreviewConfig(); | 54 | void savePreviewConfig(); | ||
58 | 55 | | |||
59 | void showThemeGHNS(); | 56 | void showThemeGHNS(); | ||
60 | void installThemeGTK3GHNS(); | 57 | void installThemeGTK3GHNS(); | ||
61 | 58 | | |||
62 | void showDialogForInstall(); | 59 | void showDialogForInstall(); | ||
63 | void showDialogForUninstall(); | 60 | void showDialogForUninstall(); | ||
64 | 61 | | |||
65 | void runGtk2IfNecessary(bool); | 62 | void runGtk2IfNecessary(bool); | ||
66 | void runGtk3IfNecessary(bool); | 63 | void runGtk3IfNecessary(bool); | ||
67 | void untogglePreview(); | 64 | void untogglePreview(); | ||
68 | 65 | | |||
69 | signals: | | |||
70 | void selectedIconTheme(); | | |||
71 | | ||||
72 | private: | 66 | private: | ||
73 | void syncUI(); | 67 | void syncUI(); | ||
74 | bool m_loading = false; | 68 | bool m_loading = false; | ||
75 | 69 | | |||
76 | Ui::GUI *ui; | 70 | Ui::GUI *ui; | ||
77 | AppearenceGTK *appareance; | 71 | AppearenceGTK *appareance; | ||
78 | 72 | | |||
79 | DialogInstaller *installer; | 73 | DialogInstaller *installer; | ||
80 | DialogUninstaller *uninstaller; | 74 | DialogUninstaller *uninstaller; | ||
81 | KProcess* m_p2; | 75 | KProcess* m_p2; | ||
82 | KProcess* m_p3; | 76 | KProcess* m_p3; | ||
83 | QString m_tempGtk2Preview; | 77 | QString m_tempGtk2Preview; | ||
84 | QString m_tempGtk3Preview; | 78 | QString m_tempGtk3Preview; | ||
85 | bool m_saveEnabled; | 79 | bool m_saveEnabled; | ||
86 | CursorThemesModel* m_cursorsModel; | | |||
87 | IconThemesModel* m_iconsModel; | | |||
88 | }; | 80 | }; | ||
89 | 81 | | |||
90 | #endif // MODULO_H | 82 | #endif // MODULO_H |