]> cloud.milkyroute.net Git - dolphin.git/blob - src/settings/dolphinsettingsdialog.h
Build with QT_NO_KEYWORDS
[dolphin.git] / src / settings / dolphinsettingsdialog.h
1 /*
2 * SPDX-FileCopyrightText: 2006 Peter Penz <peter.penz@gmx.at>
3 *
4 * SPDX-License-Identifier: GPL-2.0-or-later
5 */
6
7 #ifndef DOLPHINSETTINGSDIALOG_H
8 #define DOLPHINSETTINGSDIALOG_H
9
10 #include <KPageDialog>
11 #include <KActionCollection>
12
13 class QUrl;
14 class SettingsPageBase;
15
16 /**
17 * @brief Settings dialog for Dolphin.
18 *
19 * Contains the pages for Startup, View Modes, Navigation, Services, General, and Trash.
20 */
21 class DolphinSettingsDialog : public KPageDialog
22 {
23 Q_OBJECT
24
25 public:
26 explicit DolphinSettingsDialog(const QUrl& url, QWidget* parent = nullptr, KActionCollection* actions = {});
27 ~DolphinSettingsDialog() override;
28
29 Q_SIGNALS:
30 void settingsChanged();
31
32 private Q_SLOTS:
33 /** Enables the Apply button. */
34 void enableApply();
35 void applySettings();
36 void restoreDefaults();
37
38 protected:
39 void closeEvent(QCloseEvent* event) override;
40
41 private:
42 static SettingsPageBase *createTrashSettingsPage(QWidget *parent);
43
44 QList<SettingsPageBase*> m_pages;
45 bool m_unsavedChanges;
46 };
47
48 #endif