ui: Fix build break due to eo api changes (input events)
This commit is contained in:
parent
05a29c965a
commit
19657b6d25
22
src/bin/ui.c
22
src/bin/ui.c
|
@ -258,8 +258,8 @@ _ui_select(void)
|
|||
static void
|
||||
_ui_key(void *data EINA_UNUSED, const Eo_Event *event)
|
||||
{
|
||||
Efl_Event_Key *ev = event->info;
|
||||
const char *keyname = efl_event_key_name_get(ev);
|
||||
Efl_Input_Key *ev = event->info;
|
||||
const char *keyname = efl_input_key_name_get(ev);
|
||||
|
||||
if (!keyname) return;
|
||||
|
||||
|
@ -300,12 +300,12 @@ static int down_menu_sel = 0;
|
|||
static void
|
||||
_ui_mouse_down(void *data EINA_UNUSED, const Eo_Event *event)
|
||||
{
|
||||
Efl_Event_Pointer *ev = event->info;
|
||||
Efl_Input_Pointer *ev = event->info;
|
||||
|
||||
if (efl_event_pointer_button_get(ev) != 1) return;
|
||||
if (efl_input_pointer_button_get(ev) != 1) return;
|
||||
if (menu_active)
|
||||
{
|
||||
efl_event_pointer_position_get(ev, &down_x, &down_y);
|
||||
efl_input_pointer_position_get(ev, &down_x, &down_y);
|
||||
down_menu_sel = menu_sel;
|
||||
}
|
||||
}
|
||||
|
@ -313,14 +313,14 @@ _ui_mouse_down(void *data EINA_UNUSED, const Eo_Event *event)
|
|||
static void
|
||||
_ui_mouse_up(void *data EINA_UNUSED, const Eo_Event *event)
|
||||
{
|
||||
Efl_Event_Pointer *ev = event->info;
|
||||
Efl_Input_Pointer *ev = event->info;
|
||||
|
||||
if (efl_event_pointer_button_get(ev) != 1) return;
|
||||
if (efl_input_pointer_button_get(ev) != 1) return;
|
||||
if (menu_active)
|
||||
{
|
||||
Evas_Coord dx, dy, x, y;
|
||||
|
||||
efl_event_pointer_position_get(ev, &x, &y);
|
||||
efl_input_pointer_position_get(ev, &x, &y);
|
||||
dx = x - down_x;
|
||||
dy = y - down_y;
|
||||
if ((((dx * dx) + (dy * dy)) < (20 * 20)) &&
|
||||
|
@ -337,14 +337,14 @@ _ui_mouse_up(void *data EINA_UNUSED, const Eo_Event *event)
|
|||
static void
|
||||
_ui_mouse_move(void *data EINA_UNUSED, const Eo_Event *event)
|
||||
{
|
||||
Efl_Event_Pointer *ev = event->info;
|
||||
Efl_Input_Pointer *ev = event->info;
|
||||
|
||||
if (efl_event_pointer_button_get(ev) != 1) return;
|
||||
if (efl_input_pointer_button_get(ev) != 1) return;
|
||||
if (menu_active)
|
||||
{
|
||||
Evas_Coord x;
|
||||
|
||||
efl_event_pointer_position_get(ev, &x, NULL);
|
||||
efl_input_pointer_position_get(ev, &x, NULL);
|
||||
menu_sel = down_menu_sel + ((x - down_x) / 25);
|
||||
/* scroll */
|
||||
if (menu_sel < 0) menu_sel = 0;
|
||||
|
|
Loading…
Reference in New Issue