Skip to content

Change type of shadows from array to LayerDrawable#46818

Closed
jorge-cab wants to merge 1 commit into
facebook:mainfrom
jorge-cab:export-D63798842
Closed

Change type of shadows from array to LayerDrawable#46818
jorge-cab wants to merge 1 commit into
facebook:mainfrom
jorge-cab:export-D63798842

Conversation

@jorge-cab
Copy link
Copy Markdown
Contributor

Summary:
Before we were using lists which meant CompositeBackgroundDrawable had a LayerDrawable of variable length.

This meant that our layers were not consistent and made it hard to optimize CompositeBackgroundDrawable to not create a new instance every time we set a new Layer.

With this change CompositeBackgroundDrawable has a consistent amount of layers which will allow us to more easily mutate it and land the optimization present on D63287222

Differential Revision: D63798842

@facebook-github-bot facebook-github-bot added CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. p: Facebook Partner: Facebook Partner labels Oct 3, 2024
@facebook-github-bot
Copy link
Copy Markdown
Contributor

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

@facebook-github-bot
Copy link
Copy Markdown
Contributor

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

Summary:

Before we were using lists which meant `CompositeBackgroundDrawable` had a `LayerDrawable` of variable length. 

This meant that our layers were not consistent and made it hard to optimize `CompositeBackgroundDrawable` to not create a new instance every time we set a new Layer.  

With this change `CompositeBackgroundDrawable` has a consistent amount of layers which will allow us to more easily mutate it and land the optimization present on D63287222

Changelog: [Internal]

Reviewed By: NickGerleman

Differential Revision: D63798842
@facebook-github-bot
Copy link
Copy Markdown
Contributor

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

jorge-cab added a commit to jorge-cab/react-native that referenced this pull request Nov 19, 2024
Summary:

Before we were using lists which meant `CompositeBackgroundDrawable` had a `LayerDrawable` of variable length. 

This meant that our layers were not consistent and made it hard to optimize `CompositeBackgroundDrawable` to not create a new instance every time we set a new Layer.  

With this change `CompositeBackgroundDrawable` has a consistent amount of layers which will allow us to more easily mutate it and land the optimization present on D63287222

Changelog: [Internal]

Reviewed By: NickGerleman

Differential Revision: D63798842
@facebook-github-bot facebook-github-bot added the Merged This PR has been merged. label Nov 19, 2024
@facebook-github-bot
Copy link
Copy Markdown
Contributor

This pull request has been merged in fd2ce35.

@react-native-bot
Copy link
Copy Markdown
Collaborator

This pull request was successfully merged by @jorge-cab in fd2ce35

When will my fix make it into a release? | How to file a pick request?

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

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. p: Facebook Partner: Facebook Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants