KWin
Loading...
Searching...
No Matches
lidswitchtracker.h
Go to the documentation of this file.
1/*
2 KWin - the KDE window manager
3 This file is part of the KDE project.
4
5 SPDX-FileCopyrightText: 2023 Xaver Hugl <xaver.hugl@gmail.com>
6
7 SPDX-License-Identifier: GPL-2.0-or-later
8*/
9#pragma once
10#include "input_event_spy.h"
11
12#include <QObject>
13
14namespace KWin
15{
16
17class LidSwitchTracker : public QObject, InputEventSpy
18{
19 Q_OBJECT
20public:
21 explicit LidSwitchTracker();
22
23 bool isLidClosed() const;
24
25Q_SIGNALS:
27
28private:
29 void switchEvent(KWin::SwitchEvent *event) override;
30
31 bool m_isLidClosed = false;
32};
33
34}