KWin
Loading...
Searching...
No Matches
src
backends
fakeinput
fakeinputdevice.cpp
Go to the documentation of this file.
1
/*
2
SPDX-FileCopyrightText: 2021 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
3
4
SPDX-License-Identifier: GPL-2.0-or-later
5
*/
6
7
#include "
fakeinputdevice.h
"
8
9
namespace
KWin
10
{
11
static
int
s_lastDeviceId = 0;
12
13
FakeInputDevice::FakeInputDevice
(QObject *parent)
14
:
InputDevice
(parent)
15
, m_name(QStringLiteral(
"Fake Input Device %1"
).arg(++s_lastDeviceId))
16
{
17
}
18
19
bool
FakeInputDevice::isAuthenticated
()
const
20
{
21
return
m_authenticated;
22
}
23
24
void
FakeInputDevice::setAuthenticated
(
bool
authenticated)
25
{
26
m_authenticated = authenticated;
27
}
28
29
QString
FakeInputDevice::sysName
()
const
30
{
31
return
QString();
32
}
33
34
QString
FakeInputDevice::name
()
const
35
{
36
return
m_name;
37
}
38
39
bool
FakeInputDevice::isEnabled
()
const
40
{
41
return
true
;
42
}
43
44
void
FakeInputDevice::setEnabled
(
bool
enabled)
45
{
46
}
47
48
LEDs
FakeInputDevice::leds
()
const
49
{
50
return
LEDs();
51
}
52
53
void
FakeInputDevice::setLeds
(LEDs leds)
54
{
55
}
56
57
bool
FakeInputDevice::isKeyboard
()
const
58
{
59
return
true
;
60
}
61
62
bool
FakeInputDevice::isPointer
()
const
63
{
64
return
true
;
65
}
66
67
bool
FakeInputDevice::isTouchpad
()
const
68
{
69
return
false
;
70
}
71
72
bool
FakeInputDevice::isTouch
()
const
73
{
74
return
true
;
75
}
76
77
bool
FakeInputDevice::isTabletTool
()
const
78
{
79
return
false
;
80
}
81
82
bool
FakeInputDevice::isTabletPad
()
const
83
{
84
return
false
;
85
}
86
87
bool
FakeInputDevice::isTabletModeSwitch
()
const
88
{
89
return
false
;
90
}
91
92
bool
FakeInputDevice::isLidSwitch
()
const
93
{
94
return
false
;
95
}
96
97
}
// namespace KWin
98
99
#include "moc_fakeinputdevice.cpp"
KWin::FakeInputDevice::isPointer
bool isPointer() const override
Definition
fakeinputdevice.cpp:62
KWin::FakeInputDevice::isKeyboard
bool isKeyboard() const override
Definition
fakeinputdevice.cpp:57
KWin::FakeInputDevice::isTouchpad
bool isTouchpad() const override
Definition
fakeinputdevice.cpp:67
KWin::FakeInputDevice::isTouch
bool isTouch() const override
Definition
fakeinputdevice.cpp:72
KWin::FakeInputDevice::sysName
QString sysName() const override
Definition
fakeinputdevice.cpp:29
KWin::FakeInputDevice::isTabletPad
bool isTabletPad() const override
Definition
fakeinputdevice.cpp:82
KWin::FakeInputDevice::isEnabled
bool isEnabled() const override
Definition
fakeinputdevice.cpp:39
KWin::FakeInputDevice::setLeds
void setLeds(LEDs leds) override
Definition
fakeinputdevice.cpp:53
KWin::FakeInputDevice::name
QString name() const override
Definition
fakeinputdevice.cpp:34
KWin::FakeInputDevice::isAuthenticated
bool isAuthenticated() const
Definition
fakeinputdevice.cpp:19
KWin::FakeInputDevice::isTabletTool
bool isTabletTool() const override
Definition
fakeinputdevice.cpp:77
KWin::FakeInputDevice::setAuthenticated
void setAuthenticated(bool authenticated)
Definition
fakeinputdevice.cpp:24
KWin::FakeInputDevice::FakeInputDevice
FakeInputDevice(QObject *parent=nullptr)
Definition
fakeinputdevice.cpp:13
KWin::FakeInputDevice::leds
LEDs leds() const override
Definition
fakeinputdevice.cpp:48
KWin::FakeInputDevice::isTabletModeSwitch
bool isTabletModeSwitch() const override
Definition
fakeinputdevice.cpp:87
KWin::FakeInputDevice::isLidSwitch
bool isLidSwitch() const override
Definition
fakeinputdevice.cpp:92
KWin::FakeInputDevice::setEnabled
void setEnabled(bool enabled) override
Definition
fakeinputdevice.cpp:44
KWin::InputDevice
Definition
inputdevice.h:22
fakeinputdevice.h
KWin
Definition
activation_test.cpp:20
Generated on Sat Feb 17 2024 01:42:09 for KWin by
1.10.0