mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Linux: Take global scale factor into account when setting peer scale factor
This commit is contained in:
parent
38b24d7145
commit
a45f05c1db
1 changed files with 2 additions and 2 deletions
|
|
@ -1202,7 +1202,7 @@ public:
|
|||
|
||||
auto& displays = Desktop::getInstance().getDisplays();
|
||||
|
||||
auto newScaleFactor = displays.findDisplayForRect (bounds, true).scale;
|
||||
auto newScaleFactor = displays.findDisplayForRect (bounds, true).scale / Desktop::getInstance().getGlobalScaleFactor();
|
||||
if (! approximatelyEqual (newScaleFactor, currentScaleFactor))
|
||||
{
|
||||
currentScaleFactor = newScaleFactor;
|
||||
|
|
@ -2796,7 +2796,7 @@ private:
|
|||
Rectangle<int> physicalBounds (wx, wy, (int) ww, (int) wh);
|
||||
auto& displays = Desktop::getInstance().getDisplays();
|
||||
|
||||
auto newScaleFactor = displays.findDisplayForRect (physicalBounds, true).scale;
|
||||
auto newScaleFactor = displays.findDisplayForRect (physicalBounds, true).scale / Desktop::getInstance().getGlobalScaleFactor();
|
||||
if (! approximatelyEqual (newScaleFactor, currentScaleFactor))
|
||||
{
|
||||
currentScaleFactor = newScaleFactor;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue