File indexing completed on 2024-11-10 04:56:32

0001 /*
0002     SPDX-FileCopyrightText: 2021 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
0003 
0004     SPDX-License-Identifier: GPL-2.0-or-later
0005 */
0006 
0007 #pragma once
0008 
0009 #include "core/inputbackend.h"
0010 
0011 #include <QThread>
0012 
0013 namespace KWin
0014 {
0015 
0016 class Session;
0017 
0018 namespace LibInput
0019 {
0020 class Connection;
0021 }
0022 
0023 class KWIN_EXPORT LibinputBackend : public InputBackend
0024 {
0025     Q_OBJECT
0026 
0027 public:
0028     explicit LibinputBackend(Session *session, QObject *parent = nullptr);
0029     ~LibinputBackend() override;
0030 
0031     void initialize() override;
0032     void updateScreens() override;
0033 
0034 private:
0035     QThread m_thread;
0036     std::unique_ptr<LibInput::Connection> m_connection;
0037 };
0038 
0039 } // namespace KWin