┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/settings/dolphinsettingsdialog.h
blob: f0322c5f0c6fd021c2b93aba323c707ec787284a (plain)
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
45
46
47
48
49
50
/*
 * SPDX-FileCopyrightText: 2006 Peter Penz <[email protected]>
 *
 * SPDX-License-Identifier: GPL-2.0-or-later
 */

#ifndef DOLPHINSETTINGSDIALOG_H
#define DOLPHINSETTINGSDIALOG_H

#include <KActionCollection>
#include <KPageDialog>

class QUrl;
class SettingsPageBase;

/**
 * @brief Settings dialog for Dolphin.
 *
 * Contains the pages for Startup, View Modes, Navigation, Services, General, and Trash.
 */
class DolphinSettingsDialog : public KPageDialog
{
    Q_OBJECT

public:
    explicit DolphinSettingsDialog(const QUrl &url, QWidget *parent = nullptr, KActionCollection *actions = {});
    ~DolphinSettingsDialog() override;

    KPageWidgetItem *trashSettings;

Q_SIGNALS:
    void settingsChanged();

private Q_SLOTS:
    /** Enables the Apply button. */
    void enableApply();
    void applySettings();
    void restoreDefaults();

protected:
    void closeEvent(QCloseEvent *event) override;

private:
    static SettingsPageBase *createTrashSettingsPage(QWidget *parent);

    QList<SettingsPageBase *> m_pages;
    bool m_unsavedChanges;
};

#endif