2020-01-18 05:38:21 -03:00
|
|
|
/*
|
|
|
|
|
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
|
|
|
|
|
*
|
2021-04-22 05:24:48 -03:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-01-18 05:38:21 -03:00
|
|
|
*/
|
|
|
|
|
|
2019-03-05 09:59:44 -03:00
|
|
|
#pragma once
|
|
|
|
|
|
2020-02-03 22:00:50 -03:00
|
|
|
#include <AK/Types.h>
|
|
|
|
|
|
2019-03-05 09:59:44 -03:00
|
|
|
struct MousePacket {
|
2020-02-03 13:29:40 -03:00
|
|
|
int x { 0 };
|
|
|
|
|
int y { 0 };
|
|
|
|
|
int z { 0 };
|
2021-12-13 19:12:01 -03:00
|
|
|
int w { 0 };
|
2020-04-08 11:35:00 -03:00
|
|
|
|
|
|
|
|
enum Button {
|
|
|
|
|
LeftButton = 0x01,
|
|
|
|
|
RightButton = 0x02,
|
|
|
|
|
MiddleButton = 0x04,
|
2021-10-27 13:49:04 -03:00
|
|
|
BackwardButton = 0x08,
|
2020-05-02 17:06:17 -03:00
|
|
|
ForwardButton = 0x10,
|
2020-04-08 11:35:00 -03:00
|
|
|
};
|
|
|
|
|
|
2019-07-03 16:17:35 -03:00
|
|
|
unsigned char buttons { 0 };
|
2020-02-03 13:29:40 -03:00
|
|
|
bool is_relative { true };
|
2019-03-05 09:59:44 -03:00
|
|
|
};
|