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

Share similar XAML dynamic setters #14717

Merged
merged 1 commit into from
Mar 1, 2024

Conversation

MrJul
Copy link
Member

@MrJul MrJul commented Feb 23, 2024

What does the pull request do?

A revival of one of my first PR #8799, aiming at reducing code duplication in the XAML by sharing property setters when appropriate.

What is the current behavior?

The XAML dynamic setters are generated per type/closure, leading to duplication.

What is the updated/expected behavior with this PR?

The XAML dynamic setters are shared between all compiled types in an assembly.

Size changes:

Assembly Before After Reduction
Themes.Fluent 771 KB 731 KB -5.2%
Themes.Simple 324 KB 310 KB -4.3%

@MrJul MrJul force-pushed the better-setters-cache2 branch from e786d3d to aa15781 Compare February 28, 2024 20:35
@avaloniaui-bot
Copy link

You can test this PR using the following package version. 11.1.999-cibuild0045401-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

@MrJul MrJul force-pushed the better-setters-cache2 branch from aa15781 to e125021 Compare February 29, 2024 18:35
@avaloniaui-bot
Copy link

You can test this PR using the following package version. 11.1.999-cibuild0045451-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

@maxkatz6 maxkatz6 added this pull request to the merge queue Feb 29, 2024
Merged via the queue into AvaloniaUI:master with commit 434cbac Mar 1, 2024
6 checks passed
@MrJul MrJul deleted the better-setters-cache2 branch March 1, 2024 09:15
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.

3 participants