forked from enlightenment/enlightenment
fix _e_popup_autoclose_key_down_cb
- uses autoclose_popup->key_data as autoclose_popup->key_cb data key_data is provided at cb registration through e_popup_autoclose(…) - re-enable _mixer_popup_key_down_cb
This commit is contained in:
parent
c66e21aa9a
commit
cf2ef255c4
|
@ -36,13 +36,13 @@ _e_popup_free(E_Popup *pop)
|
||||||
}
|
}
|
||||||
|
|
||||||
static Eina_Bool
|
static Eina_Bool
|
||||||
_e_popup_autoclose_key_down_cb(void *data, int type EINA_UNUSED, void *event)
|
_e_popup_autoclose_key_down_cb(void *data EINA_UNUSED, int type EINA_UNUSED, void *event)
|
||||||
{
|
{
|
||||||
Ecore_Event_Key *ev = event;
|
Ecore_Event_Key *ev = event;
|
||||||
Eina_Bool del = EINA_TRUE;
|
Eina_Bool del = EINA_TRUE;
|
||||||
|
|
||||||
if (autoclose_popup->key_cb)
|
if (autoclose_popup->key_cb)
|
||||||
del = !autoclose_popup->key_cb(data, ev);
|
del = !autoclose_popup->key_cb(autoclose_popup->key_data, ev);
|
||||||
if (del) _e_popup_autoclose_cleanup();
|
if (del) _e_popup_autoclose_cleanup();
|
||||||
return ECORE_CALLBACK_RENEW;
|
return ECORE_CALLBACK_RENEW;
|
||||||
}
|
}
|
||||||
|
|
|
@ -467,7 +467,6 @@ _mixer_popup_key_down_cb(void *data, Ecore_Event_Key *ev)
|
||||||
E_Mixer_Instance *inst = data;
|
E_Mixer_Instance *inst = data;
|
||||||
const char *keysym;
|
const char *keysym;
|
||||||
|
|
||||||
if (!inst) return ECORE_CALLBACK_PASS_ON;
|
|
||||||
keysym = ev->key;
|
keysym = ev->key;
|
||||||
if (strcmp(keysym, "Escape") == 0)
|
if (strcmp(keysym, "Escape") == 0)
|
||||||
_mixer_popup_del(inst);
|
_mixer_popup_del(inst);
|
||||||
|
|
Loading…
Reference in New Issue