File indexing completed on 2024-04-28 05:26:47

0001 /*
0002  *   SPDX-FileCopyrightText: 2020 Aleix Pol Gonzalez <aleixpol@kde.org>
0003  *
0004  *   SPDX-License-Identifier: GPL-2.0-only OR GPL-3.0-only OR LicenseRef-KDE-Accepted-GPL
0005  */
0006 
0007 #pragma once
0008 
0009 #include <optional>
0010 
0011 #include <QObject>
0012 
0013 class DiscoverNotifier;
0014 
0015 class UnattendedUpdates : public QObject
0016 {
0017     Q_OBJECT
0018 public:
0019     UnattendedUpdates(DiscoverNotifier *parent);
0020     ~UnattendedUpdates() override;
0021 
0022 private:
0023     void checkNewState();
0024     void triggerUpdate(int timeoutId);
0025 
0026     std::optional<int> m_idleTimeoutId;
0027 };