| 68 | } |
| 69 | |
| 70 | void UnitManager::trigger_destroy_callbacks(UnitId unit) |
| 71 | { |
| 72 | ListNode *cur; |
| 73 | list_for_each(cur, &_callbacks.node) |
| 74 | { |
| 75 | UnitDestroyCallback *udc = (UnitDestroyCallback *)container_of(cur, UnitDestroyCallback, node); |
| 76 | udc->destroy(unit, udc->user_data); |
| 77 | } |
| 78 | } |
| 79 | |
| 80 | } // namespace crown |