Remove unecessary PointerEvent attributes

Summary: Changelog: [iOS][Internal] Remove unecessary PointerEvent attributes

Reviewed By: kacieb

Differential Revision: D37115465

fbshipit-source-id: 079a297d1ce5b3d2c6766036a111c73bd75535f1
This commit is contained in:
Vincent Riemer 2022-06-16 13:05:54 -07:00 коммит произвёл Facebook GitHub Bot
Родитель 7b0ba6d94f
Коммит 033ffcc14b
4 изменённых файлов: 0 добавлений и 18 удалений

Просмотреть файл

@ -180,8 +180,6 @@ static PointerEvent CreatePointerEventFromActiveTouch(ActiveTouch activeTouch)
event.pressure = touch.force;
event.pointerType = PointerTypeCStringFromUITouchType(activeTouch.touchType);
event.clientPoint = touch.pagePoint;
event.target = touch.target;
event.timestamp = touch.timestamp;
return event;
}
@ -196,8 +194,6 @@ CreatePointerEventFromIncompleteHoverData(UIView *view, CGPoint clientLocation,
event.pressure = 0.0;
event.pointerType = "mouse";
event.clientPoint = RCTPointFromCGPoint(clientLocation);
event.target = (Tag)view.tag;
event.timestamp = timestamp;
return event;
}

Просмотреть файл

@ -24,8 +24,6 @@ std::vector<DebugStringConvertibleObject> getDebugProps(
{"pressure", getDebugDescription(pointerEvent.pressure, options)},
{"pointerType", getDebugDescription(pointerEvent.pointerType, options)},
{"clientPoint", getDebugDescription(pointerEvent.clientPoint, options)},
{"target", getDebugDescription(pointerEvent.target, options)},
{"timestamp", getDebugDescription(pointerEvent.timestamp, options)},
};
}

Просмотреть файл

@ -34,16 +34,6 @@ struct PointerEvent {
* opposed to the coordinate within the page).
*/
Point clientPoint;
/*
* A reference to the view to which the event was originally dispatched.
*/
Tag target;
/*
* The time at which the event was created (in milliseconds). By
* specification, this value is time since epochbut in reality, browsers'
* definitions vary.
*/
Float timestamp;
};
#if RN_DEBUG_STRING_CONVERTIBLE

Просмотреть файл

@ -68,8 +68,6 @@ static jsi::Value pointerEventPayload(
object.setProperty(runtime, "pointerType", event.pointerType);
object.setProperty(runtime, "clientX", event.clientPoint.x);
object.setProperty(runtime, "clientY", event.clientPoint.y);
object.setProperty(runtime, "target", event.target);
object.setProperty(runtime, "timestamp", event.timestamp * 1000);
return object;
}