summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2020-08-25 09:03:51 +0100
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2020-08-25 13:21:25 +0100
commitaac4dd306623101cd472f6f823ec9fc700652711 (patch)
tree8f76086ba6e8919777e6ef2383570cb6c7a6cf09
parent13d4c546f9f73ed270bbc30fbe85a14805c12430 (diff)
evas events - cast enums after checking their values match - fix wrns
-rw-r--r--src/lib/evas/canvas/evas_events.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/lib/evas/canvas/evas_events.c b/src/lib/evas/canvas/evas_events.c
index 0a1f1b460f..96ec12c025 100644
--- a/src/lib/evas/canvas/evas_events.c
+++ b/src/lib/evas/canvas/evas_events.c
@@ -1642,7 +1642,7 @@ _canvas_event_feed_mouse_down_internal(Evas_Public_Data *e, Efl_Input_Pointer_Da
1642 ev->cur.y = pdata->seat->y; 1642 ev->cur.y = pdata->seat->y;
1643 ev->modifiers = &(e->modifiers); 1643 ev->modifiers = &(e->modifiers);
1644 ev->locks = &(e->locks); 1644 ev->locks = &(e->locks);
1645 ev->event_flags = e->default_event_flags; 1645 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
1646 ev->touch_id = 0; 1646 ev->touch_id = 0;
1647 ev->action = EFL_POINTER_ACTION_DOWN; 1647 ev->action = EFL_POINTER_ACTION_DOWN;
1648 ev->value_flags |= value_flags; 1648 ev->value_flags |= value_flags;
@@ -1913,7 +1913,7 @@ _canvas_event_feed_mouse_up_internal(Evas_Public_Data *e, Efl_Input_Pointer_Data
1913 ev->cur.y = pdata->seat->y; 1913 ev->cur.y = pdata->seat->y;
1914 ev->modifiers = &(e->modifiers); 1914 ev->modifiers = &(e->modifiers);
1915 ev->locks = &(e->locks); 1915 ev->locks = &(e->locks);
1916 ev->event_flags = e->default_event_flags; 1916 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
1917 ev->touch_id = 0; 1917 ev->touch_id = 0;
1918 ev->value_flags |= value_flags; 1918 ev->value_flags |= value_flags;
1919 if (ev->device) efl_ref(ev->device); 1919 if (ev->device) efl_ref(ev->device);
@@ -2048,7 +2048,7 @@ _canvas_event_feed_mouse_updown(Eo *eo_e, int b, Evas_Button_Flags flags,
2048 else 2048 else
2049 ev->action = down ? EFL_POINTER_ACTION_DOWN : EFL_POINTER_ACTION_UP; 2049 ev->action = down ? EFL_POINTER_ACTION_DOWN : EFL_POINTER_ACTION_UP;
2050 ev->button = b; 2050 ev->button = b;
2051 ev->button_flags = flags; 2051 ev->button_flags = (Efl_Pointer_Flags)flags;
2052 ev->radius = 1; 2052 ev->radius = 1;
2053 ev->radius_x = 1; 2053 ev->radius_x = 1;
2054 ev->radius_y = 1; 2054 ev->radius_y = 1;
@@ -2135,7 +2135,7 @@ _canvas_event_feed_mouse_cancel_internal(Evas_Public_Data *e, Efl_Input_Pointer_
2135 2135
2136 ev->action = EFL_POINTER_ACTION_CANCEL; 2136 ev->action = EFL_POINTER_ACTION_CANCEL;
2137 ev->value_flags |= value_flags; 2137 ev->value_flags |= value_flags;
2138 ev->event_flags = flags; 2138 ev->event_flags = (Efl_Input_Flags)flags;
2139 EINA_LIST_FOREACH_SAFE(e->touch_points, l, ll, point) 2139 EINA_LIST_FOREACH_SAFE(e->touch_points, l, ll, point)
2140 { 2140 {
2141 if ((point->state == EVAS_TOUCH_POINT_DOWN) || 2141 if ((point->state == EVAS_TOUCH_POINT_DOWN) ||
@@ -2212,7 +2212,7 @@ _canvas_event_feed_mouse_wheel_internal(Eo *eo_e, Efl_Input_Pointer_Data *pe)
2212 ev->cur.y = pdata->seat->y; 2212 ev->cur.y = pdata->seat->y;
2213 ev->modifiers = &(e->modifiers); 2213 ev->modifiers = &(e->modifiers);
2214 ev->locks = &(e->locks); 2214 ev->locks = &(e->locks);
2215 ev->event_flags = e->default_event_flags; 2215 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
2216 ev->action = EFL_POINTER_ACTION_WHEEL; 2216 ev->action = EFL_POINTER_ACTION_WHEEL;
2217 ev->value_flags |= value_flags; 2217 ev->value_flags |= value_flags;
2218 2218
@@ -2342,7 +2342,7 @@ _canvas_event_feed_mouse_move_internal(Evas_Public_Data *e, Efl_Input_Pointer_Da
2342 evt = ev->eo; 2342 evt = ev->eo;
2343 ev->modifiers = &(e->modifiers); 2343 ev->modifiers = &(e->modifiers);
2344 ev->locks = &(e->locks); 2344 ev->locks = &(e->locks);
2345 ev->event_flags = e->default_event_flags; 2345 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
2346 ev->pressed_buttons = pdata->button; 2346 ev->pressed_buttons = pdata->button;
2347 ev->touch_id = 0; 2347 ev->touch_id = 0;
2348 ev->value_flags |= value_flags; 2348 ev->value_flags |= value_flags;
@@ -2795,7 +2795,7 @@ _canvas_event_feed_mouse_in_internal(Evas *eo_e, Efl_Input_Pointer_Data *ev)
2795 ev->cur.y = pdata->seat->y; 2795 ev->cur.y = pdata->seat->y;
2796 ev->modifiers = &(e->modifiers); 2796 ev->modifiers = &(e->modifiers);
2797 ev->locks = &(e->locks); 2797 ev->locks = &(e->locks);
2798 ev->event_flags = e->default_event_flags; 2798 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
2799 ev->value_flags |= value_flags; 2799 ev->value_flags |= value_flags;
2800 if (ev->device) efl_ref(ev->device); 2800 if (ev->device) efl_ref(ev->device);
2801 2801
@@ -2901,7 +2901,7 @@ _canvas_event_feed_mouse_out_internal(Evas *eo_e, Efl_Input_Pointer_Data *ev)
2901 ev->cur.y = pdata->seat->y; 2901 ev->cur.y = pdata->seat->y;
2902 ev->modifiers = &(e->modifiers); 2902 ev->modifiers = &(e->modifiers);
2903 ev->locks = &(e->locks); 2903 ev->locks = &(e->locks);
2904 ev->event_flags = e->default_event_flags; 2904 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
2905 ev->value_flags |= value_flags; 2905 ev->value_flags |= value_flags;
2906 if (ev->device) efl_ref(ev->device); 2906 if (ev->device) efl_ref(ev->device);
2907 2907
@@ -3025,7 +3025,7 @@ _canvas_event_feed_multi_down_internal(Evas_Public_Data *e, Efl_Input_Pointer_Da
3025 ev->action = EFL_POINTER_ACTION_DOWN; 3025 ev->action = EFL_POINTER_ACTION_DOWN;
3026 ev->modifiers = &(e->modifiers); 3026 ev->modifiers = &(e->modifiers);
3027 ev->locks = &(e->locks); 3027 ev->locks = &(e->locks);
3028 ev->event_flags = e->default_event_flags; 3028 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
3029 ev->value_flags |= value_flags; 3029 ev->value_flags |= value_flags;
3030 if (ev->device) efl_ref(ev->device); 3030 if (ev->device) efl_ref(ev->device);
3031 3031
@@ -3131,7 +3131,7 @@ _canvas_event_feed_multi_up_internal(Evas_Public_Data *e, Efl_Input_Pointer_Data
3131 ev->action = EFL_POINTER_ACTION_UP; 3131 ev->action = EFL_POINTER_ACTION_UP;
3132 ev->modifiers = &(e->modifiers); 3132 ev->modifiers = &(e->modifiers);
3133 ev->locks = &(e->locks); 3133 ev->locks = &(e->locks);
3134 ev->event_flags = e->default_event_flags; 3134 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
3135 ev->value_flags |= value_flags; 3135 ev->value_flags |= value_flags;
3136 if (ev->device) efl_ref(ev->device); 3136 if (ev->device) efl_ref(ev->device);
3137 3137
@@ -3211,7 +3211,7 @@ _canvas_event_feed_multi_internal(Evas *eo_e, Evas_Public_Data *e,
3211 ev->radius = rad; 3211 ev->radius = rad;
3212 ev->radius_x = radx; 3212 ev->radius_x = radx;
3213 ev->radius_y = rady; 3213 ev->radius_y = rady;
3214 ev->button_flags = flags; 3214 ev->button_flags = (Efl_Pointer_Flags)flags;
3215 ev->timestamp = timestamp; 3215 ev->timestamp = timestamp;
3216 ev->data = (void *) data; 3216 ev->data = (void *) data;
3217 ev->device = efl_ref(_evas_event_legacy_device_get(eo_e, EINA_TRUE)); 3217 ev->device = efl_ref(_evas_event_legacy_device_get(eo_e, EINA_TRUE));
@@ -3311,7 +3311,7 @@ _canvas_event_feed_multi_move_internal(Evas_Public_Data *e, Efl_Input_Pointer_Da
3311 evt = ev->eo; 3311 evt = ev->eo;
3312 ev->modifiers = &(e->modifiers); 3312 ev->modifiers = &(e->modifiers);
3313 ev->locks = &(e->locks); 3313 ev->locks = &(e->locks);
3314 ev->event_flags = e->default_event_flags; 3314 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
3315 ev->action = EFL_POINTER_ACTION_MOVE; 3315 ev->action = EFL_POINTER_ACTION_MOVE;
3316 ev->value_flags |= value_flags; 3316 ev->value_flags |= value_flags;
3317 if (ev->device) efl_ref(ev->device); 3317 if (ev->device) efl_ref(ev->device);
@@ -3501,7 +3501,7 @@ _canvas_event_feed_key_down_internal(Evas_Public_Data *e, Efl_Input_Key_Data *ev
3501 evt = ev->eo; 3501 evt = ev->eo;
3502 ev->modifiers = &(e->modifiers); 3502 ev->modifiers = &(e->modifiers);
3503 ev->locks = &(e->locks); 3503 ev->locks = &(e->locks);
3504 ev->event_flags = e->default_event_flags; 3504 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
3505 if (ev->device) efl_ref(ev->device); 3505 if (ev->device) efl_ref(ev->device);
3506 3506
3507 if (e->grabs) 3507 if (e->grabs)
@@ -3594,7 +3594,7 @@ _canvas_event_feed_key_up_internal(Evas_Public_Data *e, Efl_Input_Key_Data *ev)
3594 evt = ev->eo; 3594 evt = ev->eo;
3595 ev->modifiers = &(e->modifiers); 3595 ev->modifiers = &(e->modifiers);
3596 ev->locks = &(e->locks); 3596 ev->locks = &(e->locks);
3597 ev->event_flags = e->default_event_flags; 3597 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
3598 if (ev->device) efl_ref(ev->device); 3598 if (ev->device) efl_ref(ev->device);
3599 3599
3600 if (e->grabs) 3600 if (e->grabs)
@@ -3761,7 +3761,7 @@ evas_event_feed_hold(Eo *eo_e, int hold, unsigned int timestamp, const void *dat
3761 ev->hold = !!hold; 3761 ev->hold = !!hold;
3762 ev->data = (void *) data; 3762 ev->data = (void *) data;
3763 ev->timestamp = timestamp; 3763 ev->timestamp = timestamp;
3764 ev->event_flags = e->default_event_flags; 3764 ev->event_flags = (Efl_Input_Flags)e->default_event_flags;
3765 ev->device = efl_ref(_evas_event_legacy_device_get(eo_e, EINA_TRUE)); 3765 ev->device = efl_ref(_evas_event_legacy_device_get(eo_e, EINA_TRUE));
3766 3766
3767 pdata = _evas_pointer_data_by_device_get(e, ev->device); 3767 pdata = _evas_pointer_data_by_device_get(e, ev->device);