From 2a90425400b137fd623847f7cbfd2848a3303a89 Mon Sep 17 00:00:00 2001 From: ashmew2 Date: Wed, 16 Mar 2016 11:39:28 +0000 Subject: [PATCH] Add SF 25 and SF 40 to newlib sources git-svn-id: svn://kolibrios.org@6346 a494cfbc-eb01-0410-851d-a64ba20cac60 --- .../sources/newlib/libc/include/kos32sys.h | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/contrib/sdk/sources/newlib/libc/include/kos32sys.h b/contrib/sdk/sources/newlib/libc/include/kos32sys.h index 24eff7bc88..820d11ffd9 100644 --- a/contrib/sdk/sources/newlib/libc/include/kos32sys.h +++ b/contrib/sdk/sources/newlib/libc/include/kos32sys.h @@ -65,6 +65,18 @@ void end_draw(void) "int $0x40" ::"a"(12),"b"(2)); }; +static inline void +put_image(uint16_t x_coord, uint16_t y_coord, + uint16_t size_x, uint16_t size_y, void *img) +{ + __asm__ __volatile__("int $0x40" + ::"a"(25), + "b"(img), + "c"(size_x<<16 | size_y), + "d"(x_coord<<16 | y_coord)); +}; + + static inline void sys_create_window(int x, int y, int w, int h, const char *name, color_t workcolor, uint32_t style) @@ -219,6 +231,17 @@ static inline uint32_t set_cursor(uint32_t cursor) return old; }; +static inline uint32_t set_wanted_events_mask(uint32_t event_mask) +{ + uint32_t old_event_mask; + __asm__ __volatile__( + "int $0x40" + :"=a"(old_event_mask) + :"a"(40)); + + return old_event_mask; +}; + static inline int destroy_cursor(uint32_t cursor) { int ret;