Mir
input_device.h
Go to the documentation of this file.
1/*
2 * Copyright (C) Canonical, Ltd.
3 *
4 * This program is free software: you can redistribute it and/or modify it under
5 * the terms of the GNU Lesser General Public License version 3, as published by
6 * the Free Software Foundation.
7 *
8 * This program is distributed in the hope that it will be useful, but WITHOUT
9 * ANY WARRANTY; without even the implied warranties of MERCHANTABILITY,
10 * SATISFACTORY QUALITY, or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 * Lesser General Public License for more details.
12 *
13 * You should have received a copy of the GNU Lesser General Public License
14 * along with this program. If not, see <http://www.gnu.org/licenses/>.
15 */
16#ifndef MIROIL_INPUT_DEVICE_H
17#define MIROIL_INPUT_DEVICE_H
18#include <mir_toolkit/mir_input_device_types.h>
19#include <memory>
20#include <string>
21
22namespace mir { namespace input { class Device; } }
23
24namespace miroil
25{
27{
28public:
29 InputDevice(std::shared_ptr<mir::input::Device> const& device);
34
35 auto operator=(InputDevice const& src) -> InputDevice&;
37
38 bool operator==(InputDevice const& other);
39
40 void apply_keymap(std::string const& layout, std::string const& variant);
42 auto get_device_name() -> std::string;
43 auto is_keyboard() -> bool;
44 auto is_alpha_numeric() -> bool;
45
46private:
47 std::shared_ptr<mir::input::Device> device;
48};
49
50}
51
52#endif //MIROIL_INPUT_DEVICE_H
Definition: input_device.h:27
auto operator=(InputDevice const &src) -> InputDevice &
void apply_keymap(std::string const &layout, std::string const &variant)
auto is_alpha_numeric() -> bool
InputDevice(InputDevice const &src)
InputDevice(InputDevice &&src)
auto get_device_id() -> MirInputDeviceId
bool operator==(InputDevice const &other)
InputDevice(std::shared_ptr< mir::input::Device > const &device)
auto is_keyboard() -> bool
auto get_device_name() -> std::string
auto operator=(InputDevice &&src) -> InputDevice &
int64_t MirInputDeviceId
Definition: mir_input_device_types.h:27
Definition: input_device.h:22
Definition: runner.h:27
Definition: compositor.h:21

Copyright © 2012-2023 Canonical Ltd.
Generated on Tue 2 May 10:01:24 UTC 2023
This documentation is licensed under the GPL version 2 or 3.