From: Hermet Park Date: Mon, 23 Dec 2019 11:57:51 +0000 (+0900) Subject: fix broken menu selection. X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;ds=sidebyside;h=0a22c47ebc88d14869c7ff43fef7fd4783d0cc2c;p=platform%2Fupstream%2Fexpedite.git fix broken menu selection. booo. efl_input_pointer_mouse_get() doesn't work. This is a temporary fix for expedite working back. Change-Id: I8edd59dfbbf0f425efe9c8b45f09be2fc50e8567 --- diff --git a/src/bin/ui.c b/src/bin/ui.c index 670bac1..ed9e792 100644 --- a/src/bin/ui.c +++ b/src/bin/ui.c @@ -152,7 +152,7 @@ double weights[] = 5.000, // test 91 1.000, // test 92 (line) 10.000, // test 93 Image Blend Many Smooth Down Scaled - + 20.000, // MASK 20.000, // MASK 2 20.000, // MASK 3 @@ -296,6 +296,9 @@ _ui_key(void *data EINA_UNUSED, const Efl_Event *event) static Eina_Position2D down; static int down_menu_sel = 0; +//FIXME: efl_input_pointer_button_get() doesn't work! +static Eina_Bool mdown = EINA_FALSE; + static void _ui_mouse_down(void *data EINA_UNUSED, const Efl_Event *event) { @@ -306,6 +309,7 @@ _ui_mouse_down(void *data EINA_UNUSED, const Efl_Event *event) { down = efl_input_pointer_position_get(ev); down_menu_sel = menu_sel; + mdown = EINA_TRUE; } } @@ -325,6 +329,7 @@ _ui_mouse_up(void *data EINA_UNUSED, const Efl_Event *event) if ((((dx * dx) + (dy * dy)) < (20 * 20)) && (menu_sel == down_menu_sel)) _ui_select(); + mdown = EINA_FALSE; } else { @@ -338,7 +343,10 @@ _ui_mouse_move(void *data EINA_UNUSED, const Efl_Event *event) { Efl_Input_Pointer *ev = event->info; - if (efl_input_pointer_button_get(ev) != 1) return; + /* FIXME: This mdown should be replace with the original call + if (efl_input_pointer_button_get(ev) != 1) return; */ + if (!mdown) return; + if (menu_active) { Evas_Coord x;