Преглед на файлове

Fix swipe gestures for web (#3151)

pull/3153/head
ubkp преди 2 години
committed by GitHub
родител
ревизия
ffe4d36e0a
No known key found for this signature in database GPG ключ ID: 4AEE18F83AFDEB23
променени са 1 файла, в които са добавени 4 реда и са изтрити 0 реда
  1. +4
    -0
      src/rcore.c

+ 4
- 0
src/rcore.c Целия файл

@ -6131,6 +6131,10 @@ static EM_BOOL EmscriptenTouchCallback(int eventType, const EmscriptenTouchEvent
{
gestureEvent.pointId[i] = CORE.Input.Touch.pointId[i];
gestureEvent.position[i] = CORE.Input.Touch.position[i];
// Normalize gestureEvent.position[i]
gestureEvent.position[i].x /= (float)GetScreenWidth();
gestureEvent.position[i].y /= (float)GetScreenHeight();
}
// Gesture data is sent to gestures system for processing

Зареждане…
Отказ
Запис