[Android] Fixed TouchBegan reporting wrong coordinates

* So far `sf::Event::TouchBegan` always reported the coordinates of the
first pointer/finger.
This commit is contained in:
Mario Liebisch 2014-06-09 09:26:03 +02:00 committed by Stefan Schindler
parent 9690a7edee
commit 159176f5ba

View File

@ -376,8 +376,6 @@ void WindowImplAndroid::processMotionEvent(AInputEvent* _event, ActivityStates*
}
states->pendingEvents.push_back(event);
states->touchEvents[id] = Vector2i(event.touch.x, event.touch.y);
}
}
@ -391,8 +389,8 @@ void WindowImplAndroid::processPointerEvent(bool isDown, AInputEvent* _event, Ac
int index = (action & AMOTION_EVENT_ACTION_POINTER_INDEX_MASK) >> AMOTION_EVENT_ACTION_POINTER_INDEX_SHIFT;
int id = AMotionEvent_getPointerId(_event, index);
float x = AMotionEvent_getX(_event, 0);
float y = AMotionEvent_getY(_event, 0);
float x = AMotionEvent_getX(_event, index);
float y = AMotionEvent_getY(_event, index);
Event event;