summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Hacohen <tom@stosb.com>2013-09-27 10:50:06 +0100
committerTom Hacohen <tom@stosb.com>2013-09-27 10:50:06 +0100
commit3df115cc633998440bfa175ac85dab4299e2e883 (patch)
tree283356072561f19c84eeb7f7706a9cfa0bf6850d
parent948a75f89fc31f587135c953ef5a3aa9d25b1cd4 (diff)
downloadefl-3df115cc633998440bfa175ac85dab4299e2e883.tar.gz
Eo: Class_Id and Object_Id are now the same type.
-rw-r--r--src/lib/eo/eo.c10
-rw-r--r--src/lib/eo/eo_private.h14
2 files changed, 9 insertions, 15 deletions
diff --git a/src/lib/eo/eo.c b/src/lib/eo/eo.c
index 64d8b3cbdf..14c4fdae7f 100644
--- a/src/lib/eo/eo.c
+++ b/src/lib/eo/eo.c
@@ -17,7 +17,7 @@ EAPI Eina_Lock _eo_class_creation_lock;
int _eo_log_dom = -1;
static _Eo_Class **_eo_classes;
-static Eo_Class_Id _eo_classes_last_id;
+static Eo_Id _eo_classes_last_id;
static Eina_Bool _eo_init_count = 0;
static Eo_Op _eo_ops_last_id = 0;
@@ -151,7 +151,7 @@ static inline _Eo_Class *
_eo_class_pointer_get(const Eo *klass_id)
{
#ifdef HAVE_EO_ID
- return ID_CLASS_GET((Eo_Class_Id)klass_id);
+ return ID_CLASS_GET((Eo_Id)klass_id);
#else
return (_Eo_Class *) EO_FROM_HANDLE(klass_id);
#endif
@@ -832,11 +832,11 @@ eo_class_new(const Eo_Class_Description *desc, const Eo *parent_id, ...)
DBG("Started building extensions list for class '%s'", desc->name);
extn_list = NULL;
const _Eo_Class *extn = NULL;
- const Eo_Class_Id *extn_id = NULL;
+ const Eo_Id *extn_id = NULL;
va_start(p_list, parent_id);
- extn_id = va_arg(p_list, Eo_Class_Id *);
+ extn_id = va_arg(p_list, Eo_Id *);
while (extn_id)
{
extn = _eo_class_pointer_get((Eo *)extn_id);
@@ -850,7 +850,7 @@ eo_class_new(const Eo_Class_Description *desc, const Eo *parent_id, ...)
break;
}
- extn_id = va_arg(p_list, Eo_Class_Id *);
+ extn_id = va_arg(p_list, Eo_Id *);
}
va_end(p_list);
diff --git a/src/lib/eo/eo_private.h b/src/lib/eo/eo_private.h
index 1d547564c2..ca364dda24 100644
--- a/src/lib/eo/eo_private.h
+++ b/src/lib/eo/eo_private.h
@@ -85,6 +85,8 @@ struct _Eo_Object {
#ifndef HAVE_EO_ID
EINA_MAGIC
#endif
+ Eo_Id obj_id;
+
Eo *parent;
Eina_List *children;
const _Eo_Class *klass;
@@ -95,8 +97,6 @@ struct _Eo_Object {
Eina_List *composite_objects;
- Eo_Id obj_id;
-
int refcount;
int datarefcount;
@@ -108,13 +108,6 @@ struct _Eo_Object {
Eina_Bool manual_free:1;
};
-/**
- * @typedef Eo_Class_Id
- * An Id of a class.
- * @ingroup Eo_Class
- */
-typedef uintptr_t Eo_Class_Id;
-
typedef struct _Dich_Chain1 Dich_Chain1;
typedef struct
@@ -139,7 +132,8 @@ struct _Eo_Class
#ifndef HAVE_EO_ID
EINA_MAGIC
#endif
- Eo_Class_Id class_id;
+ Eo_Id class_id;
+
const _Eo_Class *parent;
const Eo_Class_Description *desc;
Dich_Chain1 *chain; /**< The size is chain size */