-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Remove the unnecessary fields in DpiHelper #6851
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
Conversation
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
/azp run |
No pipelines are associated with this pull request. |
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Otherwise LGTM, great find @lindexi
src/Microsoft.DotNet.Wpf/src/PresentationFramework/System/Windows/Standard/DpiHelper.cs
Outdated
Show resolved
Hide resolved
/azp run |
Azure Pipelines successfully started running 1 pipeline(s). |
@lindexi This PR is good to be merge can you please resolve the conversations? |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6851 +/- ##
=======================================
Coverage ? 13.48%
=======================================
Files ? 3316
Lines ? 664822
Branches ? 74651
=======================================
Hits ? 89637
Misses ? 572582
Partials ? 2603
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
f763970
to
06f7f4f
Compare
Thank you @lindexi, for your consistent and valuable contributions. |
Description
We can merge the
_transformToDevice
and_transformToDip
fields to local variable. Why we define the_transformToDevice
and_transformToDip
fields? Because we use the two fields to store the DPI in the previous version, and the code is:In order to support Per-Moniter v2, we will use the DPI in per window and we do not get the dpi from desktop once. It is means that we do not need these two fields anymore.
Customer Impact
None.
Regression
None.
Testing
Just CI.
Risk
Low. Unless some developers rely on using reflection to get fields.
Microsoft Reviewers: Open in CodeFlow