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

Replace resource constants with properties in WindowsBase #6060

Conversation

ThomasGoulet73
Copy link
Contributor

Contributes to #1

Depends on #6059

Description

Replace the use of resource constants with properties in WindowsBase. This follows the standard of other .Net projects, like dotnet/runtime.

There are a bunch of files that are shared with other projects. I temporarily changed the use of constants with using nameof of properties in WindowsBase in this commit: 86ef9fc.

Customer Impact

None.

Regression

No.

Testing

I tested a few resources and made sure that the generated code in the property getter is the same as the original code.

Risk

None.

@ThomasGoulet73 ThomasGoulet73 requested a review from a team as a code owner February 3, 2022 04:56
@ghost ghost added the PR metadata: Label to tag PRs, to facilitate with triage label Feb 3, 2022
@ghost ghost requested review from fabiant3, ryalanms and SamBent February 3, 2022 04:56
@ThomasGoulet73
Copy link
Contributor Author

ThomasGoulet73 commented Feb 9, 2022

I changed shared files to use properties even in projects that do not use properties by adding properties manually to SR. I think this is better than my initial approach of using nameof because it makes it easier to remove workaround when changing other projects to use properties because the properties will conflict with the generated properties.

I think that this PR is now ready to review. This PR should have a pretty low risk of breaking something.

Copy link
Member

@RussKie RussKie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@singhashish-wpf singhashish-wpf merged commit be69d73 into dotnet:main Mar 30, 2022
@ThomasGoulet73 ThomasGoulet73 deleted the replace-resource-constants-with-properties-windowsbase branch March 30, 2022 17:10
@ghost ghost locked as resolved and limited conversation to collaborators Apr 29, 2022
@ghost ghost assigned ThomasGoulet73 May 4, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
PR metadata: Label to tag PRs, to facilitate with triage
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants