Evas.SmartObject: Fix smart callbacks with NULL event_info
If the event has a conversion func assigned but event_info is NULL we should pass None instead of dropping the parameter. This behavior is now the same as before the callback rework.
This commit is contained in:
parent
8a0dccbf22
commit
fcc93216f9
|
@ -420,11 +420,13 @@ cdef void _smart_callback(void *data, Evas_Object *o, void *event_info) with gil
|
|||
if event_info == NULL:
|
||||
try:
|
||||
tmp_args = [spec.obj]
|
||||
if spec.event_conv != NULL:
|
||||
tmp_args.append(None)
|
||||
tmp_args.extend(spec.args)
|
||||
PyObject_Call(spec.func, tuple(tmp_args), spec.kargs)
|
||||
except Exception:
|
||||
traceback.print_exc()
|
||||
elif spec.event_conv == NULL:
|
||||
elif event_info != NULL and spec.event_conv == NULL:
|
||||
EINA_LOG_DOM_WARN(
|
||||
PY_EFL_EVAS_LOG_DOMAIN,
|
||||
'event_info for event "%s" is not NULL and there is no event_conv!',
|
||||
|
|
Loading…
Reference in New Issue