23 |
|
#define M_MOTION 0x1 |
24 |
|
|
25 |
|
int crad; |
26 |
– |
#define right_button (mouse_event & M_RIGHTBUTT) |
27 |
– |
#define left_button (mouse_event & M_LEFTBUTT) |
26 |
|
int mouse_event = 0; |
27 |
|
int mouse_xpos = -1; |
28 |
|
int mouse_ypos = -1; |
29 |
|
|
30 |
+ |
#define hide_cursor move_cursor(-1,-1) |
31 |
+ |
#define show_cursor move_cursor(mouse_xpos,mouse_ypos) |
32 |
|
|
33 |
|
#define CTRL(c) ((c)-'@') |
34 |
|
|
255 |
|
break; |
256 |
|
} |
257 |
|
postext(box.xmin+box.xsiz/2, box.ymin+box.ysiz/2); |
258 |
+ |
hide_cursor(); |
259 |
|
_outtext(buf); |
260 |
+ |
show_cursor(); |
261 |
|
return(1); |
262 |
|
default: |
263 |
|
return(-1); |
279 |
|
if (!(mouse_event & M_LDOWN)) |
280 |
|
return; |
281 |
|
l_x = a_x = mouse_xpos; l_y = a_y = mouse_ypos; |
282 |
< |
move_cursor(-1, -1); /* hide cursor */ |
282 |
> |
hide_cursor(); |
283 |
|
revbox(a_x, a_y, l_x, l_y); /* show box */ |
284 |
|
do { |
285 |
|
mouse_event = 0; |
291 |
|
} |
292 |
|
} while (!(mouse_event & M_LUP)); |
293 |
|
revbox(a_x, a_y, l_x, l_y); /* hide box */ |
294 |
< |
move_cursor(mouse_xpos, mouse_ypos); /* show cursor */ |
294 |
> |
show_cursor(); |
295 |
|
box.xmin = mouse_xpos; |
296 |
|
box.ymin = mouse_ypos; |
297 |
|
if (box.xmin > a_x) { |