diff options
-rw-r--r-- | int33.h | 19 | ||||
-rw-r--r-- | mousetsr.c | 4 |
2 files changed, 21 insertions, 2 deletions
@@ -265,6 +265,13 @@ static void int33_set_mouse_speed(int16_t x, int16_t y); __parm [cx] [dx] \ __modify [ax] +static void int33_set_speed_double_threshold(uint16_t th); +#pragma aux int33_set_speed_double_threshold = \ + "mov ax, 0x13" \ + "int 0x33" \ + __parm [dx] \ + __modify [ax] + static uint16_t int33_get_mouse_status_size(void); #pragma aux int33_get_mouse_status_size = \ "mov bx, 0" \ @@ -294,6 +301,18 @@ static void int33_set_sensitivity(uint16_t sens_x, uint16_t sens_y, uint16_t dou __parm [bx] [cx] [dx] \ __modify [ax] +static void int33_get_sensitivity(uint16_t *sens_x, uint16_t *sens_y, uint16_t *double_speed_threshold); +#pragma aux int33_get_sensitivity = \ + "push dx" \ + "mov ax, 0x1B" \ + "int 0x33" \ + "mov [si], bx" \ + "mov [di], cx" \ + "pop bx" \ + "mov [bx], dx" \ + __parm [si] [di] [dx] \ + __modify [ax] + static uint16_t int33_get_driver_version(void); #pragma aux int33_get_driver_version = \ "mov bx, 0" \ @@ -1126,8 +1126,8 @@ static void reset_mouse_settings() static void reset_mouse_state() { int i; - data.pos.x = data.min.x; - data.pos.y = data.min.y; + data.pos.x = data.min.x + (data.max.x - data.min.x) / 2; + data.pos.y = data.min.y + (data.max.y - data.min.y) / 2; data.pos_frac.x = 0; data.pos_frac.y = 0; data.delta.x = 0; |