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

fix(iOSmacOS): Obsolete the use of readonly fields #9126

Merged
merged 2 commits into from
Jun 26, 2022

Conversation

spouliot
Copy link
Contributor

GitHub Issue (If applicable): closes #9027

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

ViewHelper has C# readonly fields for MainScreenScale and IsRetinaDisplay that are evaluated only once. IOW they are set to the current screen when the evaluation is done and moving the window to a different screen will not update the values.

What is the new behavior?

Both readonly fields are now decorated with [Obsolete] attributes giving update instructions to directly use (now cached) DisplayInformation properties. This ensure the current (screen) values will be given for every call during the app lifetime.

PR Checklist

Please check if your PR fulfills the following requirements:

Other information

Internal Issue (If applicable):

@spouliot spouliot requested a review from a team June 24, 2022 14:40
@gitpod-io
Copy link

gitpod-io bot commented Jun 24, 2022

Copy link
Member

@jeromelaban jeromelaban left a comment

Choose a reason for hiding this comment

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

Nice ! Let's validate the screenshot comparison results as well.

@jeromelaban
Copy link
Member

Screenshots look good!

@jeromelaban jeromelaban merged commit 048db03 into unoplatform:master Jun 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[macos][ios] Issues with ViewHelper
2 participants