}
template <typename F>
-Eina_Bool free_callback_calback(void* data, Eo* obj EINA_UNUSED
- , Eo_Event_Description const* e EINA_UNUSED
- , void* event_info EINA_UNUSED)
+Eina_Bool free_callback_callback(void* data, ::Eo_Event2 const*)
{
- delete (F*) data;
+ delete static_cast<F*>(data);
return EO_CALLBACK_CONTINUE;
}
template <typename T, typename F>
Eina_Bool
-event_callback(void *data, Eo *obj, Eo_Event_Description const* desc, void *info)
+event_callback(void *data, ::Eo_Event2 const* event)
{
- T wrapper(::eo_ref(obj));
+ T wrapper(::eo_ref(event->obj));
F *f = static_cast<F*>(data);
- return _detail::really_call_event(wrapper, *f, *desc, info
- , std::is_void<decltype((*f)(wrapper, *desc, info))>());
+ return _detail::really_call_event(wrapper, *f, *event->desc, event->event_info
+ , std::is_void<decltype((*f)(wrapper, *event->desc, event->event_info))>());
}
}
d.out << tab(3)
<< "eo_do(_eoptr," << endl
<< tab(4) << "eo_event_callback_add(EO_BASE_EVENT_DEL, "
- << "&::efl::eolian::free_callback_calback<"
+ << "&::efl::eolian::free_callback_callback<"
<< parameter_no_ref_type(d.type, d.name)
<< ">, " << callback_tmp(d.name) << "));" << endl;
})
operator<<(std::ostream& out, callback_parameter_free_ev_add const& x)
{
out << "eo_do(" << x._eo_raw_expr
- << ", eo_event_callback_add(EO_BASE_EVENT_DEL, &::efl::eolian::free_callback_calback<"
+ << ", eo_event_callback_add(EO_BASE_EVENT_DEL, &::efl::eolian::free_callback_callback<"
<< parameter_no_ref_type(x._type, x._name) << ">, "
<< callback_tmp(x._name) << "));";
return out;
#define MY_CLASS CALLBACK_CLASS
-static Eina_Bool _callback_callback_added(void* data EINA_UNUSED, Eo* obj EINA_UNUSED
- , Eo_Event_Description const* e EINA_UNUSED
- , void* event_info EINA_UNUSED)
+static Eina_Bool _callback_callback_added(void* data EINA_UNUSED, Eo_Event2 const* event)
{
- Callback_Data* pd = event_info;
+ Callback_Data* pd = event->event_info;
++pd->callbacks;
eo_event_callback_call(CALLBACK_EVENT_CALL_ON_ADD, &pd->callbacks);
return EINA_TRUE;