eo2: cleaned up EO2_CLASS_DESCRIPTION_OPS and OP_DESC_SIZE (renamed).

This commit is contained in:
Tom Hacohen 2013-07-29 17:50:56 +01:00
parent 56f48ac817
commit 8307ed5aa8
2 changed files with 3 additions and 3 deletions

View File

@ -607,10 +607,10 @@ EAPI Eina_Bool eo_shutdown(void);
#define EO2_VERSION 2
// computes size of Eo2_Op_Description[]
#define OP_DESC_SIZE(desc) (sizeof(desc)/sizeof(Eo2_Op_Description) -1 )
#define EO2_OP_DESC_SIZE(desc) (sizeof(desc)/sizeof(*desc) - 1)
// An helper macro to help populating #Eo_Class_Description.
#define EO2_CLASS_DESCRIPTION_OPS(op_descs, count) { NULL, NULL, op_descs, count }
#define EO2_CLASS_DESCRIPTION_OPS(op_descs) { NULL, NULL, op_descs, EO2_OP_DESC_SIZE(op_descs) }
// sort Eo2_Op_Description[] by eapi_func then attribute OP ids
EAPI void

View File

@ -814,7 +814,7 @@ static const Eo_Class_Description class_desc = {
EO2_VERSION,
"Eo Base",
EO_CLASS_TYPE_REGULAR_NO_INSTANT,
EO2_CLASS_DESCRIPTION_OPS(op_descs, OP_DESC_SIZE(op_descs)),
EO2_CLASS_DESCRIPTION_OPS(op_descs),
event_desc,
sizeof(Private_Data),
_class_constructor,