Skip to content

Commit

Permalink
opt code
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongwuzw committed Jul 31, 2024
1 parent d7f8823 commit a81e6d9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -263,14 +263,14 @@ ShadowNode::Shared LayoutableShadowNode::findNodeAtPoint(

auto transform = layoutableShadowNode->getTransform();
auto frame = layoutableShadowNode->getLayoutMetrics().frame;
auto transformedFrame = frame * transform;
auto isPointInside = false;
auto newPoint = Point();
auto inversionTransform = transform;

// Fast path: Handle horizontal/vertical inversion
if (Transform::isVerticalInversion(transform) ||
Transform::isHorizontalInversion(transform)) {
auto transformedFrame = frame * transform;
auto centerX =
transformedFrame.origin.x + transformedFrame.size.width / 2.0;
auto centerY =
Expand Down

0 comments on commit a81e6d9

Please sign in to comment.