mirror of
https://github.com/lvgl/lvgl.git
synced 2025-01-14 06:42:58 +08:00
fix(sdl): fix warning
This commit is contained in:
parent
dbecd26d28
commit
87de84dfbb
@ -135,17 +135,17 @@ void _lv_sdl_mouse_handler(SDL_Event * event)
|
||||
|
||||
case SDL_FINGERUP:
|
||||
indev_dev->left_button_down = false;
|
||||
indev_dev->last_x = hor_res * event->tfinger.x / zoom;
|
||||
indev_dev->last_y = ver_res * event->tfinger.y / zoom;
|
||||
indev_dev->last_x = (int16_t)((float)hor_res * event->tfinger.x / zoom);
|
||||
indev_dev->last_y = (int16_t)((float)ver_res * event->tfinger.y / zoom);
|
||||
break;
|
||||
case SDL_FINGERDOWN:
|
||||
indev_dev->left_button_down = true;
|
||||
indev_dev->last_x = hor_res * event->tfinger.x / zoom;
|
||||
indev_dev->last_y = ver_res * event->tfinger.y / zoom;
|
||||
indev_dev->last_x = (int16_t)((float)hor_res * event->tfinger.x / zoom);
|
||||
indev_dev->last_y = (int16_t)((float)ver_res * event->tfinger.y / zoom);
|
||||
break;
|
||||
case SDL_FINGERMOTION:
|
||||
indev_dev->last_x = hor_res * event->tfinger.x / zoom;
|
||||
indev_dev->last_y = ver_res * event->tfinger.y / zoom;
|
||||
indev_dev->last_x = (int16_t)((float)hor_res * event->tfinger.x / zoom);
|
||||
indev_dev->last_y = (int16_t)((float)ver_res * event->tfinger.y / zoom);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user