From 7177a697128056e09fee99d7db05ee9bab18f325 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Zurcher?= Date: Tue, 22 May 2012 12:25:46 +0200 Subject: eiotas_spin.h: add macros eiotas_spin_require_particle and eiotas_spin_release_particle --- src/include/eiotas_spin.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/include/eiotas_spin.h b/src/include/eiotas_spin.h index 63cff05..e8d7319 100644 --- a/src/include/eiotas_spin.h +++ b/src/include/eiotas_spin.h @@ -20,6 +20,7 @@ #define __EIOTAS_SPIN_H__ #include "eiotas_room.h" +#include "eiotas_iota.h" #include "eiotas_particle.h" #include @@ -43,4 +44,8 @@ EAPI Eiotas_Particle* eiotas_spin_release_particle(Eiotas_Spin *spin, Eiotas_P EAPI void eiotas_spin_send_particle(Eiotas_Spin *spin, Eiotas_Particle *particle, Eina_Bool system); +#define eiotas_require_particle(_iota) eiotas_spin_require_particle((Eiotas_Spin*)((Eiotas_Iota*)(_iota))->spin) + +#define eiotas_release_particle(_iota,_particle) eiotas_spin_release_particle((Eiotas_Spin*)((Eiotas_Iota*)(_iota))->spin,_particle) + #endif // __EIOTAS_SPIN_H__ -- cgit v1.1-2-g2b99