From 6b71accbaf4be52a1e2d3a696675c5e610a4c9b3 Mon Sep 17 00:00:00 2001 From: Marvin Borner Date: Mon, 26 Apr 2021 00:43:59 +0200 Subject: Added VMMouse support and improved PS/2 mouse --- libs/libc/inc/sys.h | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'libs') diff --git a/libs/libc/inc/sys.h b/libs/libc/inc/sys.h index 8c8e217..f65e020 100644 --- a/libs/libc/inc/sys.h +++ b/libs/libc/inc/sys.h @@ -6,6 +6,7 @@ #include #include +#include #define KEYBOARD_MAGIC 0x555555 #define MOUSE_MAGIC 0xaaaaaa @@ -64,11 +65,14 @@ struct event_keyboard { struct event_mouse { u32 magic; - s32 diff_x; - s32 diff_y; - u8 but1; - u8 but2; - u8 but3; + vec2 pos; + u8 rel; // 1 rel, 0 abs + s8 scroll; // Dir: -1 neg, +1 pos + struct { + u8 left : 1; + u8 right : 1; + u8 middle : 1; + } but; }; struct stat { -- cgit v1.2.3