Fix to set the correct gesture position in multi-touch 25/282225/2
authorSeoyeon Kim <seoyeon2.kim@samsung.com>
Wed, 28 Sep 2022 04:39:13 +0000 (13:39 +0900)
committerArtur Świgoń <a.swigon@samsung.com>
Mon, 3 Oct 2022 09:28:09 +0000 (11:28 +0200)
- When user tries to zoom out/in an object, sometimes the object gets
bigger than the desired zoom behavior.

Change-Id: Iafef71c96c03f7c1aba69463eec633ae8a732865
Signed-off-by: Seoyeon Kim <seoyeon2.kim@samsung.com>
src/e_screen_reader_gestures.c

index 38bcfa3..053b64f 100644 (file)
@@ -632,6 +632,11 @@ start_scroll(Cover *cov)
         DBG("NOT ENOUGH MEMORY");
         return ;
      }
+
+   cov->flick_gesture.ev_first_down->multi.x = (double) cov->hover_gesture.x[0];
+   cov->flick_gesture.ev_first_down->multi.y = (double) cov->hover_gesture.y[0];
+
+
    memcpy(ev_down, cov->flick_gesture.ev_first_down, sizeof(Ecore_Event_Mouse_Button));
 
    if (g_context->object_needs_scroll_from_x != -1 && g_context->object_needs_scroll_from_y != -1)
@@ -658,6 +663,10 @@ start_scroll(Cover *cov)
    ev_down->y = cov->hover_gesture.y[1];
    ev_down->multi.device = 1;
    ev_down->multi.radius += MAGIC_NUMBER;
+
+   ev_down->multi.x = (double) cov->hover_gesture.x[1];
+   ev_down->multi.y = (double) cov->hover_gesture.y[1];
+
    _emit_mouse_move_event(ev_down);
    ecore_event_add(ECORE_EVENT_MOUSE_BUTTON_DOWN, ev_down, NULL, NULL);
 }