Backlight Gadget: Properly set on hold events.

This commit is contained in:
Stephen 'Okra' Houston 2017-05-12 09:57:48 -05:00
parent 20f94cec74
commit ac2c9a220f
1 changed files with 3 additions and 0 deletions

View File

@ -129,6 +129,8 @@ _backlight_cb_mouse_down(void *data, Evas *evas EINA_UNUSED, Evas_Object *obj EI
Instance *inst = data; Instance *inst = data;
Evas_Event_Mouse_Down *ev = event; Evas_Event_Mouse_Down *ev = event;
if (ev->event_flags & EVAS_EVENT_FLAG_ON_HOLD) return;
if (ev->button == 1) if (ev->button == 1)
{ {
if (inst->popup) elm_ctxpopup_dismiss(inst->popup); if (inst->popup) elm_ctxpopup_dismiss(inst->popup);
@ -136,6 +138,7 @@ _backlight_cb_mouse_down(void *data, Evas *evas EINA_UNUSED, Evas_Object *obj EI
} }
else if (ev->button == 3) else if (ev->button == 3)
{ {
ev->event_flags |= EVAS_EVENT_FLAG_ON_HOLD;
e_gadget_configure(inst->o_main); e_gadget_configure(inst->o_main);
} }
} }