9
static Picture *picture;
10
static MCursor *cursor;
15
UI_load_picture("bucket", 1, &picture);
16
UI_load_cursor("bucket", CURSOR_OWN_MASK, &cursor);
20
Bucket_clicked(int x, int y) {
21
return (x > 0 && x < UI_picture_width(picture) &&
22
y > 0 && y < UI_picture_height(picture));
28
UI_draw(picture, 0, 0);
32
Bucket_grab(int x, int y) {
36
UI_set_cursor(cursor);
41
Bucket_release(int x, int y) {
43
for (i = 0; i < Network_num_cables(); i++) {
44
Cable *cable = Network_get_cable(i);
45
if (Cable_onspark(cable, x, y))