Mercurial > MadButterfly
comparison src/mouse.c @ 235:65cabbdd5284
termporary revision
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Thu, 25 Dec 2008 18:40:27 +0800 |
parents | 2637519e2bd7 |
children | 1ca96c158125 |
comparison
equal
deleted
inserted
replaced
234:889cdc5f23c5 | 235:65cabbdd5284 |
---|---|
26 | 26 |
27 if(rdman->last_mouse_over != NULL) { | 27 if(rdman->last_mouse_over != NULL) { |
28 new_evt.event.type = EVT_MOUSE_OUT; | 28 new_evt.event.type = EVT_MOUSE_OUT; |
29 if(IS_MBO_COORD(rdman->last_mouse_over)) { | 29 if(IS_MBO_COORD(rdman->last_mouse_over)) { |
30 coord = (coord_t *)rdman->last_mouse_over; | 30 coord = (coord_t *)rdman->last_mouse_over; |
31 subject_notify(coord->mouse_event, (event_t *)&new_evt); | 31 subject_notify(coord_get_mouse_event(coord), (event_t *)&new_evt); |
32 } else if(IS_MBO_SHAPES(rdman->last_mouse_over)) { | 32 } else if(IS_MBO_SHAPES(rdman->last_mouse_over)) { |
33 shape = (shape_t *)rdman->last_mouse_over; | 33 shape = (shape_t *)rdman->last_mouse_over; |
34 ASSERT(shape->geo != NULL); | 34 ASSERT(shape->geo != NULL); |
35 subject_notify(shape->geo->mouse_event, (event_t *)&new_evt); | 35 subject_notify(sh_get_mouse_event_subject(shape), |
36 (event_t *)&new_evt); | |
36 } | 37 } |
37 } | 38 } |
38 | 39 |
39 new_evt.event.type = EVT_MOUSE_OVER; | 40 new_evt.event.type = EVT_MOUSE_OVER; |
40 subject_notify(evt->cur_tgt, (event_t *)&new_evt); | 41 subject_notify(evt->cur_tgt, (event_t *)&new_evt); |