From afa9806e47e71c94b26636a8de7c8e4db08b470d Mon Sep 17 00:00:00 2001 From: hidnplayr Date: Mon, 11 Aug 2014 23:11:42 +0000 Subject: [PATCH] Fixed __menuet__set_bitfield_for_wanted_events in libc to allow bits 30 and 31 be set. git-svn-id: svn://kolibrios.org@5029 a494cfbc-eb01-0410-851d-a64ba20cac60 --- programs/develop/libraries/menuetlibc/include/menuet/os.h | 8 ++++---- .../libraries/menuetlibc/src/libc/menuetos/event.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/programs/develop/libraries/menuetlibc/include/menuet/os.h b/programs/develop/libraries/menuetlibc/include/menuet/os.h index dd9493bade..726d8d3f94 100644 --- a/programs/develop/libraries/menuetlibc/include/menuet/os.h +++ b/programs/develop/libraries/menuetlibc/include/menuet/os.h @@ -75,7 +75,7 @@ __u32 __menuet__get_date(void); void __menuet__line(__u16 x1,__u16 y1,__u16 x2,__u16 y2,__u32 color); -void __menuet__set_bitfield_for_wanted_events(__u16 ev); +void __menuet__set_bitfield_for_wanted_events(__u32 ev); #define EVENT_REDRAW 0x00000001 #define EVENT_KEY 0x00000002 @@ -83,9 +83,9 @@ void __menuet__set_bitfield_for_wanted_events(__u16 ev); #define EVENT_END_REQUEST 0x00000008 #define EVENT_DESKTOP_BACK_DRAW 0x00000010 #define EVENT_MOUSE_CHANGE 0x00000020 -#define EVENT_IPC 0x00000040 -#define EVENT_GET_IRQS_MASK 0xFFFF0000 -#define EVENT_GET_IRQ(e) (((e)>>16)&0xFFFF) +#define EVENT_IPC 0x00000040 +#define EVENT_MOUSE_CURSOR_MASK 0x40000000 // the window does not receive mouse events if cursor outside window +#define EVENT_MOUSE_WINDOW_MASK 0x80000000 // inactive window does not receive mouse events __u32 __menuet__get_irq_owner(__u32 irq); int __menuet__get_data_read_by_irq(__u32 irq,__u32 * num_bytes_in_buf,__u8 * data); diff --git a/programs/develop/libraries/menuetlibc/src/libc/menuetos/event.c b/programs/develop/libraries/menuetlibc/src/libc/menuetos/event.c index 47c5ee5fb1..f5c8fc5f04 100644 --- a/programs/develop/libraries/menuetlibc/src/libc/menuetos/event.c +++ b/programs/develop/libraries/menuetlibc/src/libc/menuetos/event.c @@ -14,7 +14,7 @@ int __menuet__check_for_event(void) return __ret; } -void __menuet__set_bitfield_for_wanted_events(__u16 ev) +void __menuet__set_bitfield_for_wanted_events(__u32 ev) { __asm__ __volatile__("int $0x40"::"a"(40),"b"(ev)); }