Eo base: rename event_freeze_get to event_freeze_count_get.

This is needed because of a possible clash between the method event_freeze
and the property event_freeze with bindings.
This commit is contained in:
Tom Hacohen 2014-06-02 12:49:46 +01:00
parent 328d28a7f4
commit d9263e6571
10 changed files with 33 additions and 33 deletions

View File

@ -119,7 +119,7 @@ inline int
event_freeze_get(const Eo *obj)
{
int count = -1;
eo_do(obj, count = eo_event_freeze_get());
eo_do(obj, count = eo_event_freeze_count_get());
return count;
}

View File

@ -431,12 +431,12 @@ ecore_timer_freeze_get(Ecore_Timer *timer)
{
int r = 0;
eo_do(timer, r = eo_event_freeze_get());
eo_do(timer, r = eo_event_freeze_count_get());
return !!r;
}
EOLIAN static int
_ecore_timer_eo_base_event_freeze_get(Eo *obj EINA_UNUSED, Ecore_Timer_Data *timer)
_ecore_timer_eo_base_event_freeze_count_get(Eo *obj EINA_UNUSED, Ecore_Timer_Data *timer)
{
EINA_MAIN_LOOP_CHECK_RETURN_VAL(0);

View File

@ -61,7 +61,7 @@ class Ecore_Timer (Eo_Base)
Eo_Base::constructor;
Eo_Base::destructor;
Eo_Base::event_freeze;
Eo_Base::event_freeze::get;
Eo_Base::event_freeze_count::get;
Eo_Base::event_thaw;
}
}

View File

@ -1245,7 +1245,7 @@ EAPI void eo_event_thaw(void);
* @see #eo_event_freeze
* @see #eo_event_thaw
*/
EAPI int eo_event_freeze_get(void);
EAPI int eo_event_freeze_count_get(void);
/**
* @brief freeze events of object.
@ -1274,11 +1274,11 @@ EAPI void eo_event_global_thaw(void);
*
* Return event freeze count.
*
* @see #eo_event_freeze_get
* @see #eo_event_freeze_count_get
* @see #eo_event_global_freeze
* @see #eo_event_global_thaw
*/
EAPI int eo_event_global_freeze_get(void);
EAPI int eo_event_global_freeze_count_get(void);
/**
* @def eo_event_callback_add(obj, desc, cb, data)

View File

@ -21,7 +21,7 @@ Parents keep references to their children so in order to delete objects that hav
Eo* parent; /*@ the new parent */
}
}
event_global_freeze {
event_global_freeze_count {
get {
/*@ return freeze events of object.
Return event freeze count. */
@ -30,7 +30,7 @@ Return event freeze count. */
int fcount; /*@ The event freeze count of the object */
}
}
event_freeze {
event_freeze_count {
get {
/*@ return freeze events of object.
Return event freeze count. */

View File

@ -842,7 +842,7 @@ _ev_freeze_get(Eo *obj EINA_UNUSED, void *class_data)
return pd->event_freeze_count;
}
EAPI EO_FUNC_BODY(eo_event_freeze_get, int, 0);
EAPI EO_FUNC_BODY(eo_event_freeze_count_get, int, 0);
static void
_ev_global_freeze(const Eo_Class *klass EINA_UNUSED, void *class_data EINA_UNUSED)
@ -870,7 +870,7 @@ _ev_global_freeze_get(const Eo_Class *klass EINA_UNUSED, void *class_data EINA_U
{
return event_freeze_count;
}
EAPI EO_FUNC_BODY(eo_event_global_freeze_get, int, 0);
EAPI EO_FUNC_BODY(eo_event_global_freeze_count_get, int, 0);
/* Eo_Dbg */
EAPI void
@ -1048,10 +1048,10 @@ static Eo_Op_Description op_descs [] = {
EO_OP_FUNC(eo_event_callback_forwarder_del, _ev_cb_forwarder_del, "Delete an event forwarder."),
EO_OP_FUNC(eo_event_freeze, _ev_freeze, "Freezes events."),
EO_OP_FUNC(eo_event_thaw, _ev_thaw, "Thaws events."),
EO_OP_FUNC(eo_event_freeze_get, _ev_freeze_get, "Get event freeze counter."),
EO_OP_FUNC(eo_event_freeze_count_get, _ev_freeze_get, "Get event freeze counter."),
EO_OP_CLASS_FUNC(eo_event_global_freeze, _ev_global_freeze, "Freezes events globally."),
EO_OP_CLASS_FUNC(eo_event_global_thaw, _ev_global_thaw, "Thaws events globally."),
EO_OP_CLASS_FUNC(eo_event_global_freeze_get, _ev_global_freeze_get, "Get global event freeze counter."),
EO_OP_CLASS_FUNC(eo_event_global_freeze_count_get, _ev_global_freeze_get, "Get global event freeze counter."),
EO_OP_FUNC(eo_dbg_info_get, _dbg_info_get, "Get debug info list for obj."),
EO_OP_SENTINEL
};

View File

@ -960,7 +960,7 @@ _canvas_event_thaw(Eo *eo_e, void *_pd, va_list *list EINA_UNUSED)
eo_do_super(eo_e, EVAS_CLASS,
eo_event_thaw());
eo_do_super(eo_e, EVAS_CLASS,
fcount = eo_event_freeze_get());
fcount = eo_event_freeze_count_get());
if (0 == fcount)
{
Evas_Public_Data *e = _pd;
@ -989,7 +989,7 @@ evas_event_freeze_get(const Evas *eo_e)
return 0;
MAGIC_CHECK_END();
int ret = 0;
eo_do((Eo *)eo_e, ret = eo_event_freeze_get());
eo_do((Eo *)eo_e, ret = eo_event_freeze_count_get());
return ret;
}

View File

@ -1608,7 +1608,7 @@ _cb_always_call(Evas *eo_e, Evas_Callback_Type type, void *event_info)
{
int freeze_num = 0, i;
eo_do(eo_e, freeze_num = eo_event_freeze_get());
eo_do(eo_e, freeze_num = eo_event_freeze_count_get());
for (i = 0; i < freeze_num; i++) eo_do(eo_e, eo_event_thaw());
evas_event_callback_call(eo_e, type, event_info);
for (i = 0; i < freeze_num; i++) eo_do(eo_e, eo_event_freeze());

View File

@ -121,7 +121,7 @@ _evas_render2_always_call(Eo *eo_e, Evas_Callback_Type type, void *event_info)
{
int freeze_num = 0, i;
eo_do(eo_e, freeze_num = eo_event_freeze_get());
eo_do(eo_e, freeze_num = eo_event_freeze_count_get());
for (i = 0; i < freeze_num; i++) eo_do(eo_e, eo_event_thaw());
evas_event_callback_call(eo_e, type, event_info);
for (i = 0; i < freeze_num; i++) eo_do(eo_e, eo_event_freeze());

View File

@ -79,15 +79,15 @@ main(int argc, char *argv[])
eo_do(obj, eo_event_callback_priority_add(EV_A_CHANGED, EO_CALLBACK_PRIORITY_BEFORE, _a_changed_cb, (void *) 1));
fail_if(pd->cb_count != 1);
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 0);
eo_do(obj, eo_event_freeze());
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 1);
eo_do(obj, eo_event_freeze());
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 2);
eo_do(obj, eo_event_callback_priority_add(EV_A_CHANGED, EO_CALLBACK_PRIORITY_BEFORE, _a_changed_cb, (void *) 2));
@ -96,11 +96,11 @@ main(int argc, char *argv[])
eo_do(obj, simple_a_set(2));
fail_if(cb_count != 0);
eo_do(obj, eo_event_thaw());
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 1);
eo_do(obj, eo_event_thaw());
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 0);
eo_do(obj, simple_a_set(3));
@ -108,17 +108,17 @@ main(int argc, char *argv[])
cb_count = 0;
eo_do(obj, eo_event_thaw());
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 0);
eo_do(obj, eo_event_freeze());
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 1);
eo_do(obj, simple_a_set(2));
fail_if(cb_count != 0);
eo_do(obj, eo_event_thaw());
eo_do(obj, fcount = eo_event_freeze_get());
eo_do(obj, fcount = eo_event_freeze_count_get());
fail_if(fcount != 0);
eo_do(obj, eo_event_callback_del(EV_A_CHANGED, _a_changed_cb, (void *) 1));
@ -133,15 +133,15 @@ main(int argc, char *argv[])
eo_do(obj, eo_event_callback_priority_add(EV_A_CHANGED, EO_CALLBACK_PRIORITY_BEFORE, _a_changed_cb, (void *) 1));
fail_if(pd->cb_count != 1);
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 0);
eo_do(EO_CLASS, eo_event_global_freeze());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 1);
eo_do(EO_CLASS, eo_event_global_freeze());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 2);
eo_do(obj, eo_event_callback_priority_add(EV_A_CHANGED, EO_CALLBACK_PRIORITY_BEFORE, _a_changed_cb, (void *) 2));
@ -150,11 +150,11 @@ main(int argc, char *argv[])
eo_do(obj, simple_a_set(2));
fail_if(cb_count != 0);
eo_do(EO_CLASS, eo_event_global_thaw());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 1);
eo_do(EO_CLASS, eo_event_global_thaw());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 0);
eo_do(obj, simple_a_set(3));
@ -162,17 +162,17 @@ main(int argc, char *argv[])
cb_count = 0;
eo_do(EO_CLASS, eo_event_global_thaw());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 0);
eo_do(EO_CLASS, eo_event_global_freeze());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 1);
eo_do(obj, simple_a_set(2));
fail_if(cb_count != 0);
eo_do(EO_CLASS, eo_event_global_thaw());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_get());
eo_do(EO_CLASS, fcount = eo_event_global_freeze_count_get());
fail_if(fcount != 0);