Skip to content

Commit 9561971

Browse files
realsoelynnkosmydel
authored andcommitted
Make getContentOriginOffset to know info about if call-site want transform or not (facebook#44822)
Summary: Pull Request resolved: facebook#44822 Changelog: [Internal] This is to make `getContentOriginOffset` to have `includeTransform` information passed during Layout computation. Differential Revision: D58223380
1 parent 42f136d commit 9561971

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

packages/react-native/ReactCommon/react/renderer/core/LayoutableShadowNode.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,7 @@ Transform LayoutableShadowNode::getTransform() const {
194194

195195
Point LayoutableShadowNode::getContentOriginOffset(
196196
bool /*includeTransform*/) const {
197+
197198
return {0, 0};
198199
}
199200

packages/react-native/ReactCommon/react/renderer/core/tests/TestComponent.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,8 @@ class TestShadowNode final : public ConcreteViewShadowNode<
7777
facebook::react::Point _contentOriginOffset{};
7878

7979
facebook::react::Point getContentOriginOffset(
80-
bool /*includeTransform*/) const override {
80+
bool /* includeTransform */) const override {
81+
8182
return _contentOriginOffset;
8283
}
8384
};

0 commit comments

Comments
 (0)