KGuiAddons

kcolorschemewatcher_win.h
1/*
2 * SPDX-FileCopyrightText: 2020 Piyush Aggarwal <piyushaggarwal002@gmail.com>
3 *
4 * SPDX-License-Identifier: LGPL-2.0-or-later
5 */
6
7#ifndef KCOLORSCHEMEWATCHER_WIN_H
8#define KCOLORSCHEMEWATCHER_WIN_H
9
10#include <QAbstractNativeEventFilter>
11#include <QSettings>
12
13#include "kcolorschemewatcherbackend.h"
14
15class KColorSchemeWatcherWin : public KColorSchemeWatcherBackend, public QAbstractNativeEventFilter
16{
18public:
19 KColorSchemeWatcherWin();
20 KColorSchemeWatcher::ColorPreference systemPreference() const override;
21
22 bool nativeEventFilter(const QByteArray &eventType, void *message, qintptr *) override;
23
24private:
25 QSettings m_settings{QStringLiteral("HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Themes\\Personalize"), QSettings::NativeFormat};
26 bool m_preferDarkMode = false;
27};
28
29#endif
Q_OBJECTQ_OBJECT
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:14:40 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.