mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-11 23:54:18 +00:00
Fixed a few windowing issues when using global scale factors.
This commit is contained in:
parent
27646a8db0
commit
4af1478dfb
3 changed files with 6 additions and 6 deletions
|
|
@ -1045,7 +1045,7 @@ public:
|
|||
r = Desktop::getInstance().getDisplays().getMainDisplay().userArea;
|
||||
|
||||
if (! r.isEmpty())
|
||||
setBounds (r, shouldBeFullScreen);
|
||||
setBounds (ScalingHelpers::scaledScreenPosToUnscaled (component, r), shouldBeFullScreen);
|
||||
|
||||
component.repaint();
|
||||
}
|
||||
|
|
@ -1115,9 +1115,9 @@ public:
|
|||
if (c == &component)
|
||||
break;
|
||||
|
||||
// TODO: needs scaling correctly
|
||||
if (c->contains (localPos + bounds.getPosition() - c->getScreenPosition()))
|
||||
return false;
|
||||
if (ComponentPeer* peer = c->getPeer())
|
||||
if (peer->contains (localPos + bounds.getPosition() - peer->getBounds().getPosition(), true))
|
||||
return false;
|
||||
}
|
||||
|
||||
if (trueIfInAChildWindow)
|
||||
|
|
|
|||
|
|
@ -369,7 +369,7 @@ public:
|
|||
|
||||
// (can't call the component's setBounds method because that'll reset our fullscreen flag)
|
||||
if (r != component.getBounds() && ! r.isEmpty())
|
||||
setBounds (r, shouldBeFullScreen);
|
||||
setBounds (ScalingHelpers::scaledScreenPosToUnscaled (component, r), shouldBeFullScreen);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -763,7 +763,7 @@ public:
|
|||
ShowWindow (hwnd, SW_SHOWNORMAL);
|
||||
|
||||
if (! boundsCopy.isEmpty())
|
||||
setBounds (boundsCopy, false);
|
||||
setBounds (ScalingHelpers::scaledScreenPosToUnscaled (component, boundsCopy), false);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue