2022-02-13 04:23:57 +00:00
|
|
|
/*
|
|
|
|
|
* SPDX-FileCopyrightText: 2022 Devin Lin <devin@kde.org>
|
|
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include <KConfigGroup>
|
|
|
|
|
#include <KConfigWatcher>
|
|
|
|
|
#include <KSharedConfig>
|
|
|
|
|
#include <QObject>
|
|
|
|
|
|
2022-03-21 14:00:03 +00:00
|
|
|
class MobileShellSettings : public QObject
|
2022-02-13 04:23:57 +00:00
|
|
|
{
|
|
|
|
|
Q_OBJECT
|
2022-03-17 03:20:36 +00:00
|
|
|
Q_PROPERTY(bool navigationPanelEnabled READ navigationPanelEnabled WRITE setNavigationPanelEnabled NOTIFY navigationPanelEnabledChanged)
|
2022-02-13 04:23:57 +00:00
|
|
|
|
|
|
|
|
public:
|
|
|
|
|
static MobileShellSettings *self();
|
|
|
|
|
|
|
|
|
|
MobileShellSettings(QObject *parent = nullptr);
|
|
|
|
|
|
|
|
|
|
bool navigationPanelEnabled() const;
|
2022-03-17 03:20:36 +00:00
|
|
|
void setNavigationPanelEnabled(bool navigationPanelEnabled);
|
|
|
|
|
|
|
|
|
|
QList<QString> enabledQuickSettings() const;
|
|
|
|
|
void setEnabledQuickSettings(QList<QString> &list);
|
|
|
|
|
|
|
|
|
|
QList<QString> disabledQuickSettings() const;
|
|
|
|
|
void setDisabledQuickSettings(QList<QString> &list);
|
2022-02-13 04:23:57 +00:00
|
|
|
|
|
|
|
|
Q_SIGNALS:
|
|
|
|
|
void navigationPanelEnabledChanged();
|
2022-03-17 03:20:36 +00:00
|
|
|
void enabledQuickSettingsChanged();
|
|
|
|
|
void disabledQuickSettingsChanged();
|
2022-02-13 04:23:57 +00:00
|
|
|
|
|
|
|
|
private:
|
|
|
|
|
KConfigWatcher::Ptr m_configWatcher;
|
|
|
|
|
KSharedConfig::Ptr m_config;
|
|
|
|
|
};
|