Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove JNI Binding usage of layoutContext #1377

Closed
wants to merge 2 commits into from

Conversation

NickGerleman
Copy link
Contributor

Summary:
To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 0b55b48444f3c88761fd22a93079509760f56060
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 5a5ec0ff30c484d6993428aa96af34f16aef1e98
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 802b9b1f1ebbb56dd4f6e4d91e9b8f2bddc2312c
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 5ae8115dd596e01c396d24fee8d8aecf7fbddc2c
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 002cd27a6df19ce36d4b1101b4f96c3153d20753
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 791a520b8ec1447eb3a57b232d45cd4b1d281cce
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: b07c7f773eb001b3ee6975f3a1efaf8eddc39130
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 27644287b97e17f0ff7ca222bf46fa0b117c9894
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Differential Revision: D49179243

fbshipit-source-id: 0bd0ac754bb47604963eea83644663dc5f99fc75
NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 0860a3bcb11baa9dfc63a23f136996178d606eec
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 1646e0d07e4587c4720bb71e2cf7ca1abbbb1aea
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: a1024345efb5e27fe269e3e10b1bbd4edb71d00b
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: d4877971b1606647a31abefb48a80b0d54428cef
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: ef1271592f245f75f586e4adf23c2ab54b5f29ed
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: eee48e5d5e7530fbd6cf0d8476542b6f8c10a82b
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 12, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 2f0bd0e97d834f13b4cf65c755bbd64a878710ba
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 12, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 303198e0e8f75b75a69d25240842151b3cf69f81
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 13, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 6c9a5a8086d8dc3b8fa0fedb9020dfc1cef56bda
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 13, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 284d599581b39ba6de90ebbf3b2b7942b8786759
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 13, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: ba029033202041d10df85f3654594f58bc51e227
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 13, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 74cb999ae3cc7aa9261664c478315a62cf67dc1a
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/yoga that referenced this pull request Sep 13, 2023
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: e6d09cca0f4b6ac2346b80468770cf557f97dddd
NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 13, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 423a64dfadba8e43c51425b31572d2389a6f60e6
NickGerleman and others added 2 commits September 12, 2023 19:08
Summary: Moves `isBaselineLayout` out of `CalculateLayout` into `Baseline.h`. This function is called by flex line justification code, which I have been looking at extracting.

Differential Revision: D49177937

fbshipit-source-id: 7ae3e8c9bb5ce82fb91626f7ab6c8886ef8d22a8
Summary:
X-link: facebook/react-native#39402

Pull Request resolved: facebook#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: c838dce0a4356eecce243db22b4050793c4920e4
@facebook-github-bot
Copy link
Contributor

This pull request was exported from Phabricator. Differential Revision: D49179243

NickGerleman added a commit to NickGerleman/react-native that referenced this pull request Sep 13, 2023
Summary:
Pull Request resolved: facebook#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 81c88974bf145328d352a1769291e67aa05396d3
facebook-github-bot pushed a commit to facebook/react-native that referenced this pull request Sep 13, 2023
Summary:
Pull Request resolved: #39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 7e4944bead864e6b73fd2208a47c5725c18ff2b0
facebook-github-bot pushed a commit to facebook/litho that referenced this pull request Sep 13, 2023
Summary:
X-link: facebook/react-native#39402

X-link: facebook/yoga#1377

To avoid keeping a per-node mapping on native Yoga nodes to Java nodes, a per-layout context was added, to be able to pass information from the start of the layout, to measure functions, log functions, etc.

The way this was done was super invasive, and added quite a few private APIs used only by the JNI functions.

This change removes the context-using functions from the JNI bindings in favor of it managing its own context. Next diff removes all the cruft.

Reviewed By: javache

Differential Revision: D49179243

fbshipit-source-id: 7e4944bead864e6b73fd2208a47c5725c18ff2b0
@facebook-github-bot
Copy link
Contributor

This pull request has been merged in b1e0140.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants