diff --git a/src/bindings/cxx/eo_cxx/eo_cxx_interop.hh b/src/bindings/cxx/eo_cxx/eo_cxx_interop.hh index 72c435e4d7..662e5a7d55 100644 --- a/src/bindings/cxx/eo_cxx/eo_cxx_interop.hh +++ b/src/bindings/cxx/eo_cxx/eo_cxx_interop.hh @@ -846,8 +846,9 @@ inline void do_eo_add(Eo*& object, P const& parent , Efl_Class const* klass , typename std::enable_if< eo::is_eolian_object
::value>::type* = 0)
{
- object = ::_efl_add_internal_start(__FILE__, __LINE__, klass, parent._eo_ptr(), EINA_TRUE, EINA_FALSE);
- object = ::_efl_add_end(object, EINA_TRUE, EINA_FALSE);
+ bool is_ref = (parent._eo_ptr() != nullptr);
+ object = ::_efl_add_internal_start(__FILE__, __LINE__, klass, parent._eo_ptr(), is_ref, EINA_FALSE);
+ object = ::_efl_add_end(object, is_ref, EINA_FALSE);
}
template ::value>::type* = 0)
{
- object = ::_efl_add_internal_start(__FILE__, __LINE__, klass, parent._eo_ptr(), EINA_TRUE, EINA_FALSE);
+ bool is_ref = (parent._eo_ptr() != nullptr);
+ object = ::_efl_add_internal_start(__FILE__, __LINE__, klass, parent._eo_ptr(), is_ref, EINA_FALSE);
::efl::eolian::call_lambda(std::forward