mattermost / desktop

Mattermost Desktop application for Windows, Mac and Linux
Apache License 2.0
1.97k stars 793 forks source link

[MM-58780] Don't account for scaleFactor on Windows when resizing if the matching screen is the primary monitor #3072

Closed devinbinnie closed 2 weeks ago

devinbinnie commented 3 weeks ago

Summary

Further to the fix I did for the Electron bug here: https://github.com/electron/electron/issues/10862 The primary monitor on Windows doesn't need to care about the scale factor, and will respect it when resetting its window bounds. This PR checks to see if the primary monitor is the matching screen and won't use the scaleFactor if the windows bounds aren't set.

Ticket Link

https://mattermost.atlassian.net/browse/MM-58780 Closes https://github.com/mattermost/desktop/issues/3067

Fixed an issue where the window size will get smaller on Windows after a restart if the primary monitor is used and is scaled
marianunez commented 3 weeks ago

Harshil is out so you may want to get another reviewer