75,7 → 75,8 |
static int mouse_z = 0; |
static unsigned long mouse_buttons = 0; |
|
static MOUSE_HANDLER mouse_handler = NULL; |
MOUSE_HANDLER user_mouse_handler = NULL; |
MOUSE_HANDLER show_mouse_handler = NULL; |
|
#ifdef MOUSE_TASK |
/* mouse task PID */ |
143,7 → 144,10 |
dx, dy, dz, (int)dbuttons, mouse_x, mouse_y, mouse_z, (int)mouse_buttons); |
#endif |
/* mouse handler */ |
if (mouse_handler!=NULL) mouse_handler(&ev); |
if (show_mouse_handler != NULL) |
show_mouse_handler(&ev); |
else if (user_mouse_handler != NULL) |
user_mouse_handler(&ev); |
} |
} |
#ifdef MOUSE_TASK |
216,7 → 220,7 |
|
void mouse_hook(MOUSE_HANDLER h) |
{ |
mouse_handler = h; |
user_mouse_handler = h; |
} |
|
int mouse_getthreshold(void) |